Quick fix to resolve some serious group issues

Group leader swapping didn't work and left the client in a bad state
This just disbands the group if the leader leaves

Also prevents a group leader from disbanding other groups ...
Which also lead to bad states

Group leader swapping not working is better than these issues :P
This commit is contained in:
Michael Cook (mackal)
2017-02-24 01:12:46 -05:00
parent 72ed770037
commit 7621bf47c8
2 changed files with 21 additions and 7 deletions
+10
View File
@@ -581,6 +581,16 @@ bool Group::DelMember(Mob* oldmember, bool ignoresender)
return false;
}
// TODO: fix this shit
// okay, so there is code below that tries to handle this. It does not.
// So instead of figuring it out now, lets just disband the group so the client doesn't
// sit there with a broken group and there isn't any group leader shuffling going on
// since the code below doesn't work.
if (oldmember == GetLeader()) {
DisbandGroup();
return true;
}
for (uint32 i = 0; i < MAX_GROUP_MEMBERS; i++)
{
if (members[i] == oldmember)