Core/BattlePets: BattlePetError enum class (#27286)

This commit is contained in:
Meji
2021-11-19 14:01:22 +01:00
committed by GitHub
parent f97deb3316
commit 12cc779ab0
3 changed files with 11 additions and 21 deletions

View File

@@ -5658,14 +5658,14 @@ void Spell::EffectUncageBattlePet()
if (battlePetMgr->GetMaxPetLevel() < level)
{
battlePetMgr->SendError(BATTLEPETRESULT_TOO_HIGH_LEVEL_TO_UNCAGE, speciesEntry->CreatureID);
battlePetMgr->SendError(BattlePetError::TooHighLevelToUncage, speciesEntry->CreatureID);
SendCastResult(SPELL_FAILED_CANT_ADD_BATTLE_PET);
return;
}
if (battlePetMgr->HasMaxPetCount(speciesEntry))
{
battlePetMgr->SendError(BATTLEPETRESULT_CANT_HAVE_MORE_PETS_OF_THAT_TYPE, speciesEntry->CreatureID);
battlePetMgr->SendError(BattlePetError::CantHaveMorePetsOfType, speciesEntry->CreatureID);
SendCastResult(SPELL_FAILED_CANT_ADD_BATTLE_PET);
return;
}