Triggers/Category Player Group

From SC2Mapster Wiki
Jump to: navigation, search

Groups[edit | edit source]

Add Player Group To Player Group[edit | edit source]

  • Action. Adds the players in one player group to another player group.

Add Player To Player Group[edit | edit source]

  • Action. Adds a player to a player group.

Remove All Players From Player Group[edit | edit source]

  • Action. Clears a player group so it no longer has any players in it.

Copy Of Player Group[edit | edit source]

  • Function. Returns the copy of a player group.

Number Of Players In Player Group[edit | edit source]

  • Function. Returns the number of players in a player group.

Player In Player Group[edit | edit source]

  • Function. Returns true if the specified player is in the specified player group.

Player From Player Group[edit | edit source]

  • Function. Returns the player stored at the specified Index of the specified player group. For example: If you have players 4, 5, and 6 in a player group Index 1 would be Player 4, and this function would return 4.

Remove Player From Player Group[edit | edit source]

  • Action. Removes a player from the specified player group.

Remove Player Group From Player Group[edit | edit source]

  • Action. Removes all the players in one player group from another player group.

Loops[edit | edit source]

For Each Player In Player Group[edit | edit source]

  • Action. Executes a For Loop using an integer value. This will run the action set included under the For Each Player In Player Group action for every player in the specified player group. For example: If you put a "Set Player Color" action that changed the color for Player <Integer variable>, under a For Each Player In Player Group action with the Player Group parameter set to All Players, it would change the color for all players.

Pick Each Player In Player Group[edit | edit source]

  • Action. Picks each player in the specified Player Group and runs the associated action set. The "Picked Player" function must be used to reference the iterating value inside of the loop.

Picked Player[edit | edit source]

  • Function. Returns an integer value equal to the iterating value inside of a "Pick Each Player In Player Group" action. This function will return 0 if used outisde of a pick each player in group loop.

Useful Player Groups[edit | edit source]

Active Players[edit | edit source]

  • Function. Returns a player group containing all active players.

All Players[edit | edit source]

  • Function. Returns a player group containing all players.

Allies/Enemies Of Player[edit | edit source]

  • Function. Returns all players that are considered allies or enemies, determined by the Alliance parameter, of the specified player.

Empty Player Group[edit | edit source]

  • Function. Returns an empty player group.

Convert Player To Player Group[edit | edit source]

  • Function. Returns a player group containing the specified player. This allows you to call a specific player as a player group parameter in triggers.