PlayerRemoving (Event): Difference between revisions
From Legacy Roblox Wiki
Jump to navigationJump to search
>Camoy Fixed formatting |
>Camoy Format/example |
||
Line 1: | Line 1: | ||
{| | {| | ||
|<onlyinclude>{{Event|name=PlayerRemoving | |<onlyinclude>{{Event|name = PlayerRemoving | ||
|arguments=[[Instance]] '' | |arguments = [[Instance]] ''player'' | ||
|description= Fired after a player leaves the game. | |description = Fired after a player leaves the game. | ||
|object= [[ | |object = [[Players]] | ||
|}}</onlyinclude> | |}}</onlyinclude> | ||
|} | |} | ||
{{Example| | {{Example| | ||
<pre>function onPlayerLeaving(Player) | <pre> | ||
print(Player.Name .. " has left the game!") | local function onPlayerLeaving(Player) | ||
print(Player.Name.." has left the game!") | |||
end | end | ||
game.Players.PlayerRemoving:connect(onPlayerLeaving)</pre>}} | game.Players.PlayerRemoving:connect(onPlayerLeaving) | ||
</pre>}} |
Revision as of 15:58, 29 August 2010
|
Example
local function onPlayerLeaving(Player) print(Player.Name.." has left the game!") end game.Players.PlayerRemoving:connect(onPlayerLeaving)