mirror of
https://github.com/mangosfour/server.git
synced 2025-12-12 19:37:03 +00:00
Use PVPDificulty.dbc for bg/arena bracket selection (levels and difficulty)
This commit is contained in:
parent
75c81894b2
commit
63709fdc49
15 changed files with 167 additions and 98 deletions
|
|
@ -1129,7 +1129,6 @@ void BattleGround::RemovePlayerAtLeave(uint64 guid, bool Transport, bool SendPac
|
|||
// this method is called when no players remains in battleground
|
||||
void BattleGround::Reset()
|
||||
{
|
||||
SetBracketId(BG_BRACKET_ID_FIRST);
|
||||
SetWinner(WINNER_NONE);
|
||||
SetStatus(STATUS_WAIT_QUEUE);
|
||||
SetStartTime(0);
|
||||
|
|
@ -1835,3 +1834,9 @@ bool BattleGround::IsTeamScoreInRange(uint32 team, uint32 minScore, uint32 maxSc
|
|||
uint32 score = (m_TeamScores[team_idx] < 0) ? 0 : uint32(m_TeamScores[team_idx]);
|
||||
return score >= minScore && score <= maxScore;
|
||||
}
|
||||
|
||||
void BattleGround::SetBracket( PvPDifficultyEntry const* bracketEntry )
|
||||
{
|
||||
m_BracketId = bracketEntry->GetBracketId();
|
||||
SetLevelRange(bracketEntry->minLevel,bracketEntry->maxLevel);
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue