Core/Misc: When a player changes its faction its only removed from all its arena teams if cross-faction interaction is turned off.
This commit is contained in:
@@ -1919,6 +1919,8 @@ void WorldSession::HandleCharFactionOrRaceChange(WorldPacket& recvData)
|
||||
if (result)
|
||||
if (Guild* guild = sGuildMgr->GetGuildById((result->Fetch()[0]).GetUInt32()))
|
||||
guild->DeleteMember(MAKE_NEW_GUID(lowGuid, 0, HIGHGUID_PLAYER), false, false, true);
|
||||
|
||||
Player::LeaveAllArenaTeams(guid);
|
||||
}
|
||||
|
||||
if (!HasPermission(rbac::RBAC_PERM_TWO_SIDE_ADD_FRIEND))
|
||||
@@ -1931,12 +1933,8 @@ void WorldSession::HandleCharFactionOrRaceChange(WorldPacket& recvData)
|
||||
stmt = CharacterDatabase.GetPreparedStatement(CHAR_DEL_CHAR_SOCIAL_BY_FRIEND);
|
||||
stmt->setUInt32(0, lowGuid);
|
||||
trans->Append(stmt);
|
||||
|
||||
}
|
||||
|
||||
// Leave Arena Teams
|
||||
Player::LeaveAllArenaTeams(guid);
|
||||
|
||||
// Reset homebind and position
|
||||
stmt = CharacterDatabase.GetPreparedStatement(CHAR_DEL_PLAYER_HOMEBIND);
|
||||
stmt->setUInt32(0, lowGuid);
|
||||
|
||||
Reference in New Issue
Block a user