From 8fcbd8c1e04889b64e7443c5bd4792343ab56816 Mon Sep 17 00:00:00 2001 From: FatBoy-DOTC Date: Sat, 24 Feb 2024 21:01:33 -0600 Subject: [PATCH] zone override --- src/engine/db/handlers/dbCityHandler.java | 2 ++ src/engine/objects/Zone.java | 21 ++++++++++++++++++++- 2 files changed, 22 insertions(+), 1 deletion(-) diff --git a/src/engine/db/handlers/dbCityHandler.java b/src/engine/db/handlers/dbCityHandler.java index bf3d9d98..48caf5f1 100644 --- a/src/engine/db/handlers/dbCityHandler.java +++ b/src/engine/db/handlers/dbCityHandler.java @@ -32,6 +32,8 @@ public class dbCityHandler extends dbHandlerBase { String type = rs.getString("type"); switch (type) { case "zone": + if(rs.getInt("isPlayerCity") != 0 && Zone.skipZone(rs.getString("Name"))) + break; Zone zone = new Zone(rs); DbManager.addToCache(zone); list.add(zone); diff --git a/src/engine/objects/Zone.java b/src/engine/objects/Zone.java index 45314553..2e9bee7a 100644 --- a/src/engine/objects/Zone.java +++ b/src/engine/objects/Zone.java @@ -103,7 +103,26 @@ public class Zone extends AbstractGameObject { } - + public static boolean skipZone(String name){ + switch(name){ + case "Kralgar Holm": + case "Doomhorn Skrae": + case "Ymur's Crown": + case "Ecklund Wilds": + case "Ragnir Holm": + case "Aurrochs Skrae": + case "Hregerend Wildlands": + case "The Blood Sands": + case "Vale of Nar Addad": + case "Kharsoom": + case "Leth'khalivar Desert": + case "Thollok Marsh": + case "The Black Bog": + case "sevaath Mere": + return true; + } + return false; + } public static void serializeForClientMsg(Zone zone, ByteBufferWriter writer) { if (zone.loadNum == 0 && zone.playerCityID == 0)