Holy Light Damage

Events


Unit - A unit Starts the effect of an ability

Conditions


(Ability being cast) Equal to Holy Light

Actions


Set DamageEventType = 1


Set DMGS_Ability = (Ability being cast)


Unit - Cause (Triggering unit) to damage (Target unit of ability being cast), dealing 100.00 damage of attack type Spells and damage type Universal
If (All Conditions are True) then do (Then Actions) else do (Else Actions)

If - Conditions


DamageEventType Equal to 1


DMGS_Ability Equal to Holy Light

Then - Actions


Set DMGS_CriticalChance = 25.00


Set DMGS_CriticalPercent = 1.00


Set DMGS_CriticalBonus = 50.00

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

If - Conditions


DamageEventType Equal to 1


(DamageEventTarget has buff Trueshot Aura) Equal to True

Then - Actions


Set DMGS_Evasion = 50.00

Else - Actions
DMGS Config

Events


Map initialization

Conditions

Actions


-------- -------------------------------------------------------- --------


-------- Damage Modification --------


-------- -------------------------------------------------------- --------


-------- Set the system triggers --------


Set DMGS_CalculateBlock = DMGS Get Block <gen>


Set DMGS_CalculateCrit = DMGS Get Critical <gen>


Set DMGS_CalculateEvasion = DMGS Get Evasion <gen>


-------- Set the "reset" ability - this can be anything, but mustnt be something being used in the map --------


Set DMGS_ResetAbility = Watery Minion (item)


-------- -------------------------------------------------------- --------


-------- Display --------


-------- -------------------------------------------------------- --------


-------- Attack damage colour --------


Set DMGS_Colour[0] = |cffff0000


-------- Spell damage colour --------


Set DMGS_Colour[1] = |cff8000aa


-------- Text size change --------


Set DMGS_TextSizeIncrease = 1.25


Set DMGS_TextSizeDecreaseBase = 0.25


-------- Size start min/max --------


Set DMGS_SizeMax = 14.00


Set DMGS_SizeMin = 3.00


-------- How much the CURRENT/MAX health ratio affects the size of the text --------


Set DMGS_SizeHealthFactor = 100.00


-------- Default text size. If set to zero, size is based on current/max health as above --------


-------- If not set to 0, all texts will be this size (excluding critical strike) --------


Set DMGS_SizeDefault = 0.00


-------- Crit SFX and attach point --------


Set DMGS_CritSFX = Objects\Spawnmodels\Critters\Albatross\CritterBloodAlbatross.mdl


Set DMGS_CritAttach = chest
DMGS CritEvadeBlock

Events


Game - DamageModifierEvent becomes Equal to 1.00

Conditions

Actions


-------- Get Data --------


Trigger - Run DMGS_CalculateEvasion (ignoring conditions)


-------- Evasion --------


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



If - Conditions




(Random percentage) Greater than DMGS_Evasion



Then - Actions




-------- Critical --------




Trigger - Run DMGS_CalculateCrit (ignoring conditions)




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





If - Conditions






(Random percentage) Less than or equal to DMGS_CriticalChance





Then - Actions






Set DMGS_CriticalEvent = 0.00






Set DMGS_CriticalEvent = 1.00






Set DamageEventAmount = (DamageEventAmount + DMGS_CriticalBonus)






Set DamageEventAmount = (DamageEventAmount x DMGS_CriticalPercent)






Set DamageEventCritical = True






Set DMGS_CriticalEvent = 2.00





Else - Actions




-------- Block --------




Trigger - Run DMGS_CalculateBlock (ignoring conditions)




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





If - Conditions






DMGS_Block Not equal to 0.00





Then - Actions






Set DMGS_BlockEvent = 0.00






Set DMGS_BlockEvent = 1.00






-------- Reduction --------






Set DamageEventAmount = (DamageEventAmount - (DamageEventAmount x DMGS_Reduction))






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







If - Conditions








DMGS_Block Less than DamageEventAmount







Then - Actions








Set DamageEventAmount = (DamageEventAmount - DMGS_Block)







Else - Actions








Set DamageEventAmount = 0.00






Set DMGS_BlockEvent = 2.00





Else - Actions



Else - Actions




Set DMGS_EvasionEvent = 0.00




Set DMGS_EvasionEvent = 1.00




-------- Evaded --------




Set DamageEventAmount = 0.00




Set DMGS_EvasionEvent = 2.00


Set DMGS_Evasion = 0.00


Set DMGS_Block = 0.00


Set DMGS_Reduction = 0.00


Set DMGS_CriticalBonus = 0.00


Set DMGS_CriticalPercent = 0.00


Set DMGS_CriticalChance = 0.00


Set DamageEventCriticalOverride = False


Set DMGS_Ability = DMGS_ResetAbility
DMGS Display

Events


Game - DamageEvent becomes Equal to 1.00

Conditions


DamageEventAmount Not equal to 0.00

Actions


Set DMGS_TextIndex = (DMGS_TextIndex + 1)


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



If - Conditions




DMGS_SizeDefault Equal to 0.00



Then - Actions




Set DMGS_Size[DMGS_TextIndex] = (DamageEventAmount / (Life of DamageEventTarget))




Set DMGS_Size[DMGS_TextIndex] = (DMGS_Size[DMGS_TextIndex] x DMGS_SizeHealthFactor)



Else - Actions




Set DMGS_Size[DMGS_TextIndex] = DMGS_SizeDefault


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



If - Conditions




DMGS_Size[DMGS_TextIndex] Less than DMGS_SizeMin



Then - Actions




Set DMGS_Size[DMGS_TextIndex] = DMGS_SizeMin



Else - Actions




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





If - Conditions






DMGS_Size[DMGS_TextIndex] Greater than DMGS_SizeMax





Then - Actions






Set DMGS_Size[DMGS_TextIndex] = DMGS_SizeMax





Else - Actions


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



If - Conditions




DamageEventCritical Equal to True



Then - Actions




Set DMGS_Text[DMGS_TextIndex] = (DMGS_Colour[DamageEventType] + ((String((Integer(DamageEventAmount)))) + !))




Set DMGS_Size[DMGS_TextIndex] = (DMGS_Size[DMGS_TextIndex] x 1.25)




Special Effect - Create a special effect attached to the DMGS_CritAttach of DamageEventTarget using DMGS_CritSFX




Special Effect - Destroy (Last created special effect)



Else - Actions




Set DMGS_Text[DMGS_TextIndex] = (DMGS_Colour[DamageEventType] + ((String((Integer(DamageEventAmount)))) + <Empty String>))


Floating Text - Create floating text that reads DMGS_Text[DMGS_TextIndex] above DamageEventTarget with Z offset 0.00, using font size DMGS_Size[DMGS_TextIndex], color (100.00%, 100.00%, 100.00%), and 0.00% transparency


Set DMGS_Floater[DMGS_TextIndex] = (Last created floating text)


Set DMGS_Phase[DMGS_TextIndex] = 40


Set DMGS_TextSizeDecrease[DMGS_TextIndex] = DMGS_TextSizeDecreaseBase


Floating Text - Set the velocity of (Last created floating text) to 64.00 towards (Random real number between 75.00 and 105.00) degrees


Set DamageEventCritical = False


Set DamageEventType = 0
DMGS Evasion Text

Events


Game - DMGS_EvasionEvent becomes Equal to 1.00

Conditions

Actions


Set DMGS_TextIndex = (DMGS_TextIndex + 1)


Set DMGS_Size[DMGS_TextIndex] = 6.00


Set DMGS_Text[DMGS_TextIndex] = dodged!


Floating Text - Create floating text that reads DMGS_Text[DMGS_TextIndex] above DamageEventTarget with Z offset 0.00, using font size DMGS_Size[DMGS_TextIndex], color (100.00%, 100.00%, 100.00%), and 0.00% transparency


Set DMGS_Floater[DMGS_TextIndex] = (Last created floating text)


Set DMGS_Phase[DMGS_TextIndex] = 40


Set DMGS_TextSizeDecrease[DMGS_TextIndex] = DMGS_TextSizeDecreaseBase


Floating Text - Set the velocity of (Last created floating text) to 64.00 towards (Random real number between 75.00 and 105.00) degrees
DMGS Loop

Events


Time - Every 0.03 seconds of game time

Conditions

Actions


For each (Integer LoopA) from 1 to DMGS_TextIndex, do (Actions)



Loop - Actions




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





If - Conditions






DMGS_Phase[LoopA] Greater than or equal to 35





Then - Actions






-------- Phase 1: text size increases --------






Set DMGS_Size[LoopA] = (DMGS_Size[LoopA] + DMGS_TextSizeIncrease)





Else - Actions






-------- Phase 2: text size decreases --------






Set DMGS_Size[LoopA] = (DMGS_Size[LoopA] - DMGS_TextSizeDecrease[LoopA])






Set DMGS_TextSizeDecrease[LoopA] = (DMGS_TextSizeDecrease[LoopA] + 0.05)




Floating Text - Change text of DMGS_Floater[LoopA] to DMGS_Text[LoopA] using font size DMGS_Size[LoopA]




Set DMGS_Phase[LoopA] = (DMGS_Phase[LoopA] - 1)




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





If - Conditions






DMGS_Size[LoopA] Less than or equal to 0.00





Then - Actions






Floating Text - Destroy DMGS_Floater[LoopA]






-------- destroy: re-sort all float texts --------






For each (Integer LoopB) from LoopA to DMGS_TextIndex, do (Actions)







Loop - Actions








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









If - Conditions










LoopB Not equal to DMGS_TextIndex









Then - Actions










Set DMGS_Floater[LoopB] = DMGS_Floater[(LoopB + 1)]










Set DMGS_Phase[LoopB] = DMGS_Phase[(LoopB + 1)]










Set DMGS_Size[LoopB] = DMGS_Size[(LoopB + 1)]










Set DMGS_Text[LoopB] = DMGS_Text[(LoopB + 1)]










Set DMGS_TextSizeDecrease[LoopB] = DMGS_TextSizeDecrease[(LoopB + 1)]









Else - Actions






Set DMGS_TextIndex = (DMGS_TextIndex - 1)





Else - Actions