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

[General] Ally System.

Status
Not open for further replies.
Level 18
Joined
Jan 12, 2011
Messages
1,513
Ok so i need a trigger which when the host types -teams
it needs to detect how many players are in the game and then reorder the teams into 2 teams (example there are 12 players, host types -teams and then players sepparate into 6v6), if there are less players (example: 8 players ingame) then it would be a 4v4.

and the trigger needs to disable ally/unally.
 
Level 4
Joined
Aug 5, 2011
Messages
99
  • trigger!!
    • Events
      • Player - Player 1 (Red) types a chat message containing -teams as An exact match
    • Conditions
    • Actions
      • Set numberofplayers = (Number of players in (All players controlled by a User player))
      • For each (Integer A) from 1 to 12, do (Actions)
        • Loop - Actions
          • For each (Integer A) from 1 to (numberofplayers / 2), do (Actions)
            • Loop - Actions
              • Player - Make (Player((Integer A))) treat (Player((Integer B))) as an Ally with shared vision
          • For each (Integer A) from ((numberofplayers / 2) + 1) to numberofplayers, do (Actions)
            • Loop - Actions
              • Player - Make (Player((Integer A))) treat (Player((Integer B))) as an Ally with shared vision
something like that shud work normally, didnt test it tho
 
Status
Not open for further replies.
Top