This commit is contained in:
Vasco Lavos committed 2015-10-01 23:20:58 +01:00
1 parent 32a98341e5
commit 9cf015ee97
85 files changed
+369 -447

No files matched your search

@@ -31,7 +31,7 @@ public class Multiblock {
public List<ItemStack> materials = new ArrayList();
public int minX, minY, minZ, maxX, maxY, maxZ, offX, offY, offZ;
public HashMap<List<Integer>, MultiblockComponent> locationCache = new HashMap<List<Integer>, MultiblockComponent>();
/**
@@ -157,7 +157,7 @@ public class Multiblock {
public int getZSize() {
return Math.abs(minZ) + Math.abs(maxZ) + 1;
}
/**
* Rebuilds the location cache
*/
@@ -166,17 +166,17 @@ public class Multiblock {
for(MultiblockComponent comp : components)
addComponentToLocationCache(comp);
}
/**
* Adds a single component to the location cache
*/
private void addComponentToLocationCache(MultiblockComponent comp) {
ChunkCoordinates pos = comp.getRelativePosition();
locationCache.put(Arrays.asList(
pos.posX,
pos.posY,
pos.posX,
pos.posY,
pos.posZ
), comp);
), comp);
}
/**