Archiviert
13
0

Fixed (Bukkit multiworld) maps as described in BUKKIT-142.

Dieser Commit ist enthalten in:
EvilSeph 2011-12-10 12:36:19 -05:00
Ursprung 32a913a222
Commit 84a19565d4

Datei anzeigen

@ -24,7 +24,7 @@ public class ItemWorldMap extends ItemWorldMapBase {
worldmap.centerX = world.getWorldData().c(); worldmap.centerX = world.getWorldData().c();
worldmap.centerZ = world.getWorldData().e(); worldmap.centerZ = world.getWorldData().e();
worldmap.scale = 3; worldmap.scale = 3;
worldmap.map = (byte) world.worldProvider.dimension; worldmap.map = (byte) ((WorldServer) world).dimension; // CraftBukkit - fixes Bukkit multiworld maps.
worldmap.a(); worldmap.a();
world.a(s, (WorldMapBase) worldmap); world.a(s, (WorldMapBase) worldmap);
@ -72,6 +72,7 @@ public class ItemWorldMap extends ItemWorldMapBase {
byte b2 = 0; byte b2 = 0;
int[] aint = new int[256]; int[] aint = new int[256];
Chunk chunk = world.getChunkAtWorldCoords(i3, j3); Chunk chunk = world.getChunkAtWorldCoords(i3, j3);
if (chunk.isEmpty()) continue; // CraftBukkit - fixes maps erasing themselves on low chunk visibility.
int k3 = i3 & 15; int k3 = i3 & 15;
int l3 = j3 & 15; int l3 = j3 & 15;
int i4 = 0; int i4 = 0;
@ -232,7 +233,7 @@ public class ItemWorldMap extends ItemWorldMapBase {
worldmap.centerX = MathHelper.floor(entityhuman.locX); worldmap.centerX = MathHelper.floor(entityhuman.locX);
worldmap.centerZ = MathHelper.floor(entityhuman.locZ); worldmap.centerZ = MathHelper.floor(entityhuman.locZ);
worldmap.scale = 3; worldmap.scale = 3;
worldmap.map = (byte) world.worldProvider.dimension; worldmap.map = (byte) ((WorldServer) world).dimension; // CraftBukkit - fixes Bukkit multiworld maps.
worldmap.a(); worldmap.a();
} }