Core/Spells: Add server-side check for spells that require combo points to prevent exploits
--HG-- branch : trunk
This commit is contained in:
@@ -5728,6 +5728,10 @@ SpellCastResult Spell::CheckCast(bool strict)
|
||||
return SPELL_FAILED_ITEM_ALREADY_ENCHANTED;
|
||||
}
|
||||
|
||||
// check if caster has at least 1 combo point for spells that require combo points
|
||||
if (m_needComboPoints && m_caster->ToPlayer() && !m_caster->ToPlayer()->GetComboPoints())
|
||||
return SPELL_FAILED_NO_COMBO_POINTS;
|
||||
|
||||
// all ok
|
||||
return SPELL_CAST_OK;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user