diff --git a/serverdata/map/static_city_points.iff b/serverdata/map/static_city_points.iff index cae348f5d..203a46d46 100644 Binary files a/serverdata/map/static_city_points.iff and b/serverdata/map/static_city_points.iff differ diff --git a/src/resources/objects/cell/CellObject.java b/src/resources/objects/cell/CellObject.java index cd01811c2..b1bfbcba7 100644 --- a/src/resources/objects/cell/CellObject.java +++ b/src/resources/objects/cell/CellObject.java @@ -40,7 +40,10 @@ public class CellObject extends SWGObject { private boolean isPublic = true; private int number = 0; private String label = ""; - + + private float label_x = 0f; + private float label_z = 0f; + public CellObject(long objectId) { super(objectId, BaselineType.SCLT); } @@ -68,7 +71,12 @@ public class CellObject extends SWGObject { public void setLabel(String label) { this.label = label; } - + + public void setLabelMapPosition(float x, float z) { + this.label_x = x; + this.label_z = z; + } + protected void sendBaselines(Player target) { BaselineBuilder bb = new BaselineBuilder(this, BaselineType.SCLT, 3); createBaseline3(target, bb); @@ -82,16 +90,17 @@ public class CellObject extends SWGObject { public void createBaseline3(Player target, BaselineBuilder bb) { super.createBaseline3(target, bb); - bb.addByte(1); // isPublic + bb.addBoolean(isPublic); bb.addInt(number); bb.incrementOperandCount(2); } public void createBaseline6(Player target, BaselineBuilder bb) { super.createBaseline6(target, bb); - bb.addLong(0); - bb.addLong(0); + bb.addUnicode(label); + bb.addFloat(label_x); + bb.addFloat((float) 0); + bb.addFloat(label_z); bb.incrementOperandCount(2); } - } diff --git a/src/utilities/namegen/SWGNameGenerator.java b/src/utilities/namegen/SWGNameGenerator.java index 2432085b5..d455f20cb 100644 --- a/src/utilities/namegen/SWGNameGenerator.java +++ b/src/utilities/namegen/SWGNameGenerator.java @@ -124,7 +124,7 @@ public class SWGNameGenerator { return ""; String name = null; - while (name == null || !nameFilter.isValid(name)) { + while (name == null || (nameFilter != null && !nameFilter.isValid(name))) { name = getNameByRule(ruleMap.get(race)); // Some reason a name can be empty, I think it has to do with the removeExcessDuplications check. if (name.isEmpty())