- Joined
- Jul 28, 2007
- Messages
- 920
How can i make unit to miss or deal no damage when attacking unit???
Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
Unit - Issue (Last Created Unit) to Undead Banshee - Curse (Triggering Unit)
Unit - Remove (Last Created Unit)
Give curse

Events


Unit - A unit Is attacked

Conditions

Actions


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



If - Conditions




Or - Any (Conditions) are true





Conditions






(Unit-type of (Attacking unit)) Equal to Missile Turret (heavy)






(Unit-type of (Attacking unit)) Equal to Missile Turret (medium)






(Unit-type of (Attacking unit)) Equal to Missile Turret (unarmored)




((Attacking unit) has buff No Radar ) Equal to False



Then - Actions




Unit - Create 1 Dummy (DropCurse) for Player 1 (Red) at (Random point in Left Start <gen>) facing Default building facing (270.0) degrees




Unit - Order (Last created unit) to Undead Banshee - Curse (Attacking unit)




Unit - Remove (Last created unit) from the game




Game - Display to (All players) the text: curse



Else - Actions
Give curse

Events


Unit - A unit Is attacked

Conditions

Actions


-------- NoRadar --------


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



If - Conditions




Radar_enters_Map[(Player number of (Owner of (Attacking unit)))] Equal to 0




((Attacking unit) has buff Miss Chance 25% ) Equal to False




((Attacking unit) has buff Miss Chance 20% ) Equal to False




Or - Any (Conditions) are true





Conditions






(Unit-type of (Attacking unit)) Equal to Missile Turret (heavy)






(Unit-type of (Attacking unit)) Equal to Missile Turret (medium)






(Unit-type of (Attacking unit)) Equal to Missile Turret (unarmored)



Then - Actions




Unit - Create 1 Dummy (DropCurse25%) for Neutral Passive at CursePoint facing Default building facing (270.0) degrees




Unit - Order (Last created unit) to Undead Banshee - Curse (Attacking unit)




Unit - Remove (Last created unit) from the game



Else - Actions


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



If - Conditions




Radar_enters_Map[(Player number of (Owner of (Attacking unit)))] Equal to 0




((Attacking unit) has buff Miss Chance 15% ) Equal to False




((Attacking unit) has buff Miss Chance 10% ) Equal to False




Or - Any (Conditions) are true





Conditions






(Unit-type of (Attacking unit)) Equal to Greater Missile Turret (PH) (unarmored)






(Unit-type of (Attacking unit)) Equal to Greater Missile Turret (AAH)






(Unit-type of (Attacking unit)) Equal to Greater Missile Turret (HH)



Then - Actions




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





If - Conditions






Or - Any (Conditions) are true







Conditions








((Attacking unit) has buff Miss Chance 25% ) Equal to True








((Attacking unit) has buff Miss Chance 20% ) Equal to True





Then - Actions






Unit - Remove Miss Chance 25% buff from (Attacking unit)






Unit - Remove Miss Chance 20% buff from (Attacking unit)





Else - Actions




Unit - Create 1 Dummy (DropCurse15%) for Neutral Passive at CursePoint facing Default building facing (270.0) degrees




Unit - Order (Last created unit) to Undead Banshee - Curse (Attacking unit)




Unit - Remove (Last created unit) from the game



Else - Actions


-------- Radar --------


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



If - Conditions




Radar_enters_Map[(Player number of (Owner of (Attacking unit)))] Greater than or equal to 1




Or - Any (Conditions) are true





Conditions






((Attacking unit) has buff Miss Chance 25% ) Equal to False






((Attacking unit) has buff Miss Chance 25% ) Equal to True




((Attacking unit) has buff Miss Chance 20% ) Equal to False




Or - Any (Conditions) are true





Conditions






(Unit-type of (Attacking unit)) Equal to Missile Turret (heavy)






(Unit-type of (Attacking unit)) Equal to Missile Turret (medium)






(Unit-type of (Attacking unit)) Equal to Missile Turret (unarmored)



Then - Actions




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





If - Conditions






((Attacking unit) has buff Miss Chance 25% ) Equal to True





Then - Actions






Unit - Remove Miss Chance 25% buff from (Attacking unit)





Else - Actions




Unit - Create 1 Dummy (DropCurse20%) for Neutral Passive at CursePoint facing Default building facing (270.0) degrees




Unit - Order (Last created unit) to Undead Banshee - Curse (Attacking unit)




Unit - Remove (Last created unit) from the game



Else - Actions


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



If - Conditions




Radar_enters_Map[(Player number of (Owner of (Attacking unit)))] Greater than or equal to 1




Or - Any (Conditions) are true





Conditions






((Attacking unit) has buff Miss Chance 15% ) Equal to False






((Attacking unit) has buff Miss Chance 15% ) Equal to True




((Attacking unit) has buff Miss Chance 10% ) Equal to False




Or - Any (Conditions) are true





Conditions






(Unit-type of (Attacking unit)) Equal to Greater Missile Turret (PH) (unarmored)






(Unit-type of (Attacking unit)) Equal to Greater Missile Turret (AAH)






(Unit-type of (Attacking unit)) Equal to Greater Missile Turret (HH)



Then - Actions




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





If - Conditions






Or - Any (Conditions) are true







Conditions








((Attacking unit) has buff Miss Chance 25% ) Equal to True








((Attacking unit) has buff Miss Chance 20% ) Equal to True





Then - Actions






Unit - Remove Miss Chance 25% buff from (Attacking unit)






Unit - Remove Miss Chance 20% buff from (Attacking unit)






Unit - Remove Miss Chance 15% buff from (Attacking unit)





Else - Actions




Unit - Create 1 Dummy (DropCurse10%) for Neutral Passive at CursePoint facing Default building facing (270.0) degrees




Unit - Order (Last created unit) to Undead Banshee - Curse (Attacking unit)




Unit - Remove (Last created unit) from the game



Else - Actions
critical strike with 0 times normal damage
Captain Griffen, even still there are triggers which change unit ownership? In which case you could exchange it instantly. Even still, if that fails, you could just up it to 1 dummy per player.
Yeah, but that shows the big red "0!" floating text above your unit. Might not look quite the way he wants it to. Hence, using curse.
2. ability based
- critical strike and bash, can make the unit with the ability miss on attacks, without the units having any chance to deal bash-damage-stun or factorised-critical-damage.
- therefore you could whenever a unit attacks another one, instantly change that units custom "critical strike with no chance to deal increased damage but chance to miss" to the corresponding one (for the kind of unit attacked).
haha

Events


Time - Every 1 seconds of the game

Conditions

Actions


Unit Group - Pick all heroes(?) and do Actions



Loop - Actions




Unit - Create 1 Dummy for Who? at Who?'s position facing something...




Unit - Set level of Curse to (Percentage chance?)
Maybe I'm just being a fool, but can't you just give evasion to units? You know the spell maybe?
If you want it realistic, give units with heavy armors less evasion then units with light armor, and for archers just don't make their arrows follow the unit. (So make them like cannon.)
That would be so much more easy?
And the miss chance is determined by the attacker, not the attacked unit, which is your solution.
With evasion? No...
The miss chance is determined by the attacker, not the attacked unit.
