Core/Creature: honor existing DB data for health and mana in case of summoned pets that don't have pet-specific stat data.

Closes #23570.

(cherry picked from commit 55570be6610483da129e40291e49090a8bc0f30c)
This commit is contained in:
Wyrserth
2021-12-16 22:01:10 +01:00
committed by Shauren
parent 537b425377
commit 434ef51c10
+2 -3
View File
@@ -845,9 +845,8 @@ bool Guardian::InitStatsForLevel(uint8 petlevel)
CreatureBaseStats const* stats = sObjectMgr->GetCreatureBaseStats(petlevel, cinfo->unit_class);
CreatureLevelScaling const* scaling = cinfo->GetLevelScaling(GetMap()->GetDifficultyID());
SetCreateHealth(sDB2Manager.EvaluateExpectedStat(ExpectedStatType::CreatureHealth, petlevel, cinfo->GetHealthScalingExpansion(), scaling->ContentTuningID, Classes(cinfo->unit_class)) * cinfo->ModHealth * cinfo->ModHealthExtra);
SetCreateMana(stats->BaseMana);
SetCreateHealth(sDB2Manager.EvaluateExpectedStat(ExpectedStatType::CreatureHealth, petlevel, cinfo->GetHealthScalingExpansion(), scaling->ContentTuningID, Classes(cinfo->unit_class)) * cinfo->ModHealth * cinfo->ModHealthExtra * _GetHealthMod(cinfo->rank));
SetCreateMana(stats->GenerateMana(cinfo));
SetCreateStat(STAT_STRENGTH, 22);
SetCreateStat(STAT_AGILITY, 22);
SetCreateStat(STAT_STAMINA, 25);