mirror of
https://github.com/EQEmu/Server.git
synced 2025-12-14 11:31:30 +00:00
Moved around some data in Mercs to help prevent another crash... dunno if it actually will fix it but it can't hurt >_<
This commit is contained in:
parent
e0b05e573e
commit
23820a369e
@ -50,7 +50,6 @@ Merc::Merc(const NPCType* d, float x, float y, float z, float heading)
|
|||||||
_lost_confidence = false;
|
_lost_confidence = false;
|
||||||
_hatedCount = 0;
|
_hatedCount = 0;
|
||||||
|
|
||||||
ourNPCData = d;
|
|
||||||
memset(equipment, 0, sizeof(equipment));
|
memset(equipment, 0, sizeof(equipment));
|
||||||
|
|
||||||
SetMercID(0);
|
SetMercID(0);
|
||||||
@ -74,7 +73,6 @@ Merc::Merc(const NPCType* d, float x, float y, float z, float heading)
|
|||||||
|
|
||||||
Merc::~Merc() {
|
Merc::~Merc() {
|
||||||
AI_Stop();
|
AI_Stop();
|
||||||
safe_delete(ourNPCData); //Since mercs are dynamically alloc'd we should probably safe_delete the data they were made from. I'm not entirely sure this is safe to delete a const.
|
|
||||||
entity_list.RemoveMerc(this->GetID());
|
entity_list.RemoveMerc(this->GetID());
|
||||||
UninitializeBuffSlots();
|
UninitializeBuffSlots();
|
||||||
}
|
}
|
||||||
@ -1915,9 +1913,9 @@ void Merc::AI_Start(int32 iMoveDelay) {
|
|||||||
AIautocastspell_timer->Start(RandomTimer(0, 2000), false);
|
AIautocastspell_timer->Start(RandomTimer(0, 2000), false);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (ourNPCData) {
|
if (NPCTypedata_ours) {
|
||||||
//AI_AddNPCSpells(ourNPCData->npc_spells_id);
|
//AI_AddNPCSpells(ourNPCData->npc_spells_id);
|
||||||
NPCSpecialAttacks(ourNPCData->npc_attacks,0);
|
NPCSpecialAttacks(NPCTypedata_ours->npc_attacks,0);
|
||||||
}
|
}
|
||||||
|
|
||||||
SendTo(GetX(), GetY(), GetZ());
|
SendTo(GetX(), GetY(), GetZ());
|
||||||
|
|||||||
@ -379,8 +379,6 @@ private:
|
|||||||
bool _lost_confidence;
|
bool _lost_confidence;
|
||||||
int _hatedCount;
|
int _hatedCount;
|
||||||
uint32 owner_char_id;
|
uint32 owner_char_id;
|
||||||
const NPCType* ourNPCData;
|
|
||||||
|
|
||||||
Timer endupkeep_timer;
|
Timer endupkeep_timer;
|
||||||
Timer rest_timer;
|
Timer rest_timer;
|
||||||
Timer confidence_timer;
|
Timer confidence_timer;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user