• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

Dark Rage v.1.50

173911-albums3479-picture31412.png


TRIGGER :

  • Dark Rage Cast
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Dark Rage
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Integer(DR_Counter)) Equal to 0
        • Then - Actions
          • Trigger - Turn on Dark Rage Loop <gen>
        • Else - Actions
      • -------- --------------------------------- --------
      • Set DR_Counter = (DR_Counter + 1.00)
      • Set DR_Index = (DR_Index + 1)
      • Set DR_Caster[DR_Index] = (Casting unit)
      • Set DR_Point[DR_Index] = (Target point of ability being cast)
      • Set DR_CasterPoint[DR_Index] = (Position of DR_Caster[DR_Index])
      • -------- --------------------------------- --------
      • Set DR_Speed[DR_Index] = 50.00
      • Set DR_Angle[DR_Index] = (Angle from DR_CasterPoint[DR_Index] to DR_Point[DR_Index])
      • Set DR_Distance[DR_Index] = (Distance between DR_Point[DR_Index] and DR_CasterPoint[DR_Index])
      • Set DR_Damage[DR_Index] = (25.00 x (Real((Level of (Ability being cast) for DR_Caster[DR_Index]))))
      • -------- --------------------------------- --------
      • Set DR_Final[DR_Index] = False
      • -------- --------------------------------- --------
      • Set DR_Effect[1] = Abilities\Spells\Undead\DeathCoil\DeathCoilSpecialArt.mdl
      • Set DR_Effect[2] = Abilities\Spells\Undead\RaiseSkeletonWarrior\RaiseSkeleton.mdl
      • Set DR_Effect[3] = Abilities\Spells\Undead\AnimateDead\AnimateDeadTarget.mdl
      • Unit - Turn collision for DR_Caster[DR_Index] Off
      • Unit - Hide DR_Caster[DR_Index]
      • Custom script: call RemoveLocation(udg_DR_CasterPoint[udg_DR_Index])
  • [/hidden]
  • Dark Rage Loop
    • Events
      • Time - Every 0.04 seconds of game time
    • Conditions
    • Actions
      • For each (Integer DR_Integer) from 1 to DR_Index, do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (Integer(DR_Distance[DR_Integer])) Greater than 0
            • Then - Actions
              • Set DR_CasterPoint[DR_Integer] = (Position of DR_Caster[DR_Integer])
              • Set DR_MovePoint[DR_Integer] = (DR_CasterPoint[DR_Integer] offset by DR_Speed[DR_Integer] towards DR_Angle[DR_Integer] degrees)
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • Or - Any (Conditions) are true
                    • Conditions
                      • (Terrain pathing at DR_MovePoint[DR_Integer] of type Walkability is off) Equal to True
                      • (DR_Caster[DR_Integer] is dead) Equal to True
                • Then - Actions
                  • Set DR_Angle[DR_Integer] = (DR_Angle[DR_Integer] x (2.00 + 180.00))
                  • Set DR_Distance[DR_Integer] = (DR_Distance[DR_Integer] - DR_Speed[DR_Integer])
                • Else - Actions
                  • Unit - Move DR_Caster[DR_Integer] instantly to DR_MovePoint[DR_Integer], facing DR_Point[DR_Integer]
                  • Set DR_Distance[DR_Integer] = (DR_Distance[DR_Integer] - DR_Speed[DR_Integer])
                  • Special Effect - Create a special effect at DR_CasterPoint[DR_Integer] using DR_Effect[1]
                  • Special Effect - Destroy (Last created special effect)
              • Set DR_DamageGroups[DR_Integer] = (Units within 150.00 of DR_CasterPoint[DR_Integer] matching ((((Matching unit) is A flying unit) Equal to False) and (((Owner of (Matching unit)) Not equal to (Owner of DR_Caster[DR_Integer])) and (((Matching unit) belongs to an ally of (Owner of DR_Caster[DR
              • Unit Group - Pick every unit in DR_DamageGroups[DR_Integer] and do (Actions)
                • Loop - Actions
                  • Set Temp_Integer = (Random integer number between (Integer(DR_Damage[DR_Integer])) and ((Integer(DR_Damage[DR_Integer])) x 4))
                  • Unit - Cause DR_Caster[DR_Integer] to damage (Picked unit), dealing (Real(Temp_Integer)) damage of attack type Spells and damage type Defensive
              • Destructible - Pick every destructible within 150.00 of DR_CasterPoint[DR_Integer] and do (Actions)
                • Loop - Actions
                  • Destructible - Kill (Picked destructible)
              • Custom script: call RemoveLocation(udg_DR_MovePoint[udg_DR_Integer])
              • Custom script: call RemoveLocation(udg_DR_CasterPoint[udg_DR_Integer])
              • Custom script: call DestroyGroup(udg_DR_DamageGroups[udg_DR_Integer])
            • Else - Actions
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • DR_Final[DR_Integer] Equal to False
                • Then - Actions
                  • Set DR_Final[DR_Integer] = True
                  • Set DR_Counter = (DR_Counter - 1.00)
                  • Set DR_CasterPoint[DR_Integer] = (Position of DR_Caster[DR_Integer])
                  • Set DR_DamageGroups[DR_Integer] = (Units within 200.00 of DR_CasterPoint[DR_Integer] matching ((((Matching unit) is A flying unit) Equal to False) and (((Owner of (Matching unit)) Not equal to (Owner of DR_Caster[DR_Integer])) and (((Matching unit) belongs to an ally of (Owner of DR_Caster[DR
                  • Special Effect - Create a special effect at DR_CasterPoint[DR_Integer] using DR_Effect[3]
                  • Special Effect - Destroy (Last created special effect)
                  • Destructible - Pick every destructible within 200.00 of DR_CasterPoint[DR_Integer] and do (Actions)
                    • Loop - Actions
                      • Destructible - Kill (Picked destructible)
                  • Unit Group - Pick every unit in DR_DamageGroups[DR_Integer] and do (Actions)
                    • Loop - Actions
                      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                        • If - Conditions
                          • K_Index[1] Equal to 0
                        • Then - Actions
                          • Trigger - Turn on Knockback Loop <gen>
                        • Else - Actions
                      • Set K_Index[1] = (K_Index[1] + 1)
                      • Set K_Index[2] = (K_Index[2] + 1)
                      • Set K_Speed_Distance = 25.00
                      • Set K_Distance_Times = (8 + (4 x (Level of Dark Rage for DR_Caster[DR_Integer])))
                      • Set K_Damage = (20 x (Level of Dark Rage for DR_Caster[DR_Integer]))
                      • Set K_Effects[1] = NONE.MDL
                      • Set K_Effects[2] = NONE.MDL
                      • Set K_Effects[3] = Abilities\Weapons\AvengerMissile\AvengerMissile.mdl
                      • Set K_Counter[K_Index[2]] = 0
                      • Set K_Caster[K_Index[2]] = DR_Caster[DR_Integer]
                      • Set K_Target[K_Index[2]] = (Picked unit)
                      • Set K_Cast_Point = (Position of K_Caster[K_Index[2]])
                      • Set K_Target_Point[K_Index[2]] = (Position of K_Target[K_Index[2]])
                      • Set K_Angle[K_Index[2]] = (Angle from K_Cast_Point to K_Target_Point[K_Index[2]])
                      • Custom script: call RemoveLocation(udg_K_Cast_Point)
                      • Custom script: call RemoveLocation(udg_K_Target_Point[udg_K_Index[2]])
                      • Unit - Turn collision for K_Target[K_Index[2]] Off
                      • Special Effect - Create a special effect attached to the origine of K_Target[K_Index[2]] using K_Effects[3]
                      • Set K_PemanentsEffects[K_Index[2]] = (Last created special effect)
                  • For each (Integer A) from 1 to 5, do (Actions)
                    • Loop - Actions
                      • -------- --------------------- --------
                      • Set Temp_Point = (DR_CasterPoint[DR_Integer] offset by 100.00 towards (72.00 x (Real((Integer A)))) degrees)
                      • Unit - Create 1 Dummy for (Owner of DR_Caster[DR_Integer]) at Temp_Point facing Default building facing degrees
                      • Unit - Turn collision for (Last created unit) Off
                      • Unit - Add a 2.00 second Generic expiration timer to (Last created unit)
                      • Custom script: call RemoveLocation(udg_Temp_Point)
                      • -------- --------------------- --------
                      • Set Temp_Point = (DR_CasterPoint[DR_Integer] offset by 300.00 towards (270.00 + (72.00 x (Real((Integer A))))) degrees)
                      • Unit - Order (Last created unit) to Undead Dreadlord - Carrion Swarm Temp_Point
                      • Custom script: call RemoveLocation(udg_Temp_Point)
                      • -------- --------------------- --------
                      • Set Temp_Point = (Position of (Last created unit))
                      • Special Effect - Create a special effect at Temp_Point using DR_Effect[2]
                      • Special Effect - Destroy (Last created special effect)
                      • Custom script: call RemoveLocation(udg_Temp_Point)
                  • Unit - Turn collision for DR_Caster[DR_Integer] On
                  • Unit - Unhide DR_Caster[DR_Integer]
                  • Selection - Add DR_Caster[DR_Integer] to selection for (Owner of DR_Caster[DR_Integer])
                  • Custom script: call RemoveLocation(udg_DR_Point[udg_DR_Integer])
                  • Custom script: call DestroyGroup(udg_DR_DamageGroups[udg_DR_Integer])
                  • Custom script: call RemoveLocation(udg_DR_CasterPoint[udg_DR_Integer])
                • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Integer(DR_Counter)) Equal to 0
        • Then - Actions
          • Set DR_Index = 0
          • Trigger - Turn off (This trigger)
        • Else - Actions
  • [/hidden]




- Initial Release


- Fixed Some Leaks
- Reduce The Number Of Dummy


- Fixed Some Leaks


- When There Are No Instance, I Set The Index To 0 (Thx to hanky)[Whoops I reset the wrong Variable :mad:]
- Set The Effect Of The Knocking Units To 1 Per Units
- Change All Effect Of The Spell
- Set Interval To 0.03 At 0.04
- Fixed Knocking Damage
- Remove The Final Damage
- Change The Knockback Speed
- Reduce The Number Of Dummy


- I Reset The Good Variables
- I Changes The Description


- Fixed One Leak
- Fixed The Bug




- Calex [For The KnockBack Systeme]
- GabyBoy [For The Spell]
- Hanky [For Said Me What I Had To Fix]
- TriggerHappy [For Said Me One Leaks]



I will add more documentation If I Have Time...

Keywords:
Dark, Rage, Calex3, Gaby-Boy, knockback, 1.50, 1.40, 1.30, 1.20, 1.10, 1.00.
Contents

Untitled (Map)

Reviews
16:24, 16th Jun 2010 TriggerHappy: You have updated everything. This leaks in your loop trigger. Unit - Create 1 Dummy for (Owner of DR_Caster[DR_Integer]) at Temp_Point facing (Position of (Triggering unit)) Hanky: Well you...

Moderator

M

Moderator

16:24, 16th Jun 2010

TriggerHappy:

You have updated everything.


This leaks in your loop trigger.

Unit - Create 1 Dummy for (Owner of DR_Caster[DR_Integer]) at Temp_Point facing (Position of (Triggering unit))


Hanky:
Well you reseted the wrong variable. If the DR_Counter variable is already equal to zero, since it's the condition, it's senseless to set the DR_Counter to zero. Instead of setting the DR_Counter to zero you have to set the DR_Index variable to zero. Because if you don't reset the DR_Index variable the spell won't work correctly later.
 
Level 18
Joined
Feb 28, 2009
Messages
1,970
@gaby-boy

To the spell - If I hadn`t missed any index, it`s probadly MUI. I think there is a little bit too big spam of sfxes when moving. I hadn`t been checking the code carefully, so there may be leaks, etc. So I won`t vote.

And another thing, is that the spell is not fully done by you. And I don`t like the method, you knockback units...

@ Amigurimi xP
 
Level 25
Joined
Jun 5, 2008
Messages
2,572
Leaks:
  • Unit - Create 1 Dummy for (Owner of DR_Caster[DR_Integer]) at (DR_CasterPoint[DR_Integer] offset by 130.00 towards (0.00 + (36.00 x (Real((Integer A))))) degrees) facing (Position of (Triggering unit))
And 3 more polar projection leaks inside the loop.

FIX:
  • Set Temp_Point = (DR_CasterPoint[DR_Integer] offset by 130.00 towards (0.00 + (30.00 x (Real((Integer A))))) degrees)
  • Unit - Create 1 Dummy for (Owner of DR_Caster[DR_Integer]) at Temp_Point
  • Custom script: call RemoveLocation(udg_Temp_Point)
Do this for all polar projections to avoid leaks.

There are 40 leaks per spell cast of type locations.
All are in the loop (from 1 to 10) in the part when the caster reaches the destination.(there are 4 location leaks in the loop, but since you loop 10 times....)

  • Unit - Order (Last created unit) to Orc Tauren Chieftain - Shockwave (DR_CasterPoint[DR_Integer] offset by 200.00 towards (90.00 + (36.00 x (Real((Integer A))))) degrees)
Absolutely NEVER, i mean NEVER, use base ability as a SHOCKWAVE.
Sorry if this sounded harsh but the Ripple effect causes much lag, replace it with carrion swarm and switch the model.

You are also using 21 dummy per spell cast, please reduce the amount of dummies used.
 
Level 9
Joined
Jan 17, 2009
Messages
372
please put triggers in hidden tagss
Now time for you to learn about da hidden tagz!!!!
to put stuff in hidden tags do the following before
  • or the information you would like to hide type [HTML][hidden="<insert desired name>"] and end it with [/hidden] at the end of the information you would like to hide. [/HTML]
 
Top