OnClientChangeNick

From Multi Theft Auto: Wiki
Revision as of 16:14, 17 January 2015 by Lopez (talk | contribs)
Jump to navigation Jump to search

Template:DeprecatedWithAlt

This event is triggered when a player changes his nickname.

Parameters

string oldNick, string newNick
  • oldNick: the nickname the player had before.
  • newNick: the new nickname of the player.

Source

The source of this event is the player that changed his nick

Example

function nickChangeHandler(oldNick, newNick)
outputChatBox(oldNick.." is now known as "..newNick, getRootElement(), 255, 100, 100) -- display the message
end
addEventHandler("onClientChangeNick", getRootElement(), nickChangeHandler) -- add an event handler

See Also

Client events


Event functions