Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
I am making a game where you are the Naga, I have the first cutscene, but what i want is when he kills 2 towers, another cutscene happens, if anyone can help, thank you
Unit Group - Pick every unit in (Units of type Tower) and do (Actions)
Loop - Actions
Unit Group - Add (Picked unit) to TowersGroup
Trigger2
Events
Unit - A unit dies
Conditions
(Unit-type of (Triggering unit)) Equal to Tower
((Killing unit) belongs to an enemy of (Owner of (Triggering unit))) Equal to True
Actions
Unit Group - Remove (Triggering unit) from TowersGroup
If (All conditions are true) then do (Actions) else do (Actions)
If - Conditions
(Number of units in TowersGroup) Equal to 0
Then - Actions
//Cutscene actions
Else - Actions
This will make the actions when two towers die. If you want to perform the actions when a specific unit kills them, you can do it like this:
If you don't have the unit pre-set in the map, use the following trigger:
Trigger
Events
Map Initialization
Conditions
Actions
Hashtable - Create a hashtable
Set Hash = (Last created hashtable)
Custom script: set bj_wantDestroyGroup = true
Unit Group - Pick every unit in (Units of type X) and do (Actions)
Loop - Actions
Hashtable - Save 0 as 1 of (Key(Picked unit)) in Hash
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.