Core/Spell: fix LoS checks for GameObject spells

Port From (https://github.com/TrinityCore/TrinityCore/commit/50fe2dc7e305fa32d30bac6ad0ced2e5647ac02b)
This commit is contained in:
hondacrx
2021-09-08 23:35:22 -04:00
parent b530251d6c
commit b071efe105
3 changed files with 20 additions and 1 deletions
@@ -275,6 +275,19 @@ namespace Game.Entities
}
}
public uint GetRequireLOS() => type switch
{
GameObjectTypes.Button => Button.requireLOS,
GameObjectTypes.QuestGiver => QuestGiver.requireLOS,
GameObjectTypes.Chest => Chest.requireLOS,
GameObjectTypes.Trap => Trap.requireLOS,
GameObjectTypes.Goober => Goober.requireLOS,
GameObjectTypes.FlagStand => FlagStand.requireLOS,
GameObjectTypes.NewFlag => NewFlag.requireLOS,
GameObjectTypes.GatheringNode => GatheringNode.requireLOS,
_ => 0,
};
public uint GetLockId()
{
switch (type)