Revert entity looking changes for now

This commit is contained in:
fullwall 2020-04-26 21:28:51 +08:00
parent d5667e53f5
commit a269bf1ccc
8 changed files with 17 additions and 17 deletions

View File

@ -42,7 +42,7 @@ public class PlayerControllerLook {
this.a.aQ += 360F;
}
} else {
this.a.yaw = b(this.a.yaw, this.a.aK, -40F);
// this.a.yaw = b(this.a.yaw, this.a.aK, -40F);
// this.a.aQ = a(this.a.aQ, this.a.aO, 10.0F);
}
float f3 = MathHelper.g(this.a.aQ - this.a.aO);

View File

@ -42,7 +42,7 @@ public class PlayerControllerLook {
this.a.aP += 360F;
}
} else {
this.a.yaw = this.b(this.a.yaw, this.a.aP, -40F);
// this.a.yaw = this.b(this.a.yaw, this.a.aP, -40F);
// this.a.aP = a(this.a.aP, this.a.aN, 10.0F);
}
float f3 = MathHelper.g(this.a.aP - this.a.aN);

View File

@ -42,7 +42,7 @@ public class PlayerControllerLook {
this.a.aP += 360F;
}
} else {
this.a.yaw = this.b(this.a.yaw, this.a.aP, -40F);
// this.a.yaw = this.b(this.a.yaw, this.a.aP, -40F);
// this.a.aP = a(this.a.aP, this.a.aN, 10.0F);
}
float f3 = MathHelper.g(this.a.aP - this.a.aN);

View File

@ -43,7 +43,7 @@ public class PlayerControllerLook {
this.a.aS += 360F;
}
} else {
this.a.yaw = b(this.a.yaw, this.a.aS, -40F);
// this.a.yaw = b(this.a.yaw, this.a.aS, -40F);
// this.a.aP = a(this.a.aS, this.a.aQ, 10.0F);
}
float f3 = MathHelper.g(this.a.aS - this.a.aQ);

View File

@ -31,7 +31,7 @@ public class PlayerControllerLook {
this.a.yaw = this.a.aM;
this.a.pitch = this.a(this.a.pitch, this.g(), this.c);
} else {
this.a.yaw = MathHelper.b(this.a.yaw, this.a.aM, -40F);
// this.a.yaw = MathHelper.b(this.a.yaw, this.a.aM, -40F);
// this.a.aM = this.a(this.a.aM, this.a.aK, 10.0F);
}

View File

@ -31,7 +31,7 @@ public class PlayerControllerLook {
this.a.yaw = this.a.aK;
this.a.pitch = this.a(this.a.pitch, this.g(), this.c);
} else {
this.a.yaw = MathHelper.b(this.a.yaw, this.a.aK, -40F);
// this.a.yaw = MathHelper.b(this.a.yaw, this.a.aK, 40F);
// this.a.aK = this.a(this.a.aK, this.a.aI, 10.0F);
}

View File

@ -111,15 +111,6 @@ public class PlayerlistTracker extends PlayerChunkMap.EntityTracker {
return false;
}
private static int getTrackingDistance(EntityTracker entry) {
try {
return (Integer) TRACKING_DISTANCE.invoke(entry);
} catch (Throwable e) {
e.printStackTrace();
}
return 0;
}
private static Entity getTracker(EntityTracker entry) {
try {
return (Entity) TRACKER.invoke(entry);
@ -138,14 +129,23 @@ public class PlayerlistTracker extends PlayerChunkMap.EntityTracker {
return null;
}
private static int getTrackingDistance(EntityTracker entry) {
try {
return (Integer) TRACKING_DISTANCE.invoke(entry);
} catch (Throwable e) {
e.printStackTrace();
}
return 0;
}
private static final MethodHandle B = NMS.getMethodHandle(PlayerChunkMap.class, "b", true, ChunkCoordIntPair.class,
EntityPlayer.class, boolean.class);
private static final MethodHandle D = NMS.getGetter(EntityTrackerEntry.class, "d");
private static final MethodHandle E = NMS.getGetter(EntityTrackerEntry.class, "e");
private static final MethodHandle GET_VISIBLE_CHUNK = NMS.getMethodHandle(PlayerChunkMap.class, "getVisibleChunk",
true, long.class);
private static final MethodHandle TRACKING_DISTANCE = NMS.getGetter(EntityTracker.class, "trackingDistance");
private static final MethodHandle TRACKER = NMS.getGetter(EntityTracker.class, "tracker");
private static final MethodHandle TRACKER_ENTRY = NMS.getGetter(EntityTracker.class, "trackerEntry");
private static final MethodHandle TRACKING_DISTANCE = NMS.getGetter(EntityTracker.class, "trackingDistance");
private static final MethodHandle VIEW_DISTANCE = NMS.getGetter(PlayerChunkMap.class, "viewDistance");
}

View File

@ -43,7 +43,7 @@ public class PlayerControllerLook {
this.a.aK += 360F;
}
} else {
this.a.yaw = b(this.a.yaw, this.a.aK, -40F);
// this.a.yaw = b(this.a.yaw, this.a.aK, -40F);
// this.a.aK = a(this.a.aK, this.a.aI, 10.0F);
}
float f3 = MathHelper.g(this.a.aK - this.a.aI);