Socket

Socket is an extension of Socket.io’s Socket.

Socket.sessionID (string)

Used to identify a socket across sessions.

WARNING: Do not use this for punishments as the ID can easily be reset.

Socket.username (string)

A user’s username.

Make sure you use .toLowerCase() when doing comparisons.

Socket.room (string)

The user’s current room.

Socket.badge (string|null)

Default: null

Set to give a user a badge.

Uses Material Icons.

Socket.kick (Function)

Parameters: reason (string)

Kicks user for inputted reason.