From d62a449f9cf44505a149a6dff2c096ba816e789a Mon Sep 17 00:00:00 2001 From: Uleat Date: Wed, 15 Feb 2017 07:03:43 -0500 Subject: [PATCH] Missed an npc spells type (or two..) --- zone/mob_ai.cpp | 4 ++-- zone/npc.h | 2 +- zone/zonedb.h | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/zone/mob_ai.cpp b/zone/mob_ai.cpp index 5034925d9..896709fc8 100644 --- a/zone/mob_ai.cpp +++ b/zone/mob_ai.cpp @@ -2496,7 +2496,7 @@ bool IsSpellInList(DBnpcspells_Struct* spell_list, int16 iSpellID) { } // adds a spell to the list, taking into account priority and resorting list as needed. -void NPC::AddSpellToNPCList(int16 iPriority, int16 iSpellID, uint16 iType, +void NPC::AddSpellToNPCList(int16 iPriority, int16 iSpellID, uint32 iType, int16 iManaCost, int32 iRecastDelay, int16 iResistAdjust) { @@ -2646,7 +2646,7 @@ DBnpcspells_Struct* ZoneDatabase::GetNPCSpells(uint32 iDBSpellsID) { { int spell_id = atoi(row[0]); npc_spells_cache[iDBSpellsID]->entries[entryIndex].spellid = spell_id; - npc_spells_cache[iDBSpellsID]->entries[entryIndex].type = atoi(row[1]); + npc_spells_cache[iDBSpellsID]->entries[entryIndex].type = atoul(row[1]); npc_spells_cache[iDBSpellsID]->entries[entryIndex].minlevel = atoi(row[2]); npc_spells_cache[iDBSpellsID]->entries[entryIndex].maxlevel = atoi(row[3]); npc_spells_cache[iDBSpellsID]->entries[entryIndex].manacost = atoi(row[4]); diff --git a/zone/npc.h b/zone/npc.h index 2db110d98..5dcc7eac9 100644 --- a/zone/npc.h +++ b/zone/npc.h @@ -377,7 +377,7 @@ public: void NPCSlotTexture(uint8 slot, uint16 texture); // Sets new material values for slots uint32 GetAdventureTemplate() const { return adventure_template_id; } - void AddSpellToNPCList(int16 iPriority, int16 iSpellID, uint16 iType, int16 iManaCost, int32 iRecastDelay, int16 iResistAdjust); + void AddSpellToNPCList(int16 iPriority, int16 iSpellID, uint32 iType, int16 iManaCost, int32 iRecastDelay, int16 iResistAdjust); void AddSpellEffectToNPCList(uint16 iSpellEffectID, int32 base, int32 limit, int32 max); void RemoveSpellFromNPCList(int16 spell_id); Timer *GetRefaceTimer() const { return reface_timer; } diff --git a/zone/zonedb.h b/zone/zonedb.h index 1c96ee298..46ce825e4 100644 --- a/zone/zonedb.h +++ b/zone/zonedb.h @@ -45,7 +45,7 @@ struct wplist { #pragma pack(1) struct DBnpcspells_entries_Struct { int16 spellid; - uint16 type; + uint32 type; uint8 minlevel; uint8 maxlevel; int16 manacost;