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!
How can I make a spell that damages(or effects in anyway) only undead units? For example I want a crushing wave spell that instantly kills any undead units in front of it, but does no harm to living enemies.
-------- Search for units around the Shockwave and deal Damage (You could add other effects here besides damage) --------
Custom script: set bj_wantDestroyGroup = true
Unit Group - Pick every unit in (Units within SW_AoE[SW_Loop] of SW_Point[0].) and do (Actions)
Loop - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
((Picked unit) belongs to an enemy of (Owner of SW_Caster[SW_Index]).) Equal to True
((Picked unit) is alive) Equal to True
((Picked unit) is A ground unit) Equal to True
((Picked unit) is Magic Immune) Equal to False
((Picked unit) is hidden) Equal to False
((Picked unit) is invulnerable) Equal to False
((Picked unit) is in SW_HitGroup[SW_Loop].) Equal to False
Then - Actions
Unit Group - Add (Picked unit) to SW_HitGroup[SW_Loop]
Unit - Cause SW_Caster[SW_Loop] to damage (Picked unit), dealing SW_Damage[SW_Loop] damage of attack type SW_AttackType[SW_Loop] and damage type SW_DamageType[SW_Loop]
Set VariableSet SW_Caster[SW_Loop] = SW_Caster[SW_Index]
Set VariableSet SW_Point[SW_Loop] = SW_Point[SW_Index]
Set VariableSet SW_Angle[SW_Loop] = SW_Angle[SW_Index]
Set VariableSet SW_Missile[SW_Loop] = SW_Missile[SW_Index]
Set VariableSet SW_Speed[SW_Loop] = SW_Speed[SW_Index]
Set VariableSet SW_Height[SW_Loop] = SW_Height[SW_Index]
Set VariableSet SW_Counter[SW_Loop] = SW_Counter[SW_Index]
Set VariableSet SW_CounterMax[SW_Loop] = SW_CounterMax[SW_Loop]
Set VariableSet SW_Distance[SW_Loop] = SW_Distance[SW_Index]
Set VariableSet SW_Damage[SW_Loop] = SW_Damage[SW_Index]
Set VariableSet SW_DamageType[SW_Loop] = SW_DamageType[SW_Index]
Set VariableSet SW_AttackType[SW_Loop] = SW_AttackType[SW_Index]
Set VariableSet SW_AoE[SW_Loop] = SW_AoE[SW_Index]
Set VariableSet SW_HitGroup[SW_Loop] = SW_HitGroup[SW_Index]
-------- --------
Set VariableSet SW_Index = (SW_Index - 1)
Set VariableSet SW_Loop = (SW_Loop - 1)
-------- --------
-------- Turn off the Timer if there are no more Shockwaves --------
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
SW_Index Equal to 0
Then - Actions
Countdown Timer - Pause SW_Timer
Else - Actions
Else - Actions
To configure the settings to your liking:
Simply edit the settings listed under -------- CONFIGURE Settings: -------- in the Custom Shockwave Cast trigger:
Actions
-------- CONFIGURE Settings: --------
Set VariableSet SW_Damage[SW_Index] = 100.00
Set VariableSet SW_DamageType[SW_Index] = Magic
Set VariableSet SW_AttackType[SW_Index] = Spells
Set VariableSet SW_Speed[SW_Index] = 25.00
Set VariableSet SW_Height[SW_Index] = 60.00
Set VariableSet SW_AoE[SW_Index] = 200.00
-------- --------
-------- Counter is increased by 1 every 0.03 seconds. Once this Counter reaches SW_CounterMax the missile is destroyed --------
-------- By default I set CounterMax to 40, which is equal to 1.20 seconds ---> 0.03 * 40 = 1.20 --------
Set VariableSet SW_CounterMax[SW_Index] = 40
You can also edit the If - Conditions in the Custom Shockwave Timer trigger to modify the Targets Allowed. By default I have settings similar to the standard Shockwave ability:
Unit Group - Pick every unit in (Units within SW_AoE[SW_Loop] of SW_Point[0].) and do (Actions)
Loop - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
((Picked unit) belongs to an enemy of (Owner of SW_Caster[SW_Index]).) Equal to True
((Picked unit) is alive) Equal to True
((Picked unit) is A ground unit) Equal to True
((Picked unit) is Magic Immune) Equal to False
((Picked unit) is hidden) Equal to False
((Picked unit) is invulnerable) Equal to False
((Picked unit) is in SW_HitGroup[SW_Loop].) Equal to False
Then - Actions
Unit Group - Add (Picked unit) to SW_HitGroup[SW_Loop]
Unit - Cause SW_Caster[SW_Loop] to damage (Picked unit), dealing SW_Damage[SW_Loop] damage of attack type SW_AttackType[SW_Loop] and damage type SW_DamageType[SW_Loop]
Else - Actions
I attached pictures to show you how to modify the spell to kill Undead units instantly.
The attached map requires the most recent version of Warcraft 3.
Edit: Updated the map to fix some minor bugs. Map name changed from Custom Shockwave to Custom Shockwave v.1.
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.