Missed files.

This commit is contained in:
hondacrx
2022-10-04 22:25:53 -04:00
parent 4b00446c1b
commit 5baac43590
2 changed files with 4 additions and 8 deletions
@@ -25,15 +25,8 @@ using System.Collections.Generic;
namespace Game.Maps
{
//#define INSTANCE_ID_HIGH_MASK 0x1F440000
//#define INSTANCE_ID_LFG_MASK 0x00000001
//#define INSTANCE_ID_NORMAL_MASK 0x00010000
using InstanceLockKey = Tuple<uint, uint>;
//using PlayerLockMap = std::unordered_map<InstanceLockKey, std::unique_ptr<InstanceLock>>;
//using LockMap = std::unordered_map<ObjectGuid, PlayerLockMap>;
public class InstanceLockManager : Singleton<InstanceLockManager>
{
object _lockObject = new();
@@ -194,6 +187,9 @@ namespace Game.Maps
instanceLock = new InstanceLock(entries.MapDifficulty.MapID, (Difficulty)entries.MapDifficulty.DifficultyID,
GetNextResetTime(entries), 0);
if (!_temporaryInstanceLocksByPlayer.ContainsKey(playerGuid))
_temporaryInstanceLocksByPlayer[playerGuid] = new Dictionary<InstanceLockKey, InstanceLock>();
_temporaryInstanceLocksByPlayer[playerGuid][entries.GetKey()] = instanceLock;
Log.outDebug(LogFilter.Instance, $"[{entries.Map.Id}-{entries.Map.MapName[Global.WorldMgr.GetDefaultDbcLocale()]} | " +
$"{entries.MapDifficulty.DifficultyID}-{CliDB.DifficultyStorage.LookupByKey(entries.MapDifficulty.DifficultyID).Name}] Created new temporary instance lock for {playerGuid} in instance {instanceId}");
+1 -1
View File
@@ -155,7 +155,7 @@ namespace Game.Maps
void LoadDungeonEncounterData(uint bossId, uint[] dungeonEncounterIds)
{
if (bossId < bosses.Count)
for (int i = 0; i < MapConst.MaxDungeonEncountersPerBoss; ++i)
for (int i = 0; i < dungeonEncounterIds.Length && i < MapConst.MaxDungeonEncountersPerBoss; ++i)
bosses[bossId].DungeonEncounters[i] = CliDB.DungeonEncounterStorage.LookupByKey(dungeonEncounterIds[i]);
}