> For the complete documentation index, see [llms.txt](https://docs.hogwarp.com/hogwarp/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.hogwarp.com/hogwarp/scripting/server-side/api-documentation/server/playersystem.md).

# PlayerSystem

### Methods

<table data-full-width="true"><thead><tr><th align="right">Name</th><th align="center">Parameters</th><th align="center">Return</th><th>Description</th></tr></thead><tbody><tr><td align="right">GetById</td><td align="center">ulong Id</td><td align="center">Game.Player</td><td>Get a player by their ulong Id. (Game.Player.Id)</td></tr></tbody></table>

### Events

<table data-full-width="true"><thead><tr><th align="right">Name</th><th align="center">Return Type</th><th>Description</th></tr></thead><tbody><tr><td align="right">PlayerJoinEvent</td><td align="center">PlayerSystem.PlayerEvent?</td><td>Signals any time a player connects to the server.</td></tr><tr><td align="right">PlayerLeftEvent</td><td align="center">PlayerSystem.PlayerEvent?</td><td>Signals any time a player disconnects from the server.</td></tr></tbody></table>

### Delegates

<table data-full-width="true"><thead><tr><th align="right">Name</th><th>Parameters</th><th align="center">Return Type</th><th>Description</th></tr></thead><tbody><tr><td align="right">PlayerEvent</td><td>Game.Player Id</td><td align="center">void</td><td>Generic delegate for Player events.</td></tr></tbody></table>

### Variables

<table data-full-width="true"><thead><tr><th align="right">Name</th><th align="center">Type</th><th>Description</th></tr></thead><tbody><tr><td align="right">Players</td><td align="center">IEnumerable&#x3C;Game.Player></td><td>Iterable collection of Players.</td></tr></tbody></table>
