Carl-Fredrik
New Member
- Reaction score
- 51
Hi everyone!
I'm trying to simply make an unit unable to attack while using the Divine Shield (Called Spiritual State in my map), I tried to make a Silence ability and then let a dummy unit use it on the hero when it becomes invulnerable but it doesn't work for some reason :/ Any suggestions?
Thanks in advance!
// Carl-Fredrik
Edit: I saw a script earlier that removed the "Move" ability, maybe there's a script for removing Attack too? (Then I'd add it again after X seconds)
I'm trying to simply make an unit unable to attack while using the Divine Shield (Called Spiritual State in my map), I tried to make a Silence ability and then let a dummy unit use it on the hero when it becomes invulnerable but it doesn't work for some reason :/ Any suggestions?
Ability Name: Silence (Dummy)
Attacks Prevented: Melee, Ranged
Targets allowed: Air, Ground, Invulnerable, Organic, Player Units
Code:
Spiritual State
Events
Unit - A unit Starts the effect of an ability
Conditions
(Ability being cast) Equal to Spiritual State
Actions
Set SS_CasterPoint = (Position of (Triggering unit))
Unit - Create 1 Dummy [No Model] for (Owner of (Triggering unit)) at SS_CasterPoint facing Default building facing degrees
Set SS_Unit = (Last created unit)
Unit - Add Silence (Dummy) to SS_Unit
Unit - Set level of Silence (Dummy) for SS_Unit to (Level of Spiritual State for (Triggering unit))
Unit - Order SS_Unit to Neutral Dark Ranger - Silence SS_CasterPoint
Thanks in advance!
// Carl-Fredrik
Edit: I saw a script earlier that removed the "Move" ability, maybe there's a script for removing Attack too? (Then I'd add it again after X seconds)