kingkingyyk3
Visitor (Welcome to the Jungle, Baby!)
- Reaction score
- 216
Here you go! Sheering Arrow in GUI!!!
P/S : I am not sure there is no leak in it, tell me if it got leaks.
Init Spell Trigger :
Sliding Trigger
P/S : I am not sure there is no leak in it, tell me if it got leaks.
Init Spell Trigger :
Trigger:
- Sheering Arrow GUI
- Events
- Unit - A unit Begins casting an ability
- Conditions
- (Ability being cast) Equal to Sheering Arrow
- Actions
- Set Caster = (Triggering unit)
- Set CasterLoc = (Position of Caster)
- Set CastLoc = (Target point of ability being cast)
- Set CasterOwning = (Owner of Caster)
- Set Angle = ((Angle from CastLoc to CasterLoc) + 180.00)
- Set LoopTimes = (Integer(((Distance between CastLoc and CasterLoc) / 50.00)))
- Animation - Play Caster's attack animation
- Wait 0.80 seconds
- Animation - Play Caster's stand animation
- Unit - Create 1 Sheering Arrow Dummy for CasterOwning at CasterLoc facing Angle degrees
- Set ArrowDummy = (Last created unit)
- Trigger - Turn on Sheering Arrow Slide <gen>
- Events
Sliding Trigger
Trigger:
- Sheering Arrow Slide
- Events
- Time - Every 0.03 seconds of game time
- Conditions
- Actions
- Set tempLoc = (Position of ArrowDummy)
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- If - Conditions
- LoopTimes Greater than or equal to 0
- Then - Actions
- Set LoopTimes = (LoopTimes - 1)
- Set tempLoc2 = (tempLoc offset by 50.00 towards Angle degrees)
- Unit - Move ArrowDummy instantly to tempLoc2
- Custom script: call DestroyEffect(AddSpecialEffectLoc("Abilities\\Spells\\Undead\\FreezingBreath\\FreezingBreathTargetArt.mdl",udg_tempLoc2))
- Custom script: call RemoveLocation(udg_tempLoc)
- Unit Group - Pick every unit in (Units within 200.00 of tempLoc2 matching ((((Life of (Matching unit)) Greater than or equal to 0.41) and (((Matching unit) is in tempGroup) Equal to False)) and ((((Matching unit) is A structure) Equal to False) and ((((Matching unit) belongs to an enemy of and do (Actions)
- Loop - Actions
- Set tempLoc = (Position of (Picked unit))
- Unit - Create 1 Caster Dummy for CasterOwning at tempLoc facing 0.00 degrees
- Set tempDummy = (Last created unit)
- Unit - Add Dummy Frost Nova for Sheering Arrow to tempDummy
- Unit - Set level of Dummy Frost Nova for Sheering Arrow for tempDummy to (Level of Sheering Arrow for Caster)
- Unit - Order tempDummy to Undead Lich - Frost Nova (Picked unit)
- Unit - Add a 1.20 second Generic expiration timer to tempDummy
- Unit Group - Add (Picked unit) to tempGroup
- Custom script: call RemoveLocation(udg_tempLoc)
- Loop - Actions
- Custom script: call RemoveLocation(udg_tempLoc2)
- Else - Actions
- Trigger - Turn off (This trigger)
- Unit - Kill ArrowDummy
- Custom script: call GroupClear(udg_tempGroup)
- -------- No need to destroy the group, we recycle it for sake of healthy --------
- Custom script: call RemoveLocation(udg_tempLoc)
- Custom script: call RemoveLocation(udg_tempLoc2)
- Custom script: call RemoveLocation(udg_CasterLoc)
- Custom script: call RemoveLocation(udg_CastLoc)
- If - Conditions
- Events