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

Status
Not open for further replies.
Level 2
Joined
Nov 28, 2015
Messages
8
Hi again, people. Can you help me out on how to make a "wait timer" in loop trigger? I mean for example, you are going to make a spell which has a charging peroid of time to give it a virtual massive blast?
 
Last edited by a moderator:
Level 24
Joined
Aug 1, 2013
Messages
4,657
Hi again, people.
Can you help me out on how to make a "wait timer" in loop trigger?
I mean for example, you are going to make a spell which has a charging peroid of time to give it a virtual massive blast?

All help appreciated.

Fixed it for you.
You can use waits in loops... if you want timers, you can go for either dynamic indexing or learn JASS :D
 
Level 12
Joined
Jan 2, 2016
Messages
973
You can use wait(s) in loops, if you are using a unique variable for the loop (not IntegerA/B), that isn't used in any other triggers.
You can NOT use wait's only in "pick all units in group and do actions". This is another kind of loop tho.
If you want to use wait in the 2-nd kind of loop - you could do something like this:
loop:
do some actions
set Temp_Unit = Picked Unit
run trigger 2 (checking conditions)

trigger 2:
local unit u = udg_Temp_Unit (this is done via custom script)
wait (the amount you want)
set udg_Temp_Unit = u (this is also done via custom script)
do the rest of the actions you want.

(This is one of the ways to do in in GUI, but doing it in JASS is easier)
 
Status
Not open for further replies.
Top