Skip to main content

Leave a Party

Last updated on

Party members can choose to leave their party. If the party leader leaves the party, party leadership will be passed to another party member automatically. Party members that leave the party will receive a notification that they've left the party and current party members will also receive a notification that someone is leaving the party.

FRegistry::Lobby.Connect();
FRegistry::Lobby.SetLeavePartyResponseDelegate(AccelByte::Api::Lobby::FPartyLeaveResponse::CreateLambda([](const FAccelByteModelsLeavePartyResponse& Result)
{
if (Result.Code == "0")
{
// Do something if LeavePartyResponseDelegate has been successful
}
else
{
// Do something if LeavePartyResponseDelegate has an error
}
}));

FRegistry::Lobby.SendLeavePartyRequest();