Core/Pools: Attempt to workaround pools being broken

Port From (https://github.com/TrinityCore/TrinityCore/commit/74923df35afe6f41b94edada701d50fc53bbaf6e)
This commit is contained in:
hondacrx
2022-02-27 23:38:18 -05:00
parent f55e8ae73c
commit bb094c585b
+2 -2
View File
@@ -585,7 +585,7 @@ namespace Game
roll -= obj.chance;
// Triggering object is marked as spawned at this time and can be also rolled (respawn case)
// so this need explicit check for this case
if (roll < 0 && (obj.guid == triggerFrom || !spawns.IsActiveObject<T>(obj.guid)))
if (roll < 0 && (/*obj.guid == triggerFrom ||*/ !spawns.IsActiveObject<T>(obj.guid)))
{
rolledObjects.Add(obj);
break;
@@ -595,7 +595,7 @@ namespace Game
if (!EqualChanced.Empty() && rolledObjects.Empty())
{
rolledObjects.AddRange(EqualChanced.Where(obj => obj.guid == triggerFrom || !spawns.IsActiveObject<T>(obj.guid)));
rolledObjects.AddRange(EqualChanced.Where(obj => /*obj.guid == triggerFrom ||*/ !spawns.IsActiveObject<T>(obj.guid)));
rolledObjects.RandomResize((uint)count);
}