PcoWSkbVqDnWTu_dm2ix
The Developer Hub is now deprecated and information on this page may no longer be accurate. To see our new and improved documentation, please click here. You can read more about the future of documentation here.
Collapse Sidebar

Neutral

Player

bool

The Neutral property determines whether the player is on a specific team.

  • When true, the player is not on a specific team. This also means that the Player/Team property will be nil and the Player/TeamColor will be white.
  • When false, the player is on a specific team. The Player/Team property will correspond to the Team that the player is on, as will the Player/TeamColor.


Code Samples


Checking if a Player is Neutral

This example checks if a player is neutral. If the player is neutral, the game prints:

Player is neutral!

If the player is neutral, the game prints:

Player is not neutral!

Note: Although this example prints the value of the local player’s neutral property, you can change the example to get the value for any player.