Core/Battleground: fix re-enter into battleground after disconnect
This commit is contained in:
1 parent
ced346076b
commit
2a38902d2e
3 files changed
+13
-7
No files matched your search
@@ -124,9 +124,17 @@ Map* MapInstanced::CreateInstanceForPlayer(const uint32 mapId, Player* player)
|
||||
// the instance id is set in battlegroundid
|
||||
NewInstanceId = player->GetBattlegroundId();
|
||||
if (!NewInstanceId) return NULL;
|
||||
map = FindInstanceMap(NewInstanceId);
|
||||
map = sMapMgr->FindMap(mapId, NewInstanceId);
|
||||
if (!map)
|
||||
map = CreateBattleground(NewInstanceId, player->GetBattleground());
|
||||
{
|
||||
if (Battleground* bg = player->GetBattleground())
|
||||
map = CreateBattleground(NewInstanceId, bg);
|
||||
else
|
||||
{
|
||||
player->TeleportToBGEntryPoint();
|
||||
return NULL;
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
Reference in new issue
Block a user