maxPlayers

(info) Other great resources: Official JS API docs, Scripting Forum

maxPlayers

Defines the maximum number of human/AI player slots on the current map, regardless of whether those slots are filled in the current game.

 

Notes

Scavenger faction is not a normal player slot as far as Warzone is concerned. For more information, see scavengerPlayer.

Example

Get list of droids for all players
// go through each player in turn and get a list of their droids for (var i = 0; i < maxPlayers; i++) { var droids = enumDroid(i); // get droids for player // do stuff }