OnClientPlayerQuit

From Multi Theft Auto: Wiki
Revision as of 02:02, 27 January 2008 by Talidan (talk | contribs) (Clientside functions cant print to the server window...)
Jump to navigation Jump to search

This event is triggered when a remote player quits the game or leaves the server.

Parameters

string reason
  • reason: A string representing the reason why the player quit.

Quit reason string can be: - "Unknown" - "Quit" - "Kicked" - "Banned" - "Bad Connection" - "Timed out"

Source

The source of this event is the player that quit the game.

Example

This example prints a message in the chatbox when a remote player leaves the server.

function onQuitGame( reason )
    outputChatBox ( getPlayerName( source ).." has left the server ("..reason..")" )
end
addEventHandler( "onClientPlayerQuit", getRootElement(), onQuitGame )

See Also

Client player events


Client event functions