mirror of
https://github.com/EQEmu/Server.git
synced 2025-12-12 22:01:30 +00:00
[Crash] Fix Crash in FindType (#2867)
This commit is contained in:
parent
4df9661903
commit
b3fd9dd88a
@ -5892,8 +5892,7 @@ uint16 Mob::GetSpellIDFromSlot(uint8 slot)
|
|||||||
bool Mob::FindType(uint16 type, bool bOffensive, uint16 threshold) {
|
bool Mob::FindType(uint16 type, bool bOffensive, uint16 threshold) {
|
||||||
int buff_count = GetMaxTotalSlots();
|
int buff_count = GetMaxTotalSlots();
|
||||||
for (int i = 0; i < buff_count; i++) {
|
for (int i = 0; i < buff_count; i++) {
|
||||||
if (buffs[i].spellid != SPELL_UNKNOWN) {
|
if (IsValidSpell(buffs[i].spellid)) {
|
||||||
|
|
||||||
for (int j = 0; j < EFFECT_COUNT; j++) {
|
for (int j = 0; j < EFFECT_COUNT; j++) {
|
||||||
// adjustments necessary for offensive npc casting behavior
|
// adjustments necessary for offensive npc casting behavior
|
||||||
if (bOffensive) {
|
if (bOffensive) {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user