Decouple zone calls, cleanup logic

This commit is contained in:
Akkadius
2020-04-19 04:36:39 -05:00
parent ebda1cf601
commit 373fb3f0e7
57 changed files with 705 additions and 467 deletions
+3 -2
View File
@@ -53,6 +53,7 @@
#include "worldserver.h"
#include "zone.h"
#include "zonedb.h"
#include "zone_store.h"
extern QueryServ* QServ;
extern Zone* zone;
@@ -129,7 +130,7 @@ bool Client::Process() {
CheckManaEndUpdate();
if (dead && dead_timer.Check()) {
database.MoveCharacterToZone(GetName(), content_db.GetZoneName(m_pp.binds[0].zoneId));
database.MoveCharacterToZone(GetName(), m_pp.binds[0].zoneId);
m_pp.zone_id = m_pp.binds[0].zoneId;
m_pp.zoneInstance = m_pp.binds[0].instance_id;
@@ -2087,7 +2088,7 @@ void Client::HandleRespawnFromHover(uint32 Option)
m_pp.zone_id = chosen->zone_id;
m_pp.zoneInstance = chosen->instance_id;
database.MoveCharacterToZone(CharacterID(), content_db.GetZoneName(chosen->zone_id));
database.MoveCharacterToZone(CharacterID(), chosen->zone_id);
Save();