This commit is contained in:
TomyLobo 2011-09-25 05:15:20 +02:00
parent 50009cc855
commit b06caa9fd3

View File

@ -362,9 +362,11 @@ public final class BlockData {
case NORTH_SOUTH:
flipX = 1;
break;
case WEST_EAST:
flipZ = 1;
break;
case UP_DOWN:
flipY = 1;
break;
@ -399,9 +401,11 @@ public final class BlockData {
case 0:
case 1:
return data;
case 2:
case 3:
return data ^ flipX;
case 4:
case 5:
return data ^ flipZ;
@ -416,6 +420,7 @@ public final class BlockData {
case 0:
case 1:
return data ^ flipX;
case 2:
case 3:
return data ^ flipZ;
@ -437,6 +442,7 @@ public final class BlockData {
switch (direction) {
case NORTH_SOUTH:
return (16 - data) & 0xf;
case WEST_EAST:
return (8 - data) & 0xf;
}
@ -451,6 +457,7 @@ public final class BlockData {
case 2:
case 3:
return data ^ flipZ;
case 4:
case 5:
return data ^ flipX;
@ -465,6 +472,7 @@ public final class BlockData {
case 0:
case 2:
return data ^ (flipZ << 1);
case 1:
case 3:
return data ^ (flipX << 1);
@ -476,6 +484,7 @@ public final class BlockData {
case 0:
case 1:
return data ^ flipZ;
case 2:
case 3:
return data ^ flipX;
@ -489,9 +498,11 @@ public final class BlockData {
case 0:
case 1:
return data ^ flipY;
case 2:
case 3:
return data ^ flipZ;
case 4:
case 5:
return data ^ flipX;
@ -504,23 +515,23 @@ public final class BlockData {
case 1:
case 4:
case 7:
data += 2 * flipX;
data += flipX * 2;
break;
case 3:
case 6:
case 9:
data -= 2 * flipX;
data -= flipX * 2;
break;
}
switch (data) {
case 1:
case 2:
case 3:
return data + 6 * flipZ;
return data + flipZ * 6;
case 7:
case 8:
case 9:
return data - 6 * flipZ;
return data - flipZ * 6;
}
break;
@ -531,10 +542,12 @@ public final class BlockData {
bit1 = 0x2;
bit2 = 0x8;
break;
case WEST_EAST:
bit1 = 0x1;
bit2 = 0x4;
break;
default:
return data;
}
@ -548,10 +561,11 @@ public final class BlockData {
switch (data & 0x3) {
case 0:
case 2:
return data ^ 2 * flipZ;
return data ^ flipZ * 2;
case 1:
case 3:
return data ^ 2 * flipX;
return data ^ flipX * 2;
}
break;
}