Skip to content

KcdMp.on_party_change

A hook called with the party after every change.

Set it to a function to hear every PartyState (membership, leader, name, labels, the frames switch) and every vitals update (at most twice a second). The argument is KcdMp.party; an empty party (id 0) means the player left or the party ended. An error inside is logged ([KcdMp] on_party_change: ...).

KcdMp.on_party_change

function | nil - function(party) end, or nil for no hook

KcdMp.on_party_change = function(party)
if party.id ~= 0 then print("party " .. party.id .. ": " .. #party.members .. " member(s)") end
end

KcdMp.party · the The party group of the index