Status
Coding : GUI/Trigger
Spell Type : MUI
Ability Description
Create a word "FAIL" that would fall from the sky. Each word deal 50 damage to any enemy within 300 range and higher level reduce the mana cost and cooldown.
Level 1 - 45 seconds cooldown, 90 mana cost.
Level 2 - 30 seconds cooldown, 75 mana cost.
Level 3 - 15 seconds cooldown, 60 mana cost.
Version 1.02 Update
Fix documentation error.
Further optimize the code.
Version 1.01
Reconstruct the entire spell, more efficient and have additional effect (Full credit for reconstruct goes to Rmx).
Add RED BARON to credit list.
Change tooltips description.
Change the falling angle of the word.
Enable user to adjust the falling speed at much easier way.
Custom values no longer been use.
Trigger:
- FAIL On
- Events
- Unit - A unit Starts the effect of an ability
- Conditions
- (Ability being cast) Equal to FAIL
- Actions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- If - Conditions
- FAIL_Skip Equal to 0
- Then - Actions
- Trigger - Turn on FAIL Loop <gen>
- Else - Actions
- If - Conditions
- Set FAIL = 1
- Set F_Point[1] = (Target point of ability being cast)
- For each (Integer F_Spawn) from 1 to 4, do (Actions)
- Loop - Actions
- Set FAIL_Times = (FAIL_Times + 1)
- Set FAIL_Skip = (FAIL_Skip + 1)
- Set FAIL_Off[FAIL_Times] = True
- Set Sheep_Off[FAIL_Times] = False
- Set F_Hero[FAIL_Times] = (Casting unit)
- Set F_Speed[FAIL_Times] = 2.00
- Set F_Distance[FAIL_Times] = (800.00 - ((Real(FAIL)) x 100.00))
- Set F_Distance[FAIL_Times] = (F_Distance[FAIL_Times] + 265.00)
- Set F_Point[2] = (F_Point[1] offset by F_Distance[FAIL_Times] towards 180.00 degrees)
- Set F_Height[FAIL_Times] = 800.00
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- If - Conditions
- FAIL Equal to 1
- Then - Actions
- Unit - Create 1 F for (Owner of F_Hero[FAIL_Times]) at F_Point[2] facing 0.00 degrees
- Set F_Unit[FAIL_Times] = (Last created unit)
- Animation - Change F_Unit[FAIL_Times] flying height to F_Height[FAIL_Times] at 0.00
- Unit - Turn collision for F_Unit[FAIL_Times] Off
- Else - Actions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- If - Conditions
- FAIL Equal to 2
- Then - Actions
- Unit - Create 1 A for (Owner of F_Hero[FAIL_Times]) at F_Point[2] facing 0.00 degrees
- Set F_Unit[FAIL_Times] = (Last created unit)
- Animation - Change F_Unit[FAIL_Times] flying height to F_Height[FAIL_Times] at 0.00
- Unit - Turn collision for F_Unit[FAIL_Times] Off
- Else - Actions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- If - Conditions
- FAIL Equal to 3
- Then - Actions
- Unit - Create 1 I for (Owner of F_Hero[FAIL_Times]) at F_Point[2] facing 270.00 degrees
- Set F_Unit[FAIL_Times] = (Last created unit)
- Animation - Change F_Unit[FAIL_Times] flying height to F_Height[FAIL_Times] at 0.00
- Unit - Turn collision for F_Unit[FAIL_Times] Off
- Else - Actions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- If - Conditions
- FAIL Equal to 4
- Then - Actions
- Unit - Create 1 L for (Owner of F_Hero[FAIL_Times]) at F_Point[2] facing 270.00 degrees
- Set F_Unit[FAIL_Times] = (Last created unit)
- Animation - Change F_Unit[FAIL_Times] flying height to F_Height[FAIL_Times] at 0.00
- Unit - Turn collision for F_Unit[FAIL_Times] Off
- Else - Actions
- If - Conditions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- If - Conditions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- If - Conditions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- If - Conditions
- Custom script: call RemoveLocation(udg_F_Point[2])
- Set FAIL = (FAIL + 1)
- Loop - Actions
- Custom script: call RemoveLocation(udg_F_Point[1])
- Set FAIL = 0
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- Events
Trigger:
- FAIL Loop
- Events
- Time - Every 0.02 seconds of game time
- Conditions
- Actions
- For each (Integer F) from 1 to FAIL_Times, do (Actions)
- Loop - Actions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- If - Conditions
- FAIL_Off[F] Equal to True
- Then - Actions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- If - Conditions
- F_Height[F] Less than or equal to 15.00
- Then - Actions
- Set FAIL_Off[F] = False
- Set FAIL_Skip = (FAIL_Skip - 1)
- Set F_Targ[1] = (Position of F_Unit[F])
- Special Effect - Create a special effect at F_Targ[1] using Objects\Spawnmodels\Human\HCancelDeath\HCancelDeath.mdl
- Special Effect - Destroy (Last created special effect)
- Set F_Group[F] = (Units within 300.00 of F_Targ[1] matching (((Owner of (Matching unit)) Not equal to (Owner of F_Hero[F])) and (((Matching unit) is alive) Equal to True)))
- Unit Group - Pick every unit in F_Group[F] and do (Actions)
- Loop - Actions
- Unit - Cause F_Hero[F] to damage (Picked unit), dealing 50.00 damage of attack type Spells and damage type Normal
- Loop - Actions
- Custom script: call DestroyGroup(udg_F_Group[udg_F])
- Unit - Remove F_Unit[F] from the game
- Set F_Unit[F] = No unit
- Set F_Hero[F] = No unit
- For each (Integer Sheep_Integer) from 1 to 8, do (Actions)
- Loop - Actions
- Set FAIL_Times = (FAIL_Times + 1)
- Set FAIL_Skip = (FAIL_Skip + 1)
- Set FAIL_Off[FAIL_Times] = False
- Set Sheep_Off[FAIL_Times] = True
- Set F_Speed[FAIL_Times] = 10.00
- Set F_Distance[FAIL_Times] = (Random real number between 300.00 and 500.00)
- Set F_Angle[FAIL_Times] = (Random angle)
- Unit - Create 1 Sheep for Neutral Passive at F_Targ[1] facing F_Angle[FAIL_Times] degrees
- Set F_Unit[FAIL_Times] = (Last created unit)
- Loop - Actions
- Custom script: call RemoveLocation(udg_F_Targ[1])
- Set F_Speed[F] = 0.00
- Set F_Distance[F] = 0.00
- Set F_Height[F] = 0.00
- Else - Actions
- Set F_Distance[F] = (F_Distance[F] - F_Speed[F])
- Set F_Point[3] = (Position of F_Unit[F])
- Set F_Point[4] = (F_Point[3] offset by F_Speed[F] towards 360.00 degrees)
- Unit - Move F_Unit[F] instantly to F_Point[4]
- Custom script: call RemoveLocation(udg_F_Point[3])
- Custom script: call RemoveLocation(udg_F_Point[4])
- Set F_Height[F] = (F_Height[F] - F_Speed[F])
- Animation - Change F_Unit[F] flying height to F_Height[F] at 0.00
- If - Conditions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- Else - Actions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- If - Conditions
- Sheep_Off[F] Equal to True
- Then - Actions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- If - Conditions
- F_Distance[F] Less than or equal to 0.00
- Then - Actions
- Set Sheep_Off[F] = False
- Set FAIL_Skip = (FAIL_Skip - 1)
- Set F_Targ[1] = (Position of F_Unit[F])
- Special Effect - Create a special effect at F_Targ[1] using Objects\Spawnmodels\Other\ToonBoom\ToonBoom.mdl
- Special Effect - Destroy (Last created special effect)
- Custom script: call RemoveLocation(udg_F_Targ[1])
- Unit - Remove F_Unit[F] from the game
- Set F_Unit[F] = No unit
- Set F_Speed[F] = 0.00
- Set F_Distance[F] = 0.00
- Set F_Angle[F] = 0.00
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- If - Conditions
- FAIL_Skip Equal to 0
- Then - Actions
- Set FAIL_Times = 0
- Trigger - Turn off FAIL Loop <gen>
- Else - Actions
- If - Conditions
- Else - Actions
- If - Conditions
- Set F_Distance[F] = (F_Distance[F] - F_Speed[F])
- Set F_Point[3] = (Position of F_Unit[F])
- Set F_Point[4] = (F_Point[3] offset by F_Speed[F] towards F_Angle[F] degrees)
- Unit - Move F_Unit[F] instantly to F_Point[4]
- Custom script: call RemoveLocation(udg_F_Point[3])
- Custom script: call RemoveLocation(udg_F_Point[4])
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- Else - Actions
- If - Conditions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- If - Conditions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- Loop - Actions
- For each (Integer F) from 1 to FAIL_Times, do (Actions)
- Events