I'm a fairly big noob at map making, and I just created my first GUI custom spell.
I'd post the map its on but I dont want to waste your time with a spell that may have leaks. I'm going to post the Trigger so you can tell me if there are leaks and I will quickly fix them so that I may post the spell for others to use
The spell works like this -
The unit that is casted on become invulnerable for 10 seconds, and then once the 10 seconds runs out, allies within 900 of the unit heal for 400.
It works fine in game, i'm just worried that there may be some leaks since im so new at this :O
Thank you!
Here is the trigger
Thanks!
I'd post the map its on but I dont want to waste your time with a spell that may have leaks. I'm going to post the Trigger so you can tell me if there are leaks and I will quickly fix them so that I may post the spell for others to use
The spell works like this -
The unit that is casted on become invulnerable for 10 seconds, and then once the 10 seconds runs out, allies within 900 of the unit heal for 400.
It works fine in game, i'm just worried that there may be some leaks since im so new at this :O
Thank you!
Here is the trigger
Code:
Divination
Events
Unit - A unit Begins casting an ability
Conditions
(Ability being cast) Equal to Divination
Actions
Set DivinationTarget[12] = (Target unit of ability being cast)
Set DivinationLoc = (Position of DivinationTarget[12])
Set DivinationGroup = (Units within 900.00 of (Position of (Target unit of ability being cast)))
Set Sfx2[12] = (Last created special effect)
Special Effect - Create a special effect attached to the chest of (Target unit of ability being cast) using Abilities\Spells\Human\DivineShield\DivineShieldTarget.mdl
Unit - Make (Target unit of ability being cast) Invulnerable
Wait 10.00 game-time seconds
Special Effect - Destroy Sfx2[12]
Unit - Make DivinationTarget[12] Vulnerable
Unit Group - Pick every unit in DivinationGroup and do (Actions)
Loop - Actions
Unit - Set life of (Picked unit) to ((Life of (Picked unit)) + 400.00)
Special Effect - Create a special effect attached to the chest of (Picked unit) using Abilities\Spells\Human\HolyBolt\HolyBoltSpecialArt.mdl
Special Effect - Destroy (Last created special effect)
Custom script: call RemoveLocation (udg_DivinationLoc)
Custom script: call DestroyGroup (udg_DivinationGroup)
Thanks!