Core/Creatures: Fixed level 240 guards and updated scaling level calculation

Port From (https://github.com/TrinityCore/TrinityCore/commit/82b4ca3b7c2329e571d0a341b8a5ab366a5d26f4)
This commit is contained in:
hondacrx
2020-05-20 20:04:00 -04:00
parent 29991a2062
commit ea80678e9a
7 changed files with 68 additions and 35 deletions
+1 -1
View File
@@ -154,7 +154,7 @@ namespace Game
if (gain != 0 && creature)
{
// Players get only 10% xp for killing creatures of lower expansion levels than himself
if ((creature.GetCreatureTemplate().HealthScalingExpansion < (int)GetExpansionForLevel(player.GetLevel())))
if ((creature.GetCreatureTemplate().GetHealthScalingExpansion() < (int)GetExpansionForLevel(player.GetLevel())))
gain = (uint)Math.Round(gain / 10.0f);
if (creature.IsElite())