Archiviert
13
0

staticify backported method

Dieser Commit ist enthalten in:
md_5 2016-04-12 18:25:18 +10:00
Ursprung 1e2fcb38e4
Commit f6313791d0

Datei anzeigen

@ -26,27 +26,16 @@
private PathPoint a(int i, int j, int k, int l, double d0, EnumDirection enumdirection) {
PathPoint pathpoint = null;
BlockPosition blockposition = new BlockPosition(i, j, k);
@@ -221,7 +223,7 @@
for (int k1 = i; k1 < i + l; ++k1) {
for (int l1 = j; l1 < j + i1; ++l1) {
for (int i2 = k; i2 < k + j1; ++i2) {
- PathType pathtype1 = a(iblockaccess, k1, l1, i2);
+ PathType pathtype1 = this.a(iblockaccess, k1, l1, i2);
if (pathtype1 == PathType.DOOR_WOOD_CLOSED && flag && flag1) {
pathtype1 = PathType.WALKABLE;
@@ -286,71 +288,43 @@
return this.a(this.a, i, j, k, entityinsentient, this.d, this.e, this.f, this.d(), this.c());
@@ -287,70 +289,42 @@
}
- public static PathType a(IBlockAccess iblockaccess, int i, int j, int k) {
public static PathType a(IBlockAccess iblockaccess, int i, int j, int k) {
- BlockPosition blockposition = new BlockPosition(i, j, k);
- IBlockData iblockdata = iblockaccess.getType(blockposition);
- Block block = iblockdata.getBlock();
- Material material = iblockdata.getMaterial();
- PathType pathtype = PathType.BLOCKED;
+ public PathType a(IBlockAccess iblockaccess, int i, int j, int k) {
+ PathType pathtype = this.b(iblockaccess, i, j, k);
+ PathType pathtype = b(iblockaccess, i, j, k);
- if (block != Blocks.TRAPDOOR && block != Blocks.IRON_TRAPDOOR && block != Blocks.WATERLILY) {
- if (block == Blocks.FIRE) {
@ -69,7 +58,7 @@
- return PathType.WATER;
- }
+ if (pathtype == PathType.OPEN && j >= 1) {
+ PathType pathtype1 = this.b(iblockaccess, i, j - 1, k);
+ PathType pathtype1 = b(iblockaccess, i, j - 1, k);
- if (material == Material.LAVA) {
- return PathType.LAVA;
@ -126,7 +115,7 @@
+ return pathtype;
+ }
+
+ private PathType b(IBlockAccess iblockaccess, int i, int j, int k) {
+ private static PathType b(IBlockAccess iblockaccess, int i, int j, int k) {
+ BlockPosition blockposition = new BlockPosition(i, j, k);
+ IBlockData iblockdata = iblockaccess.getType(blockposition);
+ Block block = iblockdata.getBlock();