• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

Skill Wave Triggers

Status
Not open for further replies.
Level 1
Joined
Feb 23, 2020
Messages
3
Iv'e been trying to create a spell that splashes damage and effect 5 times every 1 second but it seems like it doesn't work. I'm so bad at triggers. I need help
on this one

Configuration
  • RTBN Configuration
    • Events
      • Map initialization
    • Conditions
    • Actions
      • -------- ----- --------
      • -------- Ability --------
      • -------- ----- --------
      • Set R_Ability = Retribution
      • -------- ----- --------
      • -------- Dummy Unit --------
      • -------- ----- --------
      • Set R_Dummy = Dummy
      • -------- ----- --------
      • -------- Damage --------
      • -------- ----- --------
      • Set R_Damage[1] = 150.00
      • Set R_Damage[2] = 250.00
      • Set R_Damage[3] = 350.00
      • -------- ----- --------
      • -------- Damage Area --------
      • -------- ----- --------
      • Set R_Area[1] = 300.00
      • Set R_Area[2] = 320.00
      • Set R_Area[3] = 350.00
      • -------- ----- --------
      • -------- Special Effects --------
      • -------- ----- --------
      • Set R_SFX = war3mapImported\AnnihilationBlast.mdl
      • Set R_GSFX = war3mapImported\AnnihilationTarget.mdl
      • -------- ----- --------
      • -------- Size --------
      • -------- ----- --------
      • Set R_SizeL = 65.00
      • Set R_SizeW = 60.00
      • Set R_SizeH = 60.00
      • -------- ----- --------
      • -------- Color --------
      • -------- ----- --------
      • Set R_Red = 100.00
      • Set R_Green = 100.00
      • Set R_Blue = 0.00
      • -------- ----- --------
      • -------- Damage and Attack Type --------
      • -------- ----- --------
      • Set R_Attack_Type = Normal
      • Set R_Damage_Type = Magic
Execution
  • RTBN Execution
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to R_Ability
    • Actions
      • -------- ------------- --------
      • Set R_Index = (R_Index + 1)
      • Set R_Caster[R_Index] = (Triggering unit)
      • Set R_AbilityLevel[R_Index] = (Level of R_Ability for R_Caster[R_Index])
      • Set R_PointLoc = (Target point of ability being cast)
      • -------- ------------- --------
      • Unit - Create 1 R_Dummy for (Owner of R_Caster[R_Index]) at R_PointLoc facing Default building facing degrees
      • Set R_DummyTemp[R_Index] = (Last created unit)
      • Unit - Add a 5.00 second Generic expiration timer to R_DummyTemp[R_Index]
      • Custom script: call RemoveLocation(udg_R_PointLoc)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • R_Index Equal to 1
        • Then - Actions
          • Trigger - Turn on RTBN Loop <gen>
        • Else - Actions
Loop
  • RTBN Loop
    • Events
      • Time - Every 1.00 seconds of game time
    • Conditions
    • Actions
      • For each (Integer R_Loop_Integer) from 1 to R_Index, do (Actions)
        • Loop - Actions
          • Set R_PointLoc = (Target point of ability being cast)
          • -------- Animation --------
          • -------- Changing the Size and Color of the Effect --------
          • -------- Applying the effects to dummy unit --------
          • Animation - Add the R_GSFX animation tag to R_DummyTemp[R_Index]
          • Animation - Change R_DummyTemp[R_Index]'s size to (R_SizeL%, R_SizeW%, R_SizeH%) of its original size
          • Animation - Change R_DummyTemp[R_Index]'s vertex coloring to (R_Red%, R_Green%, R_Blue%) with 0.00% transparency
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • R_Index Greater than or equal to 1
            • Then - Actions
              • Set R_DamageGroup = (Units within R_Area[R_Index] of R_PointLoc)
              • Unit Group - Pick every unit in R_DamageGroup and do (Actions)
                • Loop - Actions
                  • -------- Adding Unit Variable --------
                  • Set R_TempUnit = (Picked unit)
                  • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    • If - Conditions
                      • (R_TempUnit is Magic Immune) Equal to False
                      • (R_TempUnit belongs to an ally of (Owner of R_Caster[R_Index])) Equal to False
                    • Then - Actions
                      • -------- Dealing damage to units --------
                      • Unit - Cause R_Caster[R_Index] to damage R_TempUnit, dealing R_Damage[R_AbilityLevel[R_Index]] damage of attack type R_Attack_Type and damage type R_Damage_Type
                    • Else - Actions
              • Custom script: call DestroyGroup(udg_R_DamageGroup)
              • -------- Applying Special Effects --------
              • Special Effect - Create a special effect at R_PointLoc using R_SFX
              • Set R_LCSFX = (Last created special effect)
              • Special Effect - Destroy R_LCSFX
            • Else - Actions
          • Custom script: call RemoveLocation(udg_R_PointLoc)
 
Last edited:
Level 25
Joined
Feb 9, 2009
Messages
1,798
Where's your de-index?

upload_2020-3-17_13-35-45.png

Every value in the index must be reshuffled back into the index.
Let me shamble together something here real quick...


oh and something I noticed:
upload_2020-3-17_14-12-42.png



K here's my take on it:
(Should be MUI, anyone is free to twist my arm around to tell me if I made a boo boo~)
Retribution | HIVE
& the Triggers:
Init
  • ReTr Init
    • Events
      • Map initialization
    • Conditions
    • Actions
      • Set ReTr_Config_Periodic_Timer = 0.05
      • Trigger - Add to ReTr Loop <gen> the event (Time - Every ReTr_Config_Periodic_Timer seconds of game time)
      • -------- --------
      • Set ReTr_Ability_ID = Retribution
      • -------- --------
      • Set ReTr_Config_AOE[1] = 300.00
      • Set ReTr_Config_AOE[2] = 320.00
      • Set ReTr_Config_AOE[3] = 350.00
      • -------- --------
      • Set ReTr_Config_ATK_T = Normal
      • Set ReTr_Config_DAM_T = Magic
      • -------- --------
      • Set ReTr_Config_Damage[1] = 150.00
      • Set ReTr_Config_Damage[2] = 250.00
      • Set ReTr_Config_Damage[3] = 350.00
      • -------- --------
      • Set ReTr_Config_T_Duration[1] = 5.00
      • Set ReTr_Config_T_Duration[2] = 5.00
      • Set ReTr_Config_T_Duration[3] = 5.00
      • -------- --------
      • Set ReTr_Config_Tick[1] = 1.00
      • Set ReTr_Config_Tick[2] = 1.00
      • Set ReTr_Config_Tick[3] = 1.00
      • -------- --------
      • Set ReTr_Config_Size[1] = 0.65
      • Set ReTr_Config_Size[2] = 0.65
      • Set ReTr_Config_Size[3] = 0.65
      • -------- --------
      • Set ReTr_Config_Z_height[1] = 20.00
      • Set ReTr_Config_Z_height[2] = 20.00
      • Set ReTr_Config_Z_height[3] = 20.00
      • -------- --------
      • Set ReTr_Config_SFX = war3mapImported\AnnihilationBlast.mdx
      • Set ReTr_Config_GSFX = war3mapImported\AnnihilationTarget.mdx
      • -------- --------
      • Set ReTr_z_Point[0] = (Center of (Playable map area))
      • Unit - Create 1 Albatross for Neutral Hostile at ReTr_z_Point[0] facing Default building facing degrees
      • Unit - Add ReTr_Ability_ID to (Last created unit)
      • Unit - Hide (Last created unit)
      • Unit - Add a 0.01 second Generic expiration timer to (Last created unit)
      • Custom script: call RemoveLocation(udg_ReTr_z_Point[0])
      • -------- --------
Cast
  • ReTr Cast
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to ReTr_Ability_ID
    • Actions
      • Set ReTr_Index = (ReTr_Index + 1)
      • Set ReTr_z_Caster[ReTr_Index] = (Triggering unit)
      • Set ReTr_z_Level[ReTr_Index] = (Level of ReTr_Ability_ID for ReTr_z_Caster[ReTr_Index])
      • Set ReTr_z_Damage[ReTr_Index] = ReTr_Config_Damage[ReTr_z_Level[ReTr_Index]]
      • Set ReTr_z_T_Duration[ReTr_Index] = ReTr_Config_T_Duration[ReTr_z_Level[ReTr_Index]]
      • Set ReTr_z_Point[1] = (Target point of ability being cast)
      • Special Effect - Create a special effect at ReTr_z_Point[1] using ReTr_Config_GSFX
      • Special Effect - Set Color of (Last created special effect) to r: 255, g: 255, b: 0
      • Special Effect - Set Position - Z of (Last created special effect) to ((Position - Z of (Last created special effect)) + ReTr_Config_Z_height[ReTr_z_Level[ReTr_Index]])
      • Special Effect - Set Scale of (Last created special effect) to ReTr_Config_Size[ReTr_z_Level[ReTr_Index]]
      • Set ReTr_z_SPEF[ReTr_Index] = (Last created special effect)
      • Custom script: call RemoveLocation(udg_ReTr_z_Point[1])
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • ReTr_Index Equal to 1
        • Then - Actions
          • Trigger - Turn on ReTr Loop <gen>
        • Else - Actions
Loop
  • ReTr Loop
    • Events
    • Conditions
    • Actions
      • -------- --------
      • For each (Integer ReTr_Loop) from 1 to ReTr_Index, do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • ReTr_z_T_Duration[ReTr_Loop] Equal to 0.00
            • Then - Actions
              • Special Effect - Destroy ReTr_z_SPEF[ReTr_Loop]
              • Set ReTr_z_Caster[ReTr_Loop] = ReTr_z_Caster[ReTr_Loop]
              • Set ReTr_z_Level[ReTr_Loop] = ReTr_z_Level[ReTr_Index]
              • Set ReTr_z_Damage[ReTr_Loop] = ReTr_z_Damage[ReTr_Index]
              • Set ReTr_z_T_Duration[ReTr_Loop] = ReTr_z_T_Duration[ReTr_Index]
              • Set ReTr_z_SPEF[ReTr_Loop] = ReTr_z_SPEF[ReTr_Index]
              • Set ReTr_Index = (ReTr_Index - 1)
              • Set ReTr_Loop = (ReTr_Loop - 1)
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • ReTr_Index Equal to 0
                • Then - Actions
                  • Trigger - Turn off (This trigger)
                • Else - Actions
            • Else - Actions
              • Set ReTr_z_T_Duration[ReTr_Loop] = (ReTr_z_T_Duration[ReTr_Loop] - ReTr_Config_Periodic_Timer)
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • (ReTr_z_T_Duration[ReTr_Loop] mod ReTr_Config_Tick[ReTr_z_Level[ReTr_Loop]]) Greater than or equal to (ReTr_Config_Tick[ReTr_z_Level[ReTr_Loop]] - ReTr_Config_Periodic_Timer)
                • Then - Actions
                  • Set ReTr_z_Point[2] = (Point((Position - X of ReTr_z_SPEF[ReTr_Loop]), (Position - Y of ReTr_z_SPEF[ReTr_Loop])))
                  • Special Effect - Create a special effect at ReTr_z_Point[2] using ReTr_Config_SFX
                  • Special Effect - Set Color of (Last created special effect) to r: 255, g: 255, b: 0
                  • Special Effect - Set Scale of (Last created special effect) to ReTr_Config_Size[ReTr_z_Level[ReTr_Loop]]
                  • Special Effect - Set Position - Z of (Last created special effect) to ((Position - Z of (Last created special effect)) + ReTr_Config_Z_height[ReTr_z_Level[ReTr_Loop]])
                  • Special Effect - Destroy (Last created special effect)
                  • Custom script: set bj_wantDestroyGroup = true
                  • Unit Group - Pick every unit in (Units within ReTr_Config_AOE[ReTr_z_Level[ReTr_Loop]] of ReTr_z_Point[2]) and do (Actions)
                    • Loop - Actions
                      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                        • If - Conditions
                          • ((Picked unit) is A structure) Equal to False
                          • ((Picked unit) is Magic Immune) Equal to False
                          • ((Picked unit) is alive) Equal to True
                          • ((Picked unit) belongs to an enemy of (Owner of ReTr_z_Caster[ReTr_Loop])) Equal to True
                        • Then - Actions
                          • Unit - Cause ReTr_z_Caster[ReTr_Loop] to damage (Picked unit), dealing (ReTr_Config_Damage[ReTr_z_Level[ReTr_Loop]] / (ReTr_Config_T_Duration[ReTr_z_Level[ReTr_Loop]] / ReTr_Config_Tick[ReTr_z_Level[ReTr_Loop]])) damage of attack type ReTr_Config_ATK_T and damage type ReTr_Config_DAM_T
                        • Else - Actions
                  • Custom script: call RemoveLocation(udg_ReTr_z_Point[2])
                • Else - Actions
      • -------- --------

Oh, and if the "Math - Modulo" bit is too difficult just add another variable and subtract from it much like T_Duration, and then reset it back to the Config Tick once you deal the area damage.
 
Last edited:
Level 1
Joined
Feb 23, 2020
Messages
3
Where's your de-index?

View attachment 349677
Every value in the index must be reshuffled back into the index.
Let me shamble together something here real quick...


oh and something I noticed:
View attachment 349680


K here's my take on it:
(Should be MUI, anyone is free to twist my arm around to tell me if I made a boo boo~)
Retribution | HIVE
& the Triggers:
Init
  • ReTr Init
    • Events
      • Map initialization
    • Conditions
    • Actions
      • Set ReTr_Config_Periodic_Timer = 0.05
      • Trigger - Add to ReTr Loop <gen> the event (Time - Every ReTr_Config_Periodic_Timer seconds of game time)
      • -------- --------
      • Set ReTr_Ability_ID = Retribution
      • -------- --------
      • Set ReTr_Config_AOE[1] = 300.00
      • Set ReTr_Config_AOE[2] = 320.00
      • Set ReTr_Config_AOE[3] = 350.00
      • -------- --------
      • Set ReTr_Config_ATK_T = Normal
      • Set ReTr_Config_DAM_T = Magic
      • -------- --------
      • Set ReTr_Config_Damage[1] = 150.00
      • Set ReTr_Config_Damage[2] = 250.00
      • Set ReTr_Config_Damage[3] = 350.00
      • -------- --------
      • Set ReTr_Config_T_Duration[1] = 5.00
      • Set ReTr_Config_T_Duration[2] = 5.00
      • Set ReTr_Config_T_Duration[3] = 5.00
      • -------- --------
      • Set ReTr_Config_Tick[1] = 1.00
      • Set ReTr_Config_Tick[2] = 1.00
      • Set ReTr_Config_Tick[3] = 1.00
      • -------- --------
      • Set ReTr_Config_Size[1] = 0.65
      • Set ReTr_Config_Size[2] = 0.65
      • Set ReTr_Config_Size[3] = 0.65
      • -------- --------
      • Set ReTr_Config_Z_height[1] = 20.00
      • Set ReTr_Config_Z_height[2] = 20.00
      • Set ReTr_Config_Z_height[3] = 20.00
      • -------- --------
      • Set ReTr_Config_SFX = war3mapImported\AnnihilationBlast.mdx
      • Set ReTr_Config_GSFX = war3mapImported\AnnihilationTarget.mdx
      • -------- --------
      • Set ReTr_z_Point[0] = (Center of (Playable map area))
      • Unit - Create 1 Albatross for Neutral Hostile at ReTr_z_Point[0] facing Default building facing degrees
      • Unit - Add ReTr_Ability_ID to (Last created unit)
      • Unit - Hide (Last created unit)
      • Unit - Add a 0.01 second Generic expiration timer to (Last created unit)
      • Custom script: call RemoveLocation(udg_ReTr_z_Point[0])
      • -------- --------
Cast
  • ReTr Cast
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to ReTr_Ability_ID
    • Actions
      • Set ReTr_Index = (ReTr_Index + 1)
      • Set ReTr_z_Caster[ReTr_Index] = (Triggering unit)
      • Set ReTr_z_Level[ReTr_Index] = (Level of ReTr_Ability_ID for ReTr_z_Caster[ReTr_Index])
      • Set ReTr_z_Damage[ReTr_Index] = ReTr_Config_Damage[ReTr_z_Level[ReTr_Index]]
      • Set ReTr_z_T_Duration[ReTr_Index] = ReTr_Config_T_Duration[ReTr_z_Level[ReTr_Index]]
      • Set ReTr_z_Point[1] = (Target point of ability being cast)
      • Special Effect - Create a special effect at ReTr_z_Point[1] using ReTr_Config_GSFX
      • Special Effect - Set Color of (Last created special effect) to r: 255, g: 255, b: 0
      • Special Effect - Set Position - Z of (Last created special effect) to ((Position - Z of (Last created special effect)) + ReTr_Config_Z_height[ReTr_z_Level[ReTr_Index]])
      • Special Effect - Set Scale of (Last created special effect) to ReTr_Config_Size[ReTr_z_Level[ReTr_Index]]
      • Set ReTr_z_SPEF[ReTr_Index] = (Last created special effect)
      • Custom script: call RemoveLocation(udg_ReTr_z_Point[1])
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • ReTr_Index Equal to 1
        • Then - Actions
          • Trigger - Turn on ReTr Loop <gen>
        • Else - Actions
Loop
  • ReTr Loop
    • Events
    • Conditions
    • Actions
      • -------- --------
      • For each (Integer ReTr_Loop) from 1 to ReTr_Index, do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • ReTr_z_T_Duration[ReTr_Loop] Equal to 0.00
            • Then - Actions
              • Special Effect - Destroy ReTr_z_SPEF[ReTr_Loop]
              • Set ReTr_z_Caster[ReTr_Loop] = ReTr_z_Caster[ReTr_Loop]
              • Set ReTr_z_Level[ReTr_Loop] = ReTr_z_Level[ReTr_Index]
              • Set ReTr_z_Damage[ReTr_Loop] = ReTr_z_Damage[ReTr_Index]
              • Set ReTr_z_T_Duration[ReTr_Loop] = ReTr_z_T_Duration[ReTr_Index]
              • Set ReTr_z_SPEF[ReTr_Loop] = ReTr_z_SPEF[ReTr_Index]
              • Set ReTr_Index = (ReTr_Index - 1)
              • Set ReTr_Loop = (ReTr_Loop - 1)
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • ReTr_Index Equal to 0
                • Then - Actions
                  • Trigger - Turn off (This trigger)
                • Else - Actions
            • Else - Actions
              • Set ReTr_z_T_Duration[ReTr_Loop] = (ReTr_z_T_Duration[ReTr_Loop] - ReTr_Config_Periodic_Timer)
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • (ReTr_z_T_Duration[ReTr_Loop] mod ReTr_Config_Tick[ReTr_z_Level[ReTr_Loop]]) Greater than or equal to (ReTr_Config_Tick[ReTr_z_Level[ReTr_Loop]] - ReTr_Config_Periodic_Timer)
                • Then - Actions
                  • Set ReTr_z_Point[2] = (Point((Position - X of ReTr_z_SPEF[ReTr_Loop]), (Position - Y of ReTr_z_SPEF[ReTr_Loop])))
                  • Special Effect - Create a special effect at ReTr_z_Point[2] using ReTr_Config_SFX
                  • Special Effect - Set Color of (Last created special effect) to r: 255, g: 255, b: 0
                  • Special Effect - Set Scale of (Last created special effect) to ReTr_Config_Size[ReTr_z_Level[ReTr_Loop]]
                  • Special Effect - Set Position - Z of (Last created special effect) to ((Position - Z of (Last created special effect)) + ReTr_Config_Z_height[ReTr_z_Level[ReTr_Loop]])
                  • Special Effect - Destroy (Last created special effect)
                  • Custom script: set bj_wantDestroyGroup = true
                  • Unit Group - Pick every unit in (Units within ReTr_Config_AOE[ReTr_z_Level[ReTr_Loop]] of ReTr_z_Point[2]) and do (Actions)
                    • Loop - Actions
                      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                        • If - Conditions
                          • ((Picked unit) is A structure) Equal to False
                          • ((Picked unit) is Magic Immune) Equal to False
                          • ((Picked unit) is alive) Equal to True
                          • ((Picked unit) belongs to an enemy of (Owner of ReTr_z_Caster[ReTr_Loop])) Equal to True
                        • Then - Actions
                          • Unit - Cause ReTr_z_Caster[ReTr_Loop] to damage (Picked unit), dealing (ReTr_Config_Damage[ReTr_z_Level[ReTr_Loop]] / (ReTr_Config_T_Duration[ReTr_z_Level[ReTr_Loop]] / ReTr_Config_Tick[ReTr_z_Level[ReTr_Loop]])) damage of attack type ReTr_Config_ATK_T and damage type ReTr_Config_DAM_T
                        • Else - Actions
                  • Custom script: call RemoveLocation(udg_ReTr_z_Point[2])
                • Else - Actions
      • -------- --------

Thanks! i really appreciate it! i needed this for my custom map ^_^

Oh, and if the "Math - Modulo" bit is too difficult just add another variable and subtract from it much like T_Duration, and then reset it back to the Config Tick once you deal the area damage.
 
Status
Not open for further replies.
Top