• 🏆 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!

Knives Attack v1.1

[TD] Knives Attack [/TD]
Throws knives around, the knives will pierce to all enemy ground units in line and dealing serious damage per knives.

LEVELS
Level 1: 10 knives, 50 damage.
Level 2: 15 knives, 75 damage.
Level 3: 20 knives, 100 damage.

[TD] SAMPLE IMAGES [/TD]

Sample One

Sample Two

216436-albums6048-picture64597.jpg
216436-albums6048-picture64598.jpg


[TD] CHANGELOGS: [/TD]
[TD]v1.0 - Initial Release
v1.1 - Fixed bug
[/TD]

[TD] Credits: [/TD]
[TD]- Vexorian
- rulerofiron99
[/TD]

KA Configuration

KA Cast

KA Loop

  • Events
    • Map initialization
  • Conditions
  • Actions
    • -------- Determines the ability being casted --------
    • Set KA_Ability = Knives Attack
    • -------- Determines the dummy type used to be the knives missiles --------
    • Set KA_Dummy_Type = Dummy
    • -------- Determines the distance that will knives travel --------
    • Set KA_Distance[1] = 600.00
    • Set KA_Distance[2] = 600.00
    • Set KA_Distance[3] = 600.00
    • -------- Determines the knives speed --------
    • Set KA_Speed[1] = 30.00
    • Set KA_Speed[2] = 30.00
    • Set KA_Speed[3] = 30.00
    • -------- Determines the damage per knives --------
    • Set KA_Damage[1] = 50.00
    • Set KA_Damage[2] = 75.00
    • Set KA_Damage[3] = 100.00
    • -------- Determines the range of damage, this also determines the range from knives to kill nearby trees --------
    • Set KA_Damage_Range[1] = 50.00
    • Set KA_Damage_Range[2] = 50.00
    • Set KA_Damage_Range[3] = 50.00
    • -------- Determines the number of knives --------
    • Set KA_Count[1] = 10
    • Set KA_Count[2] = 15
    • Set KA_Count[3] = 20
    • -------- Determines the scaling size (%) of knives --------
    • Set KA_Scale[1] = 100.00
    • Set KA_Scale[2] = 100.00
    • Set KA_Scale[3] = 100.00
    • -------- Determines the fly height per knives --------
    • Set KA_Fly_Height[1] = 50.00
    • Set KA_Fly_Height[2] = 50.00
    • Set KA_Fly_Height[3] = 50.00
    • -------- Determines the expiration time for knives, this is for removing knives that may get stuck --------
    • Set KA_Debug_Time = 10.00
    • -------- Determines the model of knives --------
    • Set KA_Model = Abilities\Weapons\WardenMissile\WardenMissile.mdl
    • -------- Determines the effect if the knives hit a unit --------
    • Set KA_Hit_Effect = Abilities\Spells\Other\Stampede\StampedeMissileDeath.mdl
    • -------- Determines the attachment for the hit effect --------
    • Set KA_Hit_Effect_Attach = chest
    • -------- Determines the effect if the knives reach the distance or hit something --------
    • Set KA_End_Effect = Abilities\Weapons\WardenMissile\WardenMissile.mdl
    • -------- "True" the knives will cause damage to ally --------
    • -------- "False" the knives will only cause damage to enemy --------
    • Set KA_Condition[1] = False
    • -------- "True" the knives can hit flying units --------
    • -------- "False" the knives can only hit ground units --------
    • Set KA_Condition[2] = False
    • -------- "True" the knives can hit magic immune units --------
    • -------- "False" the knives can't hit magic immune units --------
    • Set KA_Condition[3] = False
    • -------- "True" the knives will piercing through the enemies in line --------
    • -------- "False" the knives will gone if hitting a unit --------
    • Set KA_Pierce = True
    • -------- "True" the knives will kill a tree in line --------
    • -------- "False" the knives will gone if hitting a tree --------
    • Set KA_Kill_Trees = True
    • -------- Determines the attack type --------
    • Set KA_Attack_Type = Pierce
    • -------- Determines the damage type --------
    • Set KA_Damage_Type = Normal
    • -------- Determines the loop timer --------
    • Set KA_Interval = 0.03
    • -------- --------------------------- --------
    • -------- End of Configuration --------
    • -------- =========================================================================== --------
    • -------- --------------------------- --------
    • -------- Create a hashtable to save some important values --------
    • -------- --------------------------- --------
    • Custom script: set udg_KA_Hashtable = InitHashtable()
    • -------- --------------------------- --------
    • -------- Add the loop timer to the loop trigger --------
    • -------- --------------------------- --------
    • Trigger - Add to KA Loop <gen> the event (Time - Every KA_Interval seconds of game time)
    • -------- --------------------------- --------
    • -------- Create the tree remover, to check a destructable if it is a tree --------
    • -------- --------------------------- --------
    • Custom script: set udg_Harvester = CreateUnit(Player(15), 'hpea', 0, 0, 0)
    • Custom script: call SetUnitInvulnerable(udg_Harvester, true)
    • Custom script: call ShowUnit(udg_Harvester, false)
    • Custom script: set udg_Harvest_Order = "harvest"
  • Events
    • Unit - A unit Starts the effect of an ability
  • Conditions
    • (Ability being cast) Equal to KA_Ability
  • Actions
    • -------- --------------------------- --------
    • -------- Setting --------
    • -------- --------------------------- --------
    • Set KA_TempUnit[1] = (Triggering unit)
    • Set KA_Owner = (Triggering player)
    • Set KA_Level = (Level of KA_Ability for KA_TempUnit[1])
    • Set TempLoc = (Position of KA_TempUnit[1])
    • -------- --------------------------- --------
    • -------- Increase the damaged group index --------
    • -------- --------------------------- --------
    • Set KA_Group_Index = (KA_Group_Index + 1)
    • -------- --------------------------- --------
    • -------- Create the damaged group, this group is for checking if a unit near the knives is damaged --------
    • -------- --------------------------- --------
    • Custom script: set udg_KA_Damaged_Group[udg_KA_Group_Index] = CreateGroup()
    • Custom script: set udg_KA_Start_Z = GetLocationZ(udg_TempLoc)
    • -------- --------------------------- --------
    • -------- Create the knives missiles --------
    • -------- --------------------------- --------
    • Set KA_Real[1] = (Random angle)
    • For each (Integer KA_Count[0]) from 1 to KA_Count[KA_Level], do (Actions)
      • Loop - Actions
        • Set KA_Real[1] = (KA_Real[1] + (360.00 / (Real(KA_Count[KA_Level]))))
        • Custom script: set udg_KA_TempUnit[2] = CreateUnitAtLoc(udg_KA_Owner, udg_KA_Dummy_Type, udg_TempLoc, udg_KA_Real[1])
        • Special Effect - Create a special effect attached to the origin of KA_TempUnit[2] using KA_Model
        • Set KA_Model_SFX = (Last created special effect)
        • -------- --------------------------- --------
        • -------- This is just perfection for knives spawning --------
        • -------- --------------------------- --------
        • Custom script: call SetUnitX(udg_KA_TempUnit[2], GetLocationX(udg_TempLoc))
        • Custom script: call SetUnitY(udg_KA_TempUnit[2], GetLocationY(udg_TempLoc))
        • -------- --------------------------- --------
        • -------- Add the debug time for knives --------
        • -------- --------------------------- --------
        • Unit - Add a KA_Debug_Time second Generic expiration timer to KA_TempUnit[2]
        • Animation - Change KA_TempUnit[2]'s size to (KA_Scale[KA_Level]%, KA_Scale[KA_Level]%, KA_Scale[KA_Level]%) of its original size
        • -------- --------------------------- --------
        • -------- Makes the missile flying, this just for non-flying unit --------
        • -------- --------------------------- --------
        • Custom script: if UnitAddAbility(udg_KA_TempUnit[2], 'Amrf') and UnitRemoveAbility(udg_KA_TempUnit[2], 'Amrf') then
        • Custom script: endif
        • Animation - Change KA_TempUnit[2] flying height to KA_Fly_Height[KA_Level] at 0.00
        • -------- --------------------------- --------
        • -------- Add the knives to the main group, to allow them for moving --------
        • -------- --------------------------- --------
        • Unit Group - Add KA_TempUnit[2] to KA_Group
        • -------- --------------------------- --------
        • -------- Get the handle ID of each knives for saving a values --------
        • -------- --------------------------- --------
        • Custom script: set udg_KA_Handle_Id = GetHandleId(udg_KA_TempUnit[2])
        • -------- --------------------------- --------
        • -------- Saving --------
        • -------- --------------------------- --------
        • Hashtable - Save Handle OfKA_Owner as (Key owner) of KA_Handle_Id in KA_Hashtable
        • -------- --------------------------- --------
        • -------- Save the level of ability, this one is important but of course there are more important like this --------
        • -------- --------------------------- --------
        • Hashtable - Save KA_Level as (Key level) of KA_Handle_Id in KA_Hashtable
        • Hashtable - Save 0.00 as (Key distance) of KA_Handle_Id in KA_Hashtable
        • Hashtable - Save KA_Real[1] as (Key angle) of KA_Handle_Id in KA_Hashtable
        • Hashtable - Save KA_Group_Index as (Key index) of KA_Handle_Id in KA_Hashtable
        • Hashtable - Save KA_Start_Z as (Key z) of KA_Handle_Id in KA_Hashtable
        • Hashtable - Save Handle OfKA_Model_SFX as (Key model) of KA_Handle_Id in KA_Hashtable
    • -------- --------------------------- --------
    • -------- Remove location leak --------
    • -------- --------------------------- --------
    • Custom script: call RemoveLocation(udg_TempLoc)
    • -------- --------------------------- --------
    • -------- Turn the loop trigger on --------
    • -------- --------------------------- --------
    • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
      • If - Conditions
        • (KA Loop <gen> is on) Equal to False
      • Then - Actions
        • Trigger - Turn on KA Loop <gen>
      • Else - Actions
  • Events
  • Conditions
  • Actions
    • Unit Group - Pick every unit in KA_Group and do (Actions)
      • Loop - Actions
        • Set KA_TempUnit[1] = (Picked unit)
        • -------- --------------------------- --------
        • -------- Get again the handle ID of knives --------
        • -------- --------------------------- --------
        • Custom script: set udg_KA_Handle_Id = GetHandleId(udg_KA_TempUnit[1])
        • -------- --------------------------- --------
        • -------- Load some values that has saved --------
        • -------- --------------------------- --------
        • Set KA_Level = (Load (Key level) of KA_Handle_Id from KA_Hashtable)
        • Set KA_Group_Index = (Load (Key index) of KA_Handle_Id from KA_Hashtable)
        • Set KA_Real[1] = (Load (Key distance) of KA_Handle_Id from KA_Hashtable)
        • -------- --------------------------- --------
        • -------- Check if the knives has reach the distance --------
        • -------- --------------------------- --------
        • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
          • If - Conditions
            • KA_Real[1] Less than KA_Distance[KA_Level]
          • Then - Actions
            • -------- --------------------------- --------
            • -------- Load the angle --------
            • -------- --------------------------- --------
            • Set KA_Real[2] = (Load (Key angle) of KA_Handle_Id from KA_Hashtable)
            • Set TempLoc = (Position of KA_TempUnit[1])
            • Set TempLoc2 = (TempLoc offset by KA_Speed[KA_Level] towards KA_Real[2] degrees)
            • -------- --------------------------- --------
            • -------- This is just for makes more real throwed knives --------
            • -------- --------------------------- --------
            • Custom script: set udg_KA_Real[3] = GetLocationZ(udg_TempLoc2)
            • Set KA_Start_Z = (Load (Key z) of KA_Handle_Id from KA_Hashtable)
            • Set KA_Real[4] = ((KA_Start_Z - KA_Real[3]) + KA_Fly_Height[KA_Level])
            • Animation - Change KA_TempUnit[1] flying height to KA_Real[4] at 0.00
            • -------- --------------------------- --------
            • -------- Remove location leak --------
            • -------- --------------------------- --------
            • Custom script: call RemoveLocation(udg_TempLoc)
            • -------- --------------------------- --------
            • -------- Set some values to makes the knives move --------
            • -------- --------------------------- --------
            • Custom script: set udg_KA_Real[5] = GetUnitX(udg_KA_TempUnit[1])
            • Custom script: set udg_KA_Real[6] = GetUnitY(udg_KA_TempUnit[1])
            • Custom script: set udg_KA_Real[7] = udg_KA_Real[2] * bj_DEGTORAD
            • -------- --------------------------- --------
            • -------- Move the knives, do like this when moving something because this is the best way --------
            • -------- --------------------------- --------
            • Custom script: call SetUnitX(udg_KA_TempUnit[1], udg_KA_Real[5] + udg_KA_Speed[udg_KA_Level] * Cos(udg_KA_Real[7]))
            • Custom script: call SetUnitY(udg_KA_TempUnit[1], udg_KA_Real[6] + udg_KA_Speed[udg_KA_Level] * Sin(udg_KA_Real[7]))
            • -------- --------------------------- --------
            • -------- Increase and save the reached distance --------
            • -------- --------------------------- --------
            • Hashtable - Save (KA_Real[1] + KA_Speed[KA_Level]) as (Key distance) of KA_Handle_Id in KA_Hashtable
            • -------- --------------------------- --------
            • -------- Damaging nearby units --------
            • -------- --------------------------- --------
            • Custom script: set bj_wantDestroyGroup = true
            • Unit Group - Pick every unit in (Units within KA_Damage_Range[KA_Level] of TempLoc2) and do (Actions)
              • Loop - Actions
                • Set KA_TempUnit[2] = (Picked unit)
                • -------- --------------------------- --------
                • -------- Conditions --------
                • -------- --------------------------- --------
                • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                  • If - Conditions
                    • And - All (Conditions) are true
                      • Conditions
                        • (KA_TempUnit[2] is dead) Equal to False
                        • (KA_TempUnit[2] belongs to an ally of KA_Owner) Equal to KA_Condition[1]
                        • (KA_TempUnit[2] is A flying unit) Equal to KA_Condition[2]
                        • (KA_TempUnit[2] is Magic Immune) Equal to KA_Condition[3]
                        • (KA_TempUnit[2] is in KA_Damaged_Group[KA_Group_Index]) Equal to False
                  • Then - Actions
                    • -------- --------------------------- --------
                    • -------- Check if that unit is a mechanical, if so then the knives gone, because knives can't cause damage to mechanical unit like real --------
                    • -------- --------------------------- --------
                    • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                      • If - Conditions
                        • (KA_TempUnit[2] is Mechanical) Equal to False
                      • Then - Actions
                        • -------- --------------------------- --------
                        • -------- If that unit is not mechanical, then cause them the damage --------
                        • -------- --------------------------- --------
                        • -------- --------------------------- --------
                        • -------- Create the hit effect --------
                        • -------- --------------------------- --------
                        • Custom script: call DestroyEffect(AddSpecialEffectTarget(udg_KA_Hit_Effect, udg_KA_TempUnit[2], udg_KA_Hit_Effect_Attach))
                        • Unit - Cause KA_TempUnit[1] to damage KA_TempUnit[2], dealing KA_Damage[KA_Level] damage of attack type KA_Attack_Type and damage type KA_Damage_Type
                        • -------- --------------------------- --------
                        • -------- Add the damaged unit to the damaged group, so that unit will not be damaged again --------
                        • -------- --------------------------- --------
                        • Unit Group - Add KA_TempUnit[2] to KA_Damaged_Group[KA_Group_Index]
                      • Else - Actions
                        • -------- --------------------------- --------
                        • -------- Makes the knive gone --------
                        • -------- --------------------------- --------
                        • Hashtable - Save KA_Distance[KA_Level] as (Key distance) of KA_Handle_Id in KA_Hashtable
                    • -------- --------------------------- --------
                    • -------- Check the pierce boolean, if "True" then let the knives still exist, if "False" then make the knives gone --------
                    • -------- --------------------------- --------
                    • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                      • If - Conditions
                        • KA_Pierce Equal to False
                      • Then - Actions
                        • -------- --------------------------- --------
                        • -------- Makes the knive gone --------
                        • -------- --------------------------- --------
                        • Hashtable - Save KA_Distance[KA_Level] as (Key distance) of KA_Handle_Id in KA_Hashtable
                      • Else - Actions
                  • Else - Actions
            • -------- --------------------------- --------
            • -------- Check the kill trees boolean, if "True" then let the knives killing trees, if "False" then don't let the knives killing trees --------
            • -------- --------------------------- --------
            • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
              • If - Conditions
                • KA_Kill_Trees Equal to True
              • Then - Actions
                • -------- --------------------------- --------
                • -------- Killing nearby trees --------
                • -------- --------------------------- --------
                • Destructible - Pick every destructible within KA_Damage_Range[KA_Level] of TempLoc2 and do (Actions)
                  • Loop - Actions
                    • Set Tree = (Picked destructible)
                    • -------- --------------------------- --------
                    • -------- Order the tree remover to check the destructable --------
                    • -------- --------------------------- --------
                    • Custom script: call IssueTargetOrder(udg_Harvester, udg_Harvest_Order, udg_Tree)
                    • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                      • If - Conditions
                        • And - All (Conditions) are true
                          • Conditions
                            • (Current order of Harvester) Equal to (Order(Harvest_Order))
                            • (Tree is alive) Equal to True
                      • Then - Actions
                        • -------- --------------------------- --------
                        • -------- Kill the tree --------
                        • -------- --------------------------- --------
                        • Destructible - Kill Tree
                        • -------- --------------------------- --------
                        • -------- Make the knive gone, you can remove this to makes the knives killing all trees in line --------
                        • -------- --------------------------- --------
                        • Hashtable - Save KA_Distance[KA_Level] as (Key distance) of KA_Handle_Id in KA_Hashtable
                      • Else - Actions
                    • -------- --------------------------- --------
                    • -------- Now, order the tree remover to stop from his job --------
                    • -------- --------------------------- --------
                    • Unit - Order Harvester to Stop
              • Else - Actions
            • -------- --------------------------- --------
            • -------- Remove location leak --------
            • -------- --------------------------- --------
            • Custom script: call RemoveLocation(udg_TempLoc2)
            • -------- --------------------------- --------
            • -------- Check if the knives current fly height is 0 or below, if so then make the knive gone --------
            • -------- --------------------------- --------
            • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
              • If - Conditions
                • KA_Real[4] Less than or equal to 0.00
              • Then - Actions
                • -------- --------------------------- --------
                • -------- Make the knive gone --------
                • -------- --------------------------- --------
                • Hashtable - Save KA_Distance[KA_Level] as (Key distance) of KA_Handle_Id in KA_Hashtable
              • Else - Actions
          • Else - Actions
            • -------- --------------------------- --------
            • -------- Destroy group leak --------
            • -------- --------------------------- --------
            • Custom script: call DestroyGroup(udg_KA_Damaged_Group[udg_KA_Group_Index])
            • -------- --------------------------- --------
            • -------- Decrease the damaged group index --------
            • -------- --------------------------- --------
            • Set KA_Group_Index = (KA_Group_Index - 1)
            • -------- --------------------------- --------
            • -------- Create the end effect --------
            • -------- --------------------------- --------
            • Set TempLoc = (Position of KA_TempUnit[1])
            • Custom script: call DestroyEffect(AddSpecialEffectLoc(udg_KA_End_Effect, udg_TempLoc))
            • Custom script: call RemoveLocation(udg_TempLoc)
            • -------- --------------------------- --------
            • -------- Destroy special effect leak --------
            • -------- --------------------------- --------
            • Special Effect - Destroy (Load (Key model) of KA_Handle_Id in KA_Hashtable)
            • -------- --------------------------- --------
            • -------- Remove the knive --------
            • -------- --------------------------- --------
            • Unit - Kill KA_TempUnit[1]
            • -------- --------------------------- --------
            • -------- The End --------
            • -------- --------------------------- --------
            • Hashtable - Clear all child hashtables of child KA_Handle_Id in KA_Hashtable
            • Unit Group - Remove KA_TempUnit[1] from KA_Group
            • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
              • If - Conditions
                • (KA_Group is empty) Equal to True
              • Then - Actions
                • Trigger - Turn off KA Loop <gen>
              • Else - Actions

Spell Description Template by doomhammer99

Keywords:
Knive, Missile, Many, Piercing, GUI.
Contents

Knives Attack v1.1 (Map)

Reviews
Approved This is a useful alternative for Fan of Knives. The spell is triggered quite well and it is easily configurable. The blood effetc could be adjusted or changed, it could look a bit better. Required changes: Make the caster...

Moderator

M

Moderator

Reviewed by Maker, Knives Attack v1.1, 8th Jan 2013

Approved

This is a useful alternative for Fan of Knives. The spell is triggered quite well and it is easily configurable.

The blood effetc could be adjusted or changed, it could look a bit better.

Reviewed by Maker, Knives Attack v1.0, 3rd Jan 2013

Required changes:
  • Make the caster deal the damage

Suggested changes:
  • Save the Cos and Sin values of the angle, then you don't need to
    calculate them during each loop, also cuts off the degtorad conversion
    • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
      • If - Conditions
        • And - All (Conditions) are true
          • Conditions
            • (KA_TempUnit[2] is dead) Equal to False
            • (KA_TempUnit[2] belongs to an ally of KA_Owner)...
    ->
    • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
      • If - Conditions
        • (KA_TempUnit[2] is dead) Equal to False
        • (KA_TempUnit[2] belongs to an ally of KA_Owner)...
  • Get rid of Remove Dummy trigger, the dummy is set to not decay and
    has 1 second death time. It will be removed quickly automatically
  • With low cooldown values, KA_Group index keeps on growing and
    it can eventually grow too high and the spell won't work correctly
 
Level 14
Joined
Aug 8, 2010
Messages
1,022
The "Remove Dummy" trigger is not needed. Just set this field "Combat - Death Type" (in object editor) to "Can't rise, Does not decay" (which you have did) and you will be okay.
Because when a unit dies, it automatically gets removed from the game after it decays. Since the dummy doesn't decay, it is immediately removed from the game.
I will also give a suggestion. Make a configurable that defines if the knives go in random directions or in specified angles (as you did). Because if they spawn randomly, it looks a bit more cooler. The user will still be able to change between the two types, though.
This is only a suggestion, remember.

Overall, the spell is great, i like it. The code also appears to be good. Good job! I will give it a 4/5 and +rep to you. :)

EDIT : Also, use the "hidden" BB code function for your trigger so that the hivers can show/hide whatever is inside. With extremely long triggers, it's really annoying to scroll like mad.
 
Level 13
Joined
Mar 29, 2012
Messages
530
The "Remove Dummy" trigger is not needed. Just set this field "Combat - Death Type" (in object editor) to "Can't rise, Does not decay" (which you have did) and you will be okay.
Because when a unit dies, it automatically gets removed from the game after it decays. Since the dummy doesn't decay, it is immediately removed from the game.
I will also give a suggestion. Make a configurable that defines if the knives go in random directions or in specified angles (as you did). Because if they spawn randomly, it looks a bit more cooler. The user will still be able to change between the two types, though.
This is only a suggestion, remember.

Overall, the spell is great, i like it. The code also appears to be good. Good job! I will give it a 4/5 and +rep to you. :)

EDIT : Also, use the "hidden" BB code function for your trigger so that the hivers can show/hide whatever is inside. With extremely long triggers, it's really annoying to scroll like mad.

Accepted...:grin:
Thx....so i just need to kill the dummy without removing it with trigger ??
 
Review #1
1)If you are going to use SUXY(SetUnitX/Y),never use locations.
2)Some variables should have prefixes.Ex. PR_MyVar
3) Animation - Change KA_TempUnit[2]'s size to (KA_Scale[KA_Level]%, KA_Scale[KA_Level]%, KA_Scale[KA_Level]%) of its original size
Only stretch X(meaning just put 0 on the other 2 real arguements,just put the scale on the first real)
4)If you are going to create dummies while cacheing,use coordinates instead.
5) Hashtable - Save 0.00 as (Key distance) of KA_Handle_Id in KA_Hashtable
you can remove this line,because loading it defaults to 0 so it is equal to 0 when you remove this.
6) Custom script: call DestroyEffect(AddSpecialEffectLoc(udg_KA_End_Effect, udg_TempLoc))
create the effect on coordinates.
7)If you are going to use an arc method,you dont need to save/load flying height(dunno becauses i havent tested this yet)
8)just like Cold_Bon3 said,remove the units after killing it.Because corpse leaks.
9)Are you using dummy.mdx? if so,credit Vexorian

This spell is marked as Needs Fix
 
Level 13
Joined
Mar 29, 2012
Messages
530
I don't know exactly who's the creator of dummy.mdx...that i know there is 3 person....
But i only knew 1, Vexorian, so i don't give him credit yet....but i'll give it now.... :D

If you are going to use an arc method,you dont need to save/load flying height

I am not going to use that....
 
Level 13
Joined
Mar 29, 2012
Messages
530
If you are going to create dummies while cacheing,use coordinates instead.

What's the reason and example...!!!???

Custom script: call DestroyEffect(AddSpecialEffectLoc(udg_KA_End_Effect, udg_TempLoc))
create the effect on coordinates.

What's the reason and example...!!!???

just like Cold_Bon3 said,remove the units after killing it.Because corpse leaks.

Need example...!!!???
 
Level 14
Joined
Aug 8, 2010
Messages
1,022
@Ofel The Editor, dude, to remove dummies you need only one single action, no triggers, no other things. Use this :
"Unit - Add Generic Expiration Timer"
If you give a timer like this, after X seconds the dummy is out of the game. It's game over for it!! :grin:
 
Level 13
Joined
Mar 29, 2012
Messages
530
Just a little question :
Can i save values with
  • Custom script: Save...(....)
I mean without
  • Custom script: Save...BJ(....)
Also, do i need to remove the "If" for turning on the loop trigger ??
 

BUP

BUP

Level 9
Joined
Sep 9, 2012
Messages
172
@Ofel The Editor, dude, to remove dummies you need only one single action, no triggers, no other things. Use this :
"Unit - Add Generic Expiration Timer"
If you give a timer like this, after X seconds the dummy is out of the game. It's game over for it!! :grin:

Hey,dude I think you're wrong.After giving the Expiration Timer,the unit only dies.It's not removed from the game.So it leaks.
 
Level 14
Joined
Aug 8, 2010
Messages
1,022
I asked Maker yesterday especially for this and for BUP's spellpack. This is what he said
I tested with creating 12000 units and adding expiration timer. I saw no major leaks anyway. If there was a leak it was very small. Don't worry about it.

I took 4 data points, at 4k, 6k, 8k and 10k. After pausing the test for a while and checking the memory reseved, it was exactly 94352 K at all data points.
According to Maker, an expiration timer is enough.
 
Top