Fixed construction

This commit is contained in:
ceikry
2021-06-27 22:54:40 -05:00
parent 32c0016020
commit 7d295511b0
2 changed files with 4 additions and 11 deletions
@@ -68,7 +68,6 @@ public final class BuildOptionPlugin extends OptionHandler {
SystemLogger.logErr("Construction (building): " + hotspot + " : " + object + " chunkX = " + object.getLocation().getChunkX() + ", chunkY = " + object.getLocation().getChunkY());
return true;
}
System.out.println(object + " chunkX = " + object.getCenterLocation().getChunkX() + ", chunkY = " + object.getCenterLocation().getChunkY());
player.setAttribute("con:hotspot", hotspot);
BuildingUtils.openBuildInterface(player, hotspot.getHotspot());
@@ -6,6 +6,7 @@ import core.game.node.object.Scenery;
import core.game.node.object.SceneryBuilder;
import core.game.world.map.*;
import rs09.game.node.entity.skill.construction.Hotspot;
import rs09.game.system.SystemLogger;
/**
* Represents a room.
@@ -151,12 +152,12 @@ public final class Room {
spot.setCurrentY(pos[1]);
}
}
if (!house.isBuildingMode()) {
removeHotspots(housePlane, house, chunk);
}
if (rotation != Direction.NORTH && chunk.getRotation() == 0) {
chunk.rotate(rotation);
}
if (!house.isBuildingMode()) {
removeHotspots(housePlane, house, chunk);
}
}
/**
@@ -176,13 +177,6 @@ public final class Room {
chunk.remove(object);
}
} else {
// BuildHotspot hs = BuildHotspot.forId(object.protocol(), house.getStyle());
// for (Hotspot h : hotspots) {
// if (h != null && h.getHotspot() == hs && h.getHotspot().getObjectIds() == null) {
// chunk.remove(object);
// break;
// }
// }
chunk.remove(object);
}
}