• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • 🏆 Hive's 6th HD Modeling Contest: Mechanical is now open! Design and model a mechanical creature, mechanized animal, a futuristic robotic being, or anything else your imagination can tinker with! 📅 Submissions close on June 30, 2024. Don't miss this opportunity to let your creativity shine! Enter now and show us your mechanical masterpiece! 🔗 Click here to enter!

SOUNDSs (not working or working only onece)

Status
Not open for further replies.
Level 14
Joined
Mar 4, 2009
Messages
1,156
I have a problem with sounds.,every sound that i wanna play will not be played.
This is the only one that is playing but only once:ugly:
  • Untitled Trigger 004
    • Events
      • Player - Player 1 (Red) types a chat message containing S as An exact match
    • Conditions
    • Actions
      • Set SOUND[1] = GromPissed3 <gen>
      • Sound - Play SOUND[1]
      • Sound - Destroy SOUND[1]
 
Level 11
Joined
Feb 22, 2006
Messages
752
All sounds made using the sound editor are saved in global variables. So if you set your own global equal to sound X, you're just making a global point to another global pointing to sound handle X. And if you destroy that X, the handle is gone. So even if you set your global to equal to sound X again, you're doing nothing but making it point to a nonexistent sound handle that cannot be played.

There's no reason you should be destroying sounds from the sound editor anyway, since they do not leak.
 
Status
Not open for further replies.
Top