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
@@ -27,6 +27,7 @@ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
#include "../common/json/json.h"
#include "../common/event_sub.h"
#include "web_interface.h"
#include "world_store.h"
extern uint32 numzones;
extern bool holdzones;
@@ -263,7 +264,7 @@ void ZSList::ListLockedZones(const char* to, WorldTCPConnection* connection) {
int x = 0;
for (auto &zone : pLockedZones) {
if (zone) {
connection->SendEmoteMessageRaw(to, 0, 0, 0, content_db.GetZoneName(zone, true));
connection->SendEmoteMessageRaw(to, 0, 0, 0, ZoneName(zone, true));
x++;
}
}
@@ -529,7 +530,7 @@ void ZSList::SOPZoneBootup(const char* adminname, uint32 ZoneServerID, const cha
ZoneServer* zs = 0;
ZoneServer* zs2 = 0;
uint32 zoneid;
if (!(zoneid = content_db.GetZoneID(zonename)))
if (!(zoneid = ZoneID(zonename)))
SendEmoteMessage(adminname, 0, 0, 0, "Error: SOP_ZoneBootup: zone '%s' not found in 'zone' table. Typo protection=ON.", zonename);
else {
if (ZoneServerID != 0)