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

[Trigger] Why this don't work?

Status
Not open for further replies.
Level 10
Joined
Aug 15, 2008
Messages
720
  • Shield of Light
    • Events
      • Unit - A unit Finishes casting an ability
    • Conditions
      • (Ability being cast) Equal to (==) Shield of Light
    • Actions
      • Custom script: local unit udg_Target
      • Custom script: local unit udg_Caster
      • Custom script: local group udg_tempGroup
      • Custom script: local location udg_tempLoc
      • Set Target = (Target unit of ability being cast)
        • Do Multiple ActionsFor each (Integer A) from 1 to 20, do (Actions)
          • Loop - Actions
            • Set tempLoc = (Position of Target)
            • Set tempGroup = (Units within 500.00 of tempLoc)
              • Do Multiple ActionsFor each (Integer A) from 1 to (Hero level of Blood Mage 0001 <gen>), do (Actions)
                • Loop - Actions
                  • Unit - Create 1 dummy for (Owner of Target) at tempLoc facing Default building facing (270.0) degrees
                  • Unit - Add a 1.50 second Generic expiration timer to (Last created unit)
                  • Unit - Add Forked Lightning (Shield of Light) to (Last created unit)
                  • Unit Group - Pick every unit in tempGroup and do (Actions)
                    • Loop - Actions
                      • Unit - Order (Last created unit) to Neutral Naga Sea Witch - Forked Lightning (Random unit from tempGroup)
            • Wait 0.50 seconds
      • Custom script: call RemoveLocation(udg_tempLoc)
      • Custom script: call DestroyGroup(udg_tempGroup)
 
Level 10
Joined
Aug 15, 2008
Messages
720
I am doing like in this tutorial, since I don't know way how to make MUI with waits:
http://www.hiveworkshop.com/forums/...279/multi-instancible-gui-spell-making-34393/

And if I won't use these custom scripts with local etc. , then spell won't be MUI and will bug.

More Details:
#dummy casts Forked lightning what damage is 15 and uses Chain Heal lightning
#Spell Idea is that you cast unharming Lightning Shield type of spell and it will last for 10 seconds, with cooldown of 11
#How Much dumies are created are equal to heros level
#Every 0.50 secs X dumies are created and ordered to shoot lightning to any near random unit.
 
Level 12
Joined
Dec 10, 2008
Messages
850
Well sorry, but it will NEVER work unless you remove all but one local unless you use JASS. Set them as globals and use arrays and the like. Does your dummy unit have the mana to cast forked lightning? How about cooldown? And change the finishs casting ability in Events to Unit-A unit begins casting an ability.
 
Level 10
Joined
Aug 15, 2008
Messages
720
Arrays can make MPI, but I need MUI...

About script in jass... I only know basic scripts, so I can't script it in JASS.
And as I said whats the use if I delete those locals or not, fine I take arrays, but then its MPI, if I take normal variables, then spell bugs...
 
Status
Not open for further replies.
Top