Syntax error, better place for entity list removal

This commit is contained in:
SecretsOTheP 2013-03-23 10:13:29 -04:00
parent 18e9714273
commit a6f2c1be8a
2 changed files with 2 additions and 5 deletions

View File

@ -191,7 +191,7 @@ bool Client::Process() {
if (GetMerc())
{
GetMerc()->Save();
if(GetMerc()->GetGroup != NULL)
if(GetMerc()->GetGroup() != NULL)
GetMerc()->RemoveMercFromGroup(GetMerc(), GetMerc()->GetGroup());
GetMerc()->Depop();
}

View File

@ -4915,8 +4915,6 @@ void Merc::Death(Mob* killerMob, int32 damage, uint16 spell, SkillType attack_sk
if(entity_list.GetCorpseByID(GetID()))
entity_list.GetCorpseByID(GetID())->Depop();
entity_list.RemoveMerc(GetID());
if(Suspend())
{
}
@ -5775,13 +5773,12 @@ bool Merc::Dismiss(){
void Merc::Zone() {
Save();
entity_list.RemoveMerc(this->GetID());
Depop();
}
void Merc::Depop() {
WipeHateList();
entity_list.RemoveMerc(this->GetID());
entity_list.RemoveFromHateLists(this);
if(HasGroup())