[7353] Fixed problem with joining rated arena matches. Thanks to balrok for help.

Signed-off-by: Triply <triply@getmangos.com>
This commit is contained in:
Triply 2009-02-27 14:20:31 +01:00
parent 0be003ac90
commit a81d174288
10 changed files with 99 additions and 72 deletions

View file

@ -381,7 +381,7 @@ bool ChatHandler::HandleNamegoCommand(const char* args)
}
// all's well, set bg id
// when porting out from the bg, it will be reset to 0
chr->SetBattleGroundId(m_session->GetPlayer()->GetBattleGroundId());
chr->SetBattleGroundId(m_session->GetPlayer()->GetBattleGroundId(), m_session->GetPlayer()->GetBattleGroundTypeId());
// remember current position as entry point for return at bg end teleportation
chr->SetBattleGroundEntryPoint(chr->GetMapId(),chr->GetPositionX(),chr->GetPositionY(),chr->GetPositionZ(),chr->GetOrientation());
}
@ -499,7 +499,7 @@ bool ChatHandler::HandleGonameCommand(const char* args)
}
// all's well, set bg id
// when porting out from the bg, it will be reset to 0
_player->SetBattleGroundId(chr->GetBattleGroundId());
_player->SetBattleGroundId(chr->GetBattleGroundId(), chr->GetBattleGroundTypeId());
// remember current position as entry point for return at bg end teleportation
_player->SetBattleGroundEntryPoint(_player->GetMapId(),_player->GetPositionX(),_player->GetPositionY(),_player->GetPositionZ(),_player->GetOrientation());
}