• 🏆 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!

Sound Help

Status
Not open for further replies.
Level 4
Joined
May 15, 2014
Messages
67
Hey, i wanna make a sound to play when someone selects a spell. I have special sound saying "Select target" and want it to play when player selects an ability (not when he casts the ability). I've been using trigger, but its only possible to play it when someone casts an ability, not when selects it. Anyone knows how?
 
Level 11
Joined
Nov 13, 2010
Messages
211
well you can do this
Untitled Trigger 001
Events
Player - Player 1 (Red) Selects a unit
Conditions
Actions
Multiple FunctionsIf (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
((Triggering unit) has buff test ) Equal to (==) True
Then - Actions
Sound - Play song <gen>
Else - Actions

or you can try set variable for the sounds ( use Sound (sound) array 1 )
and make trigger there use the variables
 
Level 12
Joined
Mar 13, 2012
Messages
1,121
I guess the following wont help you:

You could use a dummy no target abilty which makes a sound when casted. Then it is removed and the targeted ability is added. Then after a short wait a trigger forces the player to press the hotkey for the targeted ability so you have the aiming cursor. When the player casts the ability everything is well and you can remove it and add the dummy ability again. But if he does not cast it but cancel it youre screwed. So far no way is known to detect everything that can cancel the aiming cursor. If the player presses Esc it can be detected, but if he presses just right click then things get messy.
 
Status
Not open for further replies.
Top