diff --git a/zone/lua_mob.cpp b/zone/lua_mob.cpp index 49dd21eee..8ceaef72f 100644 --- a/zone/lua_mob.cpp +++ b/zone/lua_mob.cpp @@ -878,7 +878,13 @@ bool Lua_Mob::CastSpell(int spell_id, int target_id) { bool Lua_Mob::CastSpell(int spell_id, int target_id, int slot) { Lua_Safe_Call_Bool(); - return self->CastSpell(spell_id, target_id, static_cast(slot)); + + int cast_slot = 0; + if (slot >= 0 || slot <= 23 || slot == 255) { + cast_slot = slot; + } + + return self->CastSpell(spell_id, target_id, static_cast(cast_slot)); } bool Lua_Mob::CastSpell(int spell_id, int target_id, int slot, int cast_time) {