Cleanup building initialization
This commit is contained in:
@@ -44,27 +44,6 @@ public class dbZoneHandler extends dbHandlerBase {
|
||||
return zoneList;
|
||||
}
|
||||
|
||||
public ArrayList<Zone> GET_ALL_NODES(Zone zone) {
|
||||
ArrayList<Zone> wsmList = new ArrayList<>();
|
||||
wsmList.addAll(zone.nodes);
|
||||
if (zone.absX == 0.0f) {
|
||||
zone.absX = zone.xOffset;
|
||||
}
|
||||
if (zone.absY == 0.0f) {
|
||||
zone.absY = zone.yOffset;
|
||||
}
|
||||
if (zone.absZ == 0.0f) {
|
||||
zone.absZ = zone.zOffset;
|
||||
}
|
||||
for (Zone child : zone.nodes) {
|
||||
child.absX = child.xOffset + zone.absX;
|
||||
child.absY = child.yOffset + zone.absY;
|
||||
child.absZ = child.zOffset + zone.absZ;
|
||||
wsmList.addAll(this.GET_ALL_NODES(child));
|
||||
}
|
||||
return wsmList;
|
||||
}
|
||||
|
||||
public Zone GET_BY_UID(long ID) {
|
||||
|
||||
Zone zone = (Zone) DbManager.getFromCache(Enum.GameObjectType.Zone, (int) ID);
|
||||
@@ -87,25 +66,6 @@ public class dbZoneHandler extends dbHandlerBase {
|
||||
return zone;
|
||||
}
|
||||
|
||||
public ArrayList<Zone> GET_MAP_NODES(final int objectUUID) {
|
||||
|
||||
ArrayList<Zone> zoneList = new ArrayList<>();
|
||||
|
||||
try (Connection connection = DbManager.getConnection();
|
||||
PreparedStatement preparedStatement = connection.prepareStatement("SELECT `obj_zone`.*, `object`.`parent` FROM `object` INNER JOIN `obj_zone` ON `obj_zone`.`UID` = `object`.`UID` WHERE `object`.`parent` = ?;")) {
|
||||
|
||||
preparedStatement.setLong(1, objectUUID);
|
||||
|
||||
ResultSet rs = preparedStatement.executeQuery();
|
||||
zoneList = getObjectsFromRs(rs, 2000);
|
||||
|
||||
} catch (SQLException e) {
|
||||
Logger.error(e);
|
||||
}
|
||||
|
||||
return zoneList;
|
||||
}
|
||||
|
||||
public boolean DELETE_ZONE(final Zone zone) {
|
||||
|
||||
try (Connection connection = DbManager.getConnection();
|
||||
|
||||
Reference in New Issue
Block a user