[Bug Fix] PR 1982 (#1985)

* Update spells.cpp

* [Bug Fix] PR 1982
This commit is contained in:
KayenEQ 2022-02-09 23:24:18 -05:00 committed by GitHub
parent a6d1652f44
commit fbbbd3b09d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 1 deletions

View File

@ -806,7 +806,9 @@ bool Client::UseDiscipline(uint32 spell_id, uint32 target) {
}
}
else {
CastSpell(spell_id, target, EQ::spells::CastingSlot::Discipline);
if (!CastSpell(spell_id, target, EQ::spells::CastingSlot::Discipline)) {
return false;
}
}
return(true);

View File

@ -209,6 +209,7 @@ bool Mob::CastSpell(uint16 spell_id, uint16 target_id, CastingSlot slot,
if (item_slot && IsClient() && (slot == CastingSlot::Item || slot == CastingSlot::PotionBelt))
{
if (!CheckItemRaceClassDietyRestrictionsOnCast(item_slot)) {
StopCastSpell(spell_id, send_spellbar_enable);
return false;
}
}
@ -6668,4 +6669,6 @@ bool Mob::CheckItemRaceClassDietyRestrictionsOnCast(uint32 inventory_slot) {
}
return(false);
}
return true;
}