mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-21 17:54:48 +01:00
Use PVPDificulty.dbc for bg/arena bracket selection (levels and difficulty). Rename BG/arena queue_id to bracket_id and related functions/etc. Author: VladimirMangos.
--HG-- branch : trunk
This commit is contained in:
@@ -219,10 +219,10 @@ BattleGroundMap* MapInstanced::CreateBattleGround(uint32 InstanceId, BattleGroun
|
||||
|
||||
sLog.outDebug("MapInstanced::CreateBattleGround: map bg %d for %d created.", InstanceId, GetId());
|
||||
|
||||
// 0-59 normal spawn 60-69 difficulty_1, 70-79 difficulty_2, 80 dufficulty_3
|
||||
uint8 spawnMode = (bg->GetQueueId() > QUEUE_ID_MAX_LEVEL_59) ? (bg->GetQueueId() - QUEUE_ID_MAX_LEVEL_59) : 0;
|
||||
while (!GetMapDifficultyData(GetId(), Difficulty(spawnMode)))
|
||||
spawnMode--;
|
||||
PvPDifficultyEntry const* bracketEntry = GetBattlegroundBracketByLevel(bg->GetMapId(),bg->GetMinLevel());
|
||||
|
||||
uint8 spawnMode = bracketEntry ? bracketEntry->difficulty : REGULAR_DIFFICULTY;
|
||||
|
||||
BattleGroundMap *map = new BattleGroundMap(GetId(), GetGridExpiry(), InstanceId, this, spawnMode);
|
||||
ASSERT(map->IsBattleGroundOrArena());
|
||||
map->SetBG(bg);
|
||||
|
||||
Reference in New Issue
Block a user