Skip to content

OnPlayerLeaveParty

A member is gone from the party.

reason is "left" (RemovePlayerFromParty), "kicked" (the same with "kicked"), "disconnect", or "disband"

  • the mode’s DisbandParty, the leader’s leaving under leader_leaves = "disband", or the last member standing when the party fell to one. The member’s label is gone with the membership.
function OnPlayerLeaveParty(party, pid, reason)
-- ...
end
Parameter Type
party number the party
pid number the member who left
reason string "left", "kicked", "disconnect" or "disband"

nothing

function OnPlayerLeaveParty(party, pid, reason)
if reason ~= "disband" then
SendPartyMessage(party, COLOUR_SERVER, GetPlayerName(pid) .. " left the party (" .. reason .. ").")
end
end

OnPlayerJoinParty · RemovePlayerFromParty · OnPartyDisband · the Parties group of the index