From df7218cae58369e5e7cc37469eff7e9965b227e0 Mon Sep 17 00:00:00 2001 From: hondacrx Date: Sun, 29 May 2022 16:06:09 -0400 Subject: [PATCH] Core/Spawns: prevent spawn groups from bypassing spawnMask restrictions Port From (https://github.com/TrinityCore/TrinityCore/commit/21177487ea9476cb4db3f498353c340181d87e14) --- Source/Game/Maps/Map.cs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Source/Game/Maps/Map.cs b/Source/Game/Maps/Map.cs index 0a5437b84..0c126f4c4 100644 --- a/Source/Game/Maps/Map.cs +++ b/Source/Game/Maps/Map.cs @@ -2794,6 +2794,10 @@ namespace Game.Maps foreach (SpawnData data in toSpawn) { + // don't spawn if the current map difficulty is not used by the spawn + if (!data.SpawnDifficulties.Contains(GetDifficultyID())) + continue; + // don't spawn if the grid isn't loaded (will be handled in grid loader) if (!IsGridLoaded(data.SpawnPoint)) continue;