Binding Poison 1.3.2

Binding Poison binds a target . The target loses life overtime as the poison is taking place. At the break of the spell, the poison spills into some AoE to damage nearby enemy units.

  • BPConfig
    • Events
      • Map initialization
    • Conditions
    • Actions
      • -------- You can set anything here --------
      • -------- Set the Attachment Point on the Target unit of Ability being cast --------
      • Set DummyEffect_AttachStr_OnCst = origin
      • -------- Set the Attachment Point on the sorrounding units at the break of the spell --------
      • Set DummyEffect_AttachStr_OnBrk = origin
      • -------- Set the model path used on the target unit --------
      • Set Dummy_Effect_EffStr_OnCst = Abilities\Spells\NightElf\Immolation\ImmolationTarget.mdl
      • -------- Set the model path used on the sorrounding units at the break of the spell --------
      • Set Dummy_Effect_EffStr_OnBrk = Abilities\Spells\Undead\AnimateDead\AnimateDeadTarget.mdl
      • -------- ============================================= --------
      • Set BP_RealDamage = 20.00
      • -------- Damage dealt is 20, 40, 60 per sec to the target and --------
      • -------- at the break of the spell will damage the nearby enemy units to 20, 40, 60 base damage --------
      • Set BP_Time = 3.00
      • -------- this is the duration of the spell --------
      • -------- Time is 3, 6, 9 --------
      • Set BP_DamageArea = 250
      • -------- this is the Area of effect --------
      • -------- increased, multiplied by the spell level --------
      • -------- AoE is 250, 500, 750 --------
  • BPCasting
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Binding Poison
    • Actions
      • -------- ----------------------------------------------------------------------------------- --------
      • Set BP_index_size = (BP_index_size + 1)
      • -------- ----------------------------------------------------------------------------------- --------
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • BP_index_size Greater than BP_index_max
        • Then - Actions
          • Set BP_index[BP_index_size] = BP_index_size
          • Set BP_index_max = BP_index_size
        • Else - Actions
      • Set BP_integer = BP_index[BP_index_size]
      • Set BP_Caster[BP_integer] = (Triggering unit)
      • Set BP_Target[BP_integer] = (Target unit of ability being cast)
      • Set BP_TempCasterPosition = (Position of BP_Caster[BP_integer])
      • Set BP_time[BP_integer] = (BP_Time x (Real((Level of Binding Poison for BP_Caster[BP_integer]))))
      • Set BP_AbilLevel[BP_integer] = (Level of Binding Poison for BP_Caster[BP_integer])
      • Set BP_AoE[BP_integer] = ((Real(BP_DamageArea)) x (Real((Level of Binding Poison for BP_Caster[BP_integer]))))
      • Set BP_DamageInflict[BP_integer] = (BP_RealDamage x (Real((Level of Binding Poison for BP_Caster[BP_integer]))))
      • Special Effect - Create a special effect attached to the DummyEffect_AttachStr_OnCst of BP_Target[BP_integer] using Dummy_Effect_EffStr_OnCst
      • Set BP_SpecialEffect[BP_integer] = (Last created special effect)
      • Custom script: call RemoveLocation(udg_BP_TempCasterPosition)
      • Trigger - Turn on BPDuration <gen>
  • BPDuration
    • Events
      • Time - Every 1.00 seconds of game time
    • Conditions
    • Actions
      • For each (Integer BP_loop) from 1 to BP_index_size, do (Actions)
        • Loop - Actions
          • Set BP_integer = BP_index[BP_loop]
          • Set BP_TempTargetPosition = (Position of BP_Target[BP_integer])
          • -------- this damages the enemy unit for a certain period --------
          • Unit - Cause BP_Caster[BP_integer] to damage BP_Target[BP_integer], dealing BP_DamageInflict[BP_integer] damage of attack type Spells and damage type Normal
          • -------- if time reaches zero or if target is dead, the loop will end --------
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • Or - Any (Conditions) are true
                • Conditions
                  • BP_time[BP_integer] Less than or equal to 0.00
                  • (BP_Target[BP_integer] is dead) Equal to True
            • Then - Actions
              • Set BP_DamagedGroup = (Units within BP_AoE[BP_integer] of BP_TempTargetPosition matching (((Matching unit) belongs to an enemy of (Owner of BP_Caster[BP_integer])) Equal to True))
              • Unit Group - Pick every unit in BP_DamagedGroup and do (Actions)
                • Loop - Actions
                  • Unit - Cause BP_Caster[BP_integer] to damage (Picked unit), dealing BP_DamageInflict[BP_integer] damage of attack type Spells and damage type Normal
                  • Special Effect - Create a special effect attached to the DummyEffect_AttachStr_OnBrk of (Picked unit) using Dummy_Effect_EffStr_OnBrk
                  • Special Effect - Destroy (Last created special effect)
              • Special Effect - Destroy BP_SpecialEffect[BP_integer]
              • -------- The following recycles indexes which have already ended --------
              • -------- to avoid unnecessary loops --------
              • Set BP_index[BP_loop] = BP_index[BP_index_size]
              • Set BP_index[BP_index_size] = BP_integer
              • Set BP_index_size = (BP_index_size - 1)
              • Set BP_loop = (BP_loop - 1)
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • BP_index_size Equal to 0
                • Then - Actions
                  • Trigger - Turn off (This trigger)
                • Else - Actions
            • Else - Actions
              • Set BP_time[BP_integer] = (BP_time[BP_integer] - 1.00)
          • Custom script: call RemoveLocation(udg_BP_TempTargetPosition)
          • Custom script: call DestroyGroup(udg_BP_DamagedGroup)
Change Logs:
1. This spell doesn't pause or stun the target anymore. I just bind him with poison.
2. Some major fixes done. (Please, see the triggers)
3. No more Dummy unit required.
4. No more special effect for the caster.
Change log
Stored damage as an array

Keywords:
poison, lock, bind, target
Contents

Binding Poison 1.2a (Map)

Reviews
Moderator: Pharaoh_ Date: 18:59, 22nd Apr 2012 Could be further improved, but it's approvable. Useful • The way you are damaging the units is not user-friendly. If one user wants to damage for 50 static damage, the loop trigger forces that...

Moderator

M

Moderator

160036-albums4747-picture55861.png

Moderator: Pharaoh_
Date: 18:59, 22nd Apr 2012

Review
Could be further improved, but it's approvable.

Useful
• The way you are damaging the units is not user-friendly. If one user wants to damage for 50 static damage, the loop trigger forces that damage to be multiplied by the level of the caster's ability.
Store the damage with the array, like BP_RealDamage[BP_integer].
• Storing the AoE_Effect, when you instantly destroy it is not needed. Just use Special Effect - Destroy (Last created special effect).
• You still don't configure the special effects' paths, such as AnimateDeadTarget, ImmolationTarget and AnimateDeadTarget in your BPDuration trigger.
• The Pause's duration (Storm bolt ability) should be 0 in the Object Editor, so that a user can manage everything in the spell only by triggers. Do not forget to check if the target has other instances running on it, before removing the buff, otherwise previous endings of duration will dissolve the effect of the newer instances.
• Skip remaining actions is not necessary, especially when they are in the end of an if then else branch and after a trigger turn-off.
• Set Art - Death time of the dummy to 0.
• You don't need to store the caster's special effect, especially when you use the AnimateDeadTarget effect. It does not have a stand animation anyway. Just destroy it right after it has been used in BPCasting (don't forget to additionally remove the action of destruction in the BPDuration trigger).
• Rename the triggers; their names are too generic (speaking of the ones specifically used by this spell).
• Use global variables in the map initialization trigger (or even better, create a map initialization trigger for this spell only, to init values), in order to configure special effect paths (string variables). Mark the "duration" variable with a comment, to let a user noticeably know that this variable pertains to duration of the spell per level.
• Stun the unit, like Maker suggested in his review. Use Storm Bolt-based ability, with a duration of 0 and remove the buff, when the instance has ended. Make sure you check if that particular index'd target has more than one instances running on it, before removing the buff. This will help you a) to avoid removing the buff, in case other instances are used on the same unit, b) avoid spamming the special effects on the target more than once.
• Use Stats - Hide Minimap Display = True for the dummy.
• Avoid posting the triggers over and over again in the description, for every update. Use the triggers of the current version.
• It's more preferable to use the sfx on the target, not on a dummy, this will save performance. Make configurable values for the attachment points as well (e.g. "origin"/"chest"/etc.).


Spell is good otherwise.
 
Level 22
Joined
Jan 1, 2011
Messages
1,465
If anyone leaves good advice on how to make something MUI let me be the first. If you simply cannot use hashtables then use a indexing system without hashtables.
Example: Bribe's Indexer
Or, use JNPG and do custom script hashtables (Or regular editor for that matter, though it might not compile without jasshelper)
Example:
  • Custom script: call SaveInteger( udg_Hashtable, 0, 0, 100 )
Either way will work, if possible update Warcraft 3 to the latest patch as well.
 
Hello, here is the new trigger for this spell. I guess, there is still something wrong. Could someone tell me why the effect per second is disabled when some other hero cast the same spell here?
  • Start
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Binding Poison
    • Actions
      • -------- Dont change anyhting here --------
      • Set Index[0] = (Index[0] + 1)
      • Set TimeIndex = Index[0]
      • Set EffectIndex = (Custom value of Target[Index[0]])
      • Set time_multiplier[TimeIndex] = 2.00
      • Game - Display to (All players) for 3.00 seconds the text: (String(Index[0]))
      • -------- I am setting some thing her to fire in the next trigger --------
      • Set Caster[Index[0]] = (Triggering unit)
      • Set TempCasterPosition[Index[0]] = (Position of (Triggering unit))
      • Set Target[Index[0]] = (Target unit of ability being cast)
      • Set TempTargetPosition[Index[0]] = (Position of (Target unit of ability being cast))
      • -------- Now adding some effects --------
      • Special Effect - Create a special effect at TempTargetPosition[Index[0]] using Abilities\Spells\NightElf\Immolation\ImmolationTarget.mdl
      • Set SpecialEffect_chest[EffectIndex] = (Last created special effect)
      • Special Effect - Create a special effect attached to the origin of Target[Index[0]] using Abilities\Spells\NightElf\CorrosiveBreath\ChimaeraAcidTargetArt.mdl
      • Set SpecialEffect_origin[EffectIndex] = (Last created special effect)
      • Lightning - Create a Mana Flare lightning effect from source TempCasterPosition[Index[0]] to target TempTargetPosition[Index[0]]
      • Set Lightning[EffectIndex] = (Last created lightning effect)
      • -------- I also set the damage for easy reach --------
      • -------- you can reset the values below --------
      • Set DamageGiven[Index[0]] = 20.00
      • Set DamageMultiplier[Index[0]] = 15.00
      • -------- don't touch here --------
      • Set PoisonLevel[Index[0]] = (Level of Binding Poison for Caster[Index[0]])
      • Set Damage_A[Index[0]] = ((Real(PoisonLevel[Index[0]])) + DamageMultiplier[Index[0]])
      • Set Damage = (Damage_A[Index[0]] + DamageGiven[Index[0]])
      • Set time[TimeIndex] = (((Real(PoisonLevel[Index[0]])) x time_multiplier[Index[0]]) + 5.00)
      • -------- custom script below will remove leaking locations --------
      • Custom script: call RemoveLocation(udg_TempCasterPosition[udg_Index[0]])
      • Custom script: call RemoveLocation(udg_TempTargetPosition[udg_Index[0]])
      • -------- everything is ready to fire on the next trigger --------
      • Trigger - Turn on Casted <gen>
      • -------- now, the ability will take effect --------
  • Casted
    • Events
      • Time - Every 1.00 seconds of game time
    • Conditions
    • Actions
      • -------- starting the effect by setting the time --------
      • Set time[TimeIndex] = (time[TimeIndex] - 1.00)
      • Game - Display to (All players) for 1.50 seconds the text: (String(time[TimeIndex]))
      • -------- the effect of the ability --------
      • -------- I decided to pause the unit affected by the ability --------
      • Unit - Pause Target[Index[(Integer A)]]
      • -------- below is how the target gets the damage --------
      • Unit - Cause Caster[Index[0]] to damage Target[Index[(Integer A)]], dealing Damage damage of attack type Spells and damage type Normal
      • -------- -------------------------------------------------------------------------------------------------------- --------
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • time[TimeIndex] Greater than or equal to 1.00
        • Then - Actions
          • Lightning - Destroy Lightning[EffectIndex]
        • Else - Actions
      • -------- -------------------------------------------------------------------------------------------------------- --------
      • -------- if everything is done, this trigger will close for the next use of this ability --------
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • Or - Any (Conditions) are true
            • Conditions
              • time[TimeIndex] Less than or equal to 0.00
              • (Life of Target[Index[0]]) Equal to 0.00
        • Then - Actions
          • Unit - Unpause Target[Index[0]]
          • -------- Special effects destroyed at this point --------
          • Special Effect - Destroy SpecialEffect_chest[EffectIndex]
          • Special Effect - Destroy SpecialEffect_origin[EffectIndex]
          • -------- ------------------------------------------------------------------------------------------------------------ --------
          • -------- \\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\ --------
          • -------- AoE Units are affected just once --------
          • -------- Units sorrounding the enemy unit as target of ability being cast are also affected but after the effect of the ability. The AoE is set to 512.00 as default. --------
          • -------- You can disable or delete the actions below that runs the AoEso the ability will not have AoE --------
          • -------- \\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\ --------
          • -------- Setting something good for AoE --------
          • -------- You can reset the values below --------
          • Set AreaMultiplier[Index[0]] = 10
          • Set Damage_Area[Index[0]] = 390.00
          • -------- Don't try to touch anything below --------
          • Set AoE[Index[0]] = (PoisonLevel[Index[0]] x AreaMultiplier[Index[0]])
          • Set AoEReal[Index[0]] = ((Real(AoE[Index[0]])) + Damage_Area[Index[0]])
          • Set DamagedUnits[Index[0]] = (Units within AoEReal[Index[0]] of (Position of Target[Index[0]]))
          • Unit Group - Pick every unit in DamagedUnits[Index[(Integer A)]] and do (Actions)
            • Loop - Actions
              • Unit - Cause Caster[Index[0]] to damage (Picked unit), dealing Damage damage of attack type Spells and damage type Normal
          • Custom script: call DestroyGroup(udg_DamagedUnits[udg_Index[0]])
          • -------- ------------------------------------------------------------------------------------------------------------ --------
          • -------- and turned off this trigger --------
          • Trigger - Turn off (This trigger)
        • Else - Actions
      • -------- Spell Done --------
      • -------- -------------------------------------------------------------------------------------------------------- --------
 
You should make Abil level an array too if you will be using it that way... and maybe separate the triggers into three blocks?

and position of caster causes a leak...

you should do this:

add this line at the cast trigger before you create the dummy
set TempPoint = Position of Caster[index]

use TempPoint on the dummy creation action

then add this line at the end of the trigger

Custom script: call RemoveLocation(udg_TempPoint)
 
TempPosition whatsoever and DamageGroup should not be an array... AbilLevel is the one that needs to be an array...

I suggest removing the checking part which checks if the dummy is dead and move those actions inside of it to the second if-then-else, before anything that is currently on that block... and so remove the life timer too...

and as the mods suggest, use stun rather than pausing coz pausing is bad...
 
AoE + Level would result 251, 252, 253, etc. aoe, while the main comment for the aoe states 250, 500, 750, etc.. Is this indeed what you're after?
You can guide yourself through this, for future reference, because frankly, the current formula is too overpowered to use.
http://world-editor-tutorials.thehelper.net/formula.php

Damn, didn't see this:
  • Set BP_DamageInflict[BP_integer] = (BP_RealDamage x (Real((Level of Binding Poison for BP_Caster[BP_integer]))))
Use this in the cast trigger, not the looping one. Also, Level of ability is already saved; use that variable for reference.

Update it with the changes I told you, it would be a lot better.
 
Top