Dummy doesn't cast

H34DhUnT3r

Ultra Cool Member
Reaction score
36
hi,

The problem with this trigger is that it doesn't cast cripple on all "images", only the first one. I have no idea why :banghead:
(the reason that i put the dummy creation and casting in a 2nd "foreachinteger" is that if i put it in the same it will not even create a 2nd image =.=

Trigger:
  • Mirror Image
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Mirror Image (Hero Tower)
    • Actions
      • Set tmpPoint = (Position of (Casting unit))
      • Set ImageAngle = 45.00
      • For each (Integer A) from 1 to (1 + (Level of (Ability being cast) for (Casting unit))), do (Actions)
        • Loop - Actions
          • Set tmpPointImage = (tmpPoint offset by 200.00 towards ImageAngle degrees)
          • Set ImageAngle = (ImageAngle + 90.00)
          • Unit - Create 1 BladeImage[(Level of (Ability being cast) for (Casting unit))] for (Owner of (Casting unit)) at tmpPointImage facing 270.00 degrees
          • Set Blade[(Integer A)] = (Last created unit)
          • Unit - Add a (10.00 + ((Real((Level of (Ability being cast) for (Casting unit)))) x 10.00)) second Generic expiration timer to (Last created unit)
          • Special Effect - Create a special effect at tmpPointImage using Abilities\Spells\Orc\FeralSpirit\feralspiritdone.mdl
          • Special Effect - Destroy (Last created special effect)
          • Custom script: call RemoveLocation(udg_tmpPointImage)
      • For each (Integer A) from 1 to 4, do (Actions)
        • Loop - Actions
          • Unit - Create 1 Dummy for (Owner of (Casting unit)) at tmpPoint facing Default building facing degrees
          • Unit - Order (Last created unit) to Undead Necromancer - Cripple Blade[(Integer A)]
          • Unit - Add a 1.00 second Generic expiration timer to (Last created unit)
      • Custom script: call RemoveLocation(udg_tmpPoint)


Greetings,
H34DhUnT3r[NL]
 

XeNiM666

I lurk for pizza
Reaction score
138
Change the 2nd For each integer to:
Trigger:
  • For each (Integer A) from 1 to (1 + (Level of (Ability being cast) for (Casting unit))), do (Actions)

So its:
Trigger:
  • * Mirror Image
    • o Events
      • + Unit - A unit Starts the effect of an ability
    • o Conditions
      • + (Ability being cast) Equal to Mirror Image (Hero Tower)
    • o Actions
      • + Set tmpPoint = (Position of (Casting unit))
      • + Set ImageAngle = 45.00
      • + For each (Integer A) from 1 to (1 + (Level of (Ability being cast) for (Casting unit))), do (Actions)
        • # Loop - Actions
          • * Set tmpPointImage = (tmpPoint offset by 200.00 towards ImageAngle degrees)
          • * Set ImageAngle = (ImageAngle + 90.00)
          • * Unit - Create 1 BladeImage[(Level of (Ability being cast) for (Casting unit))] for (Owner of (Casting unit)) at tmpPointImage facing 270.00 degrees
          • * Set Blade[(Integer A)] = (Last created unit)
          • * Unit - Add a (10.00 + ((Real((Level of (Ability being cast) for (Casting unit)))) x 10.00)) second Generic expiration timer to (Last created unit)
          • * Special Effect - Create a special effect at tmpPointImage using Abilities\Spells\Orc\FeralSpirit\feralspiritdone.mdl
          • * Special Effect - Destroy (Last created special effect)
          • * Custom script: call RemoveLocation(udg_tmpPointImage)
      • + For each (Integer A) from 1 to (1 + (Level of (Ability being cast) for (Casting unit))), do (Actions)
        • # Loop - Actions
          • * Unit - Create 1 Dummy for (Owner of (Casting unit)) at tmpPoint facing Default building facing degrees
          • * Unit - Order (Last created unit) to Undead Necromancer - Cripple Blade[(Integer A)]
          • * Unit - Add a 1.00 second Generic expiration timer to (Last created unit)
      • + Custom script: call RemoveLocation(udg_tmpPoint)


Oh and change all (Casting unit)s to (Triggering unit)
 

XeNiM666

I lurk for pizza
Reaction score
138
Well its faster because Casting unit returns to Triggering unit which is unoticably slower. And its more MUI. :)
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top