PlayerQuit
This event is triggered when a player quit from the server.
Parameters
- player - player, which quit from the server.
- exitType - exit type from the server:
- disconnect
- timeout
- kicked
- reason - reason of quit from the server if exit type is "kicked".
Example
function playerJoinHandler(player) {
console.log(player.name + " joined to server.");
}
mp.events.add(
{
"playerQuit": playerJoinHandler
});