Skip to content

Commit 70614df

Browse files
committed
no reset last pos on cache resync
1 parent 068d4e8 commit 70614df

1 file changed

Lines changed: 3 additions & 4 deletions

File tree

  • src/main/java/com/zenith/feature/player

src/main/java/com/zenith/feature/player/Bot.java

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1317,9 +1317,9 @@ public void handleExplosion(final ClientboundExplodePacket packet) {
13171317
}
13181318

13191319
public void syncFromCache(boolean full) {
1320-
this.x = this.lastX = CACHE.getPlayerCache().getX();
1321-
this.y = this.lastY = CACHE.getPlayerCache().getY();
1322-
this.z = this.lastZ = CACHE.getPlayerCache().getZ();
1320+
this.x = CACHE.getPlayerCache().getX();
1321+
this.y = CACHE.getPlayerCache().getY();
1322+
this.z = CACHE.getPlayerCache().getZ();
13231323
this.yaw = this.lastYaw = this.requestedYaw = CACHE.getPlayerCache().getYaw();
13241324
this.pitch = this.lastPitch = this.requestedPitch = CACHE.getPlayerCache().getPitch();
13251325
this.onGround = this.lastOnGround = true; // todo: cache
@@ -1329,7 +1329,6 @@ public void syncFromCache(boolean full) {
13291329
this.velocity.set(0, 0, 0);
13301330
this.supportingBlockPos = Optional.empty();
13311331
this.onGroundNoBlocks = false;
1332-
this.ticksSinceLastPositionPacketSent = 0;
13331332
if (full) {
13341333
this.isSneaking = this.wasSneaking = false;
13351334
this.isSprinting = this.lastSprinting = false;

0 commit comments

Comments
 (0)