• Check out the results of the Techtree Contest #19!
  • 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.
  • Create a void inspired texture for Warcraft 3 and enter Hive's 34th Texturing Contest: Void! Click here to enter!
  • The Hive's 22nd Icon Contest: Creep Abilities is now concluded, time to vote for your favourite set of icons! Click here to vote!

How to detect idle unit

Status
Not open for further replies.
Hello guys, I would like to ask how do you get all idle units?

Tried this and did'nt work. I even tried to invert the condition (/= Order(move) || /= Order(smart) || /= Order(holdposition)) but also didn't work.

I will really appreciate a help. :)

- Please don't mind the part where I pick all units in the map, it's only being tested the test map for now.

  • get idle unit
    • Events
      • Time - Every 1.00 seconds of game time
    • Conditions
    • Actions
      • Unit Group - Pick every unit in (Units in (Playable map area)) and do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (Current order of (Picked unit)) Equal to (Order(stop))
            • Then - Actions
              • Game - Display to (All players) the text: someone is idle!
              • Unit - Kill (Picked unit)
            • Else - Actions
              • Do nothing
 
Status
Not open for further replies.
Back
Top