Classes
Players
Players
hold the connected clients
You cannot Instance this class with
Instance.new()
Properties
PlayerCount: int
The PlayerCount
holds a int value which has the total number of players in the game server
RespawnTime: int
The property holds a int value which is number of seconds to spawn player after players death. This is read only for client sided scripts and can be changed by server sided scripts.
Functions
GetPlayer(string username)
GetPlayer
will return a Player
type. An example:
GetLocalPlayer()
Returns localPlayer as a Player
type. This function can only be called by client-sided scripts. An example:
Signals
OnPlayerEntered
The signal is called when a new player joins the game. This is valid on both: client sided and server sided scripts. An example:
OnPlayerLeft
The signal is called when a player leaves the game. This is valid on both: client sided and server sided scripts. An example: