forked from MagicBane/Server
class and table schema now conform to JSON
This commit is contained in:
@@ -137,7 +137,7 @@ public class PlaceAssetMsgHandler extends AbstractClientMsgHandler {
|
||||
|
||||
private static boolean validateBuildingPlacement(Zone serverZone, PlaceAssetMsg msg, ClientConnection origin, PlayerCharacter player, PlacementInfo placementInfo) {
|
||||
|
||||
if (serverZone.isGuildZone == false) {
|
||||
if (serverZone.guild_zone == false) {
|
||||
PlaceAssetMsg.sendPlaceAssetError(origin, 52, player.getName());
|
||||
return false;
|
||||
}
|
||||
@@ -201,7 +201,7 @@ public class PlaceAssetMsgHandler extends AbstractClientMsgHandler {
|
||||
|
||||
// Cannot place assets on a dead tree
|
||||
|
||||
if ((serverZone.isGuildZone)
|
||||
if ((serverZone.guild_zone)
|
||||
&& (City.getCity(serverZone.playerCityUUID).getTOL().getRank() == -1)) {
|
||||
PlaceAssetMsg.sendPlaceAssetError(origin, 1, "Cannot place asset on dead tree until world heals");
|
||||
return false;
|
||||
@@ -261,7 +261,7 @@ public class PlaceAssetMsgHandler extends AbstractClientMsgHandler {
|
||||
|
||||
// Must be a player city
|
||||
|
||||
if (serverZone.isGuildZone == false) {
|
||||
if (serverZone.guild_zone == false) {
|
||||
PlaceAssetMsg.sendPlaceAssetError(origin, 41, player.getName()); // Cannot place outside a guild zone
|
||||
return false;
|
||||
}
|
||||
@@ -571,7 +571,7 @@ public class PlaceAssetMsgHandler extends AbstractClientMsgHandler {
|
||||
|
||||
// No valid player city found
|
||||
|
||||
if (serverCity == null || serverCity.getParent().isGuildZone == false) {
|
||||
if (serverCity == null || serverCity.getParent().guild_zone == false) {
|
||||
PlaceAssetMsg.sendPlaceAssetError(origin, 52, ""); // Cannot place outisde a guild zone
|
||||
return false;
|
||||
}
|
||||
@@ -783,7 +783,7 @@ public class PlaceAssetMsgHandler extends AbstractClientMsgHandler {
|
||||
// Link the zone with the city and then add
|
||||
// to the appropriate hash tables and cache
|
||||
|
||||
zoneObject.isGuildZone = true;
|
||||
zoneObject.guild_zone = true;
|
||||
|
||||
if (zoneObject.parent != null)
|
||||
zoneObject.parent.addNode(zoneObject); //add as child to parent
|
||||
|
||||
Reference in New Issue
Block a user