PLAYERS
Player management and querying.
Availability: Client & Server
Methods
PLAYERS.disableMeshes
client
Hide all player meshes/models (client-side only)
Signature: action()
GAME.PLAYERS.disableMeshes();
PLAYERS.findByID
client server
Find a player by their unique ID
Signature: obj action(num)
Parameters:
| Name | Type | Description |
|---|---|---|
id | num | The player ID to find |
Returns: obj - The player object, or null if not found
obj result = GAME.PLAYERS.findByID(0);
PLAYERS.getSelf
client
Get the local player object (client-side only)
Signature: obj action()
Returns: obj - The local player object, or null if not available
obj self = GAME.PLAYERS.getSelf();
PLAYERS.list
client server
Get an array of all players currently in the game
Signature: obj[] action()
Returns: obj[] - Array of player objects
obj[] items = GAME.PLAYERS.list();
PLAYERS.toggleLOD
client
Toggle level-of-detail rendering for player models
Signature: action(bool)
Parameters:
| Name | Type | Description |
|---|---|---|
val | bool | Whether to enable LOD |
GAME.PLAYERS.toggleLOD(true);