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.
You use damage detection system (dds) and null damage taken by unit. Additionally you show "Miss" via floating text.
In your case, you would make trigger that fires a DDS event "unit takes damage" and check if the damaged unit as well as damager are of certain unit types. If yes, null damage taken.
How can you null a damage? By increasing the hp with the exact amount of the damage taken? what if the damaged unit has full hp? The nulling will not work.
I recommend getting to know this system. It might answer your question.
Miss

Events


Unit - A unit Is attacked

Conditions


((Unit-type of (Attacked unit)) Equal to Hippogryph Rider 8) or (((Unit-type of (Attacked unit)) Equal to Dragonhawk Rider 15) or (((Unit-type of (Attacked unit)) Equal to Harpy Queen 22) or ((Unit-type of (Attacked unit)) Equal to Red Drake 29)))


(Unit-type of (Attacking unit)) Equal to Sniper Tower Level 1

Actions


Set MissChance = (Random integer number between 1 and 100)


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



If - Conditions




MissChance Equal to (Random integer number between 1 and 60)



Then - Actions




Unit - Set life of (Attacked unit) to ((Life of (Attacked unit)) + (Damage taken))




Floating Text - Create floating text that reads Miss above (Attacking unit) with Z offset 0.00, using font size 10.00, color (100.00%, 0.00%, 0.00%), and 0.00% transparency




Set Miss = (Last created floating text)




Floating Text - Hide Miss for (All players)




Floating Text - Show Miss for PlayersIngame




Floating Text - Set the velocity of Miss to 30.00 towards 90.00 degrees




Floating Text - Change Miss: Disable permanence




Floating Text - Change the lifespan of Miss to 4.50 seconds




Floating Text - Change the fading age of Miss to 3.00 seconds



Else - Actions




Do nothing
I used a simple damage detection system using the Event, a unit is damaged so i do not understand how the DDS with variables in the event work. Can you just tell me how if its not too complicated explaining here?
But by the looks of it, it looks like the system can change the damage the unit will take thus setting PDD_amount to zero does not damage the unit while setting it to -50 heals the unit and does not damaged it.
Essentially the system does 3 things:
*Creates a "unit takes damage" event for every unit
*Gives each unit a 200% magic damage reduction ability, making spell damage always be negative. This makes it possible to know if damage was from a basic attack(or cleave) or if it was a spell(or poison).
*Whenever a unit takes damage and the damage is modified, gives it an ability that increases max health by a lot. This avoids any possible problems with the unit dying before the health change applies.
After those steps it checks if the damage amount was changed. Since the system remembers how much health the unit had right before taking damage, then it can set it to the right value afterwards.
Events
Unit - a Unit takes damage.
Trigger - Add Event to Trigger
Trigger - Add to thisTrigger the Event
Events
Unit - a unit enters Playable Map Area
Conditions
Actions
Trigger - Add to Miss the event (Unit - Triggering Unit takes damage)
Miss

Events

Conditions


((Unit-type of (Triggering Unit) Equal to Hippogryph Rider 8) or (((Unit-type of (Triggering Unit)) Equal to Dragonhawk Rider 15) or (((Unit-type of (Triggering Unit)) Equal to Harpy Queen 22) or ((Unit-type of (Triggering Unit)) Equal to Red Drake 29)))


(Unit-type of (Damage Source)) Equal to Sniper Tower Level 1

Actions


Set MissChance = (Random integer number between 1 and 100)


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



If - Conditions




MissChance Equal to (Random integer number between 1 and 60)



Then - Actions




Unit - Set life of (Triggering Unit) to ((Life of (Triggering Unit)) + (Damage taken))




Floating Text - Create floating text that reads Miss above (Damage Source) with Z offset 0.00, using font size 10.00, color (100.00%, 0.00%, 0.00%), and 0.00% transparency




Set Miss = (Last created floating text)




Floating Text - Hide Miss for (All players)




Floating Text - Show Miss for PlayersIngame




Floating Text - Set the velocity of Miss to 30.00 towards 90.00 degrees




Floating Text - Change Miss: Disable permanence




Floating Text - Change the lifespan of Miss to 4.50 seconds




Floating Text - Change the fading age of Miss to 3.00 seconds



Else - Actions
just use one of many DDS systems here on hive, you cant get anything better than that, yet