OnPlayerLeaveArea
A player left one of the map’s areas.
They walked out, were moved, or the area was changed, taken away or its layer switched off. Not when they leave the server
(OnPlayerDisconnect).
Syntax
Section titled “Syntax”function OnPlayerLeaveArea(pid, area) -- ...end| Parameter | Type | |
|---|---|---|
pid |
number | the player |
area |
string | the area’s name |
Example
Section titled “Example”function OnPlayerLeaveArea(pid, area) if area == "Arena" then EndFight(pid) endendSee also
Section titled “See also”OnPlayerEnterArea · the The map’s areas group of the index
