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

[SOLVED] UnitGroup Ally

Status
Not open for further replies.
Level 20
Joined
Jul 6, 2009
Messages
1,885
Try something like this
  • Unit Group - Pick every unit in YourGroup and do (Actions)
    • Loop - Actions
      • Set Owner = (Owner of (Picked unit))
      • Unit Group - Pick every unit in YourGroup and do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • Owner Not equal to (Owner of (Picked unit))
            • Then - Actions
              • Player - Make Owner treat (Owner of (Picked unit)) as an Ally with shared vision
            • Else - Actions
 
Status
Not open for further replies.
Top