IM tryng to make a Stun system, but somehow it didnt work, i used the Hanke dynamic system!!
atm i need a stun system that i can make it non stackable with an option true/false!!
i have tryed a vjass stun fround here wich didnt worked at all!!
thats what i tryed, somehow the Loop only turn 1 time O_O
edit : it is mui ?
atm i need a stun system that i can make it non stackable with an option true/false!!
i have tryed a vjass stun fround here wich didnt worked at all!!
thats what i tryed, somehow the Loop only turn 1 time O_O
edit : it is mui ?
-
stun
-

Events
-


Unit - A unit Starts the effect of an ability
-
-

Conditions
-


(Ability being cast) Equal to Fireblast
-
-

Actions
-


-------- Set stun duration to whatever it is, here I use 5.00 --------
-


Set stun_duration = 5.00
-


-------- Saves the duration by matching it with the target unit's ID --------
-


Hashtable - Save stun_duration as (Key duration) of (Key (Target unit of ability being cast)) in H_Fireblast
-


-------- Adds the target to a global unit group of all units stunned by the spell --------
-


Unit Group - Add (Target unit of ability being cast) to temp_group
-


-------- Starts the countdown trigger if it is not already running --------
-


If ((stun2 <gen> is on) Equal to False) then do (Trigger - Turn on stun2 <gen>) else do (Do nothing)
-
-
-
stun2
-

Events
-


Time - Every 0.25 seconds of game time
-
-

Conditions
-

Actions
-


If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-



If - Conditions
-




(Number of units in temp_group) Greater than 0
-
-



Then - Actions
-




-------- If there are more than 0 units that are stunned, the trigger runs fo each unit --------
-




Unit Group - Pick every unit in temp_group and do (Actions)
-





Loop - Actions
-






If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-







If - Conditions
-








(Load (Key duration) of (Key (Picked unit)) from H_Fireblast) Greater than 0.00
-
-







Then - Actions
-








-------- If the duration remaining is more than 0.00, then it takes 0.25 off the duration since this checks every 0.25 seconds --------
-








Hashtable - Save ((Load (Key duration) of (Key (Picked unit)) from H_Fireblast) - 0.25) as (Key duration) of (Key (Picked unit)) in H_Fireblast
-
-







Else - Actions
-








-------- If the duration remaining is 0.00 or less, then it takes the stun buff off the unit --------
-








Unit - Remove Stunned buff from (Picked unit)
-








-------- And takes the unit out of the global group of stunned units --------
-








Unit Group - Remove (Picked unit) from temp_group
-








Hashtable - Clear all child hashtables of child (Key (Picked unit)) in H_Fireblast
-
-
-
-
-
-



Else - Actions
-




-------- If there are 0 units stunned, the trigger stops (why run a trigger 4 times a second if it doesn't do anything?) --------
-




Trigger - Turn off (This trigger)
-
-
-
-
Last edited:







