• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

Loop/Wait Bug(?)

Status
Not open for further replies.
Level 1
Joined
Mar 18, 2009
Messages
2
I am having an issue where I have multiple dummy units created by a loop, that fire impale at a polar offset point. Inbetween firings I have a brief wait to make it appear as a rotating arm effect. However when I test it my loop ends after 2-3 iterations after working correctly, when it is supposed to be 24 iterations.

  • Set MarkoftheDivineAngle = 0.00
  • Set MarkPoint = (Target point of ability being cast)
  • For each (Integer A) from 1 to 24, do (Actions)
    • Loop - Actions
      • Unit - Create 1 Dummy Caster 2 for (Owner of (Triggering unit)) at MarkPoint facing Default building facing degrees
      • Unit - Set level of Mark of Divinity Effect (Neutral Hostile) for (Last created unit) to (Level of Mark of the Divine for (Triggering unit))
      • Unit - Add a 3.00 second Generic expiration timer to (Last created unit)
      • Unit - Order (Last created unit) to Undead Crypt Lord - Impale (MarkPoint offset by 256.00 towards MarkoftheDivineAngle degrees)
      • Unit - Create 1 Dummy Caster 2 for (Owner of (Triggering unit)) at MarkPoint facing Default building facing degrees
      • Unit - Set level of Mark of Divinity Effect (Neutral Hostile) for (Last created unit) to (Level of Mark of the Divine for (Triggering unit))
      • Unit - Add a 3.00 second Generic expiration timer to (Last created unit)
      • Unit - Order (Last created unit) to Undead Crypt Lord - Impale (MarkPoint offset by 256.00 towards (MarkoftheDivineAngle + 180.00) degrees)
      • Set MarkoftheDivineAngle = (MarkoftheDivineAngle + 30.00)
      • Wait 0.17 game-time seconds
Any ideas as to why it's stopping at random?
 
Level 1
Joined
Mar 18, 2009
Messages
2
I solved it by pasting the code 24 times rather than the loop, any ideas as to why this worked?
 
Status
Not open for further replies.
Top