mirror of
https://github.com/SparklyPower/SparklyPaper.git
synced 2026-01-04 15:41:34 +00:00
Fix build conflicts
This commit is contained in:
@@ -5,10 +5,10 @@ Subject: [PATCH] Add PlayerPreMoveEvent
|
||||
|
||||
|
||||
diff --git a/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||
index da190c2ab2080344dc11903aec51598af18d7556..f637d2be3d67a928ed7f78eaa7aa80cbea85a3e6 100644
|
||||
index ddcd612d10be42b4e85b2d0d60b83f15177fcac0..ba19ce959a81eac0c16643fb346d8d3614188fee 100644
|
||||
--- a/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||
+++ b/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||
@@ -1422,7 +1422,7 @@ public class ServerGamePacketListenerImpl
|
||||
@@ -1429,7 +1429,7 @@ public class ServerGamePacketListenerImpl
|
||||
d3 = d - this.lastGoodX; // Paper - diff on change, used for checking large move vectors above
|
||||
d4 = d1 - this.lastGoodY; // Paper - diff on change, used for checking large move vectors above
|
||||
d5 = d2 - this.lastGoodZ; // Paper - diff on change, used for checking large move vectors above
|
||||
@@ -17,7 +17,7 @@ index da190c2ab2080344dc11903aec51598af18d7556..f637d2be3d67a928ed7f78eaa7aa80cb
|
||||
if (this.player.onGround() && !packet.isOnGround() && flag) {
|
||||
// Paper start - Add PlayerJumpEvent
|
||||
org.bukkit.entity.Player player = this.getCraftPlayer();
|
||||
@@ -1456,7 +1456,37 @@ public class ServerGamePacketListenerImpl
|
||||
@@ -1463,7 +1463,37 @@ public class ServerGamePacketListenerImpl
|
||||
|
||||
boolean flag1 = this.player.verticalCollisionBelow;
|
||||
this.player.move(MoverType.PLAYER, new Vec3(d3, d4, d5));
|
||||
@@ -56,7 +56,7 @@ index da190c2ab2080344dc11903aec51598af18d7556..f637d2be3d67a928ed7f78eaa7aa80cb
|
||||
boolean didCollide = toX != this.player.getX() || toY != this.player.getY() || toZ != this.player.getZ(); // Paper - needed here as the difference in Y can be reset - also note: this is only a guess at whether collisions took place, floating point errors can make this true when it shouldn't be...
|
||||
// Paper start - prevent position desync
|
||||
if (this.awaitingPositionFromClient != null) {
|
||||
@@ -1590,15 +1620,15 @@ public class ServerGamePacketListenerImpl
|
||||
@@ -1597,15 +1627,15 @@ public class ServerGamePacketListenerImpl
|
||||
&& this.noBlocksAround(this.player);
|
||||
this.player.serverLevel().getChunkSource().move(this.player);
|
||||
Vec3 vec3 = new Vec3(this.player.getX() - x, this.player.getY() - y, this.player.getZ() - z);
|
||||
@@ -64,7 +64,7 @@ index da190c2ab2080344dc11903aec51598af18d7556..f637d2be3d67a928ed7f78eaa7aa80cb
|
||||
- this.player.doCheckFallDamage(vec3.x, vec3.y, vec3.z, packet.isOnGround());
|
||||
+ this.player.setOnGroundWithMovement(isOnGround, horizontalCollision, vec3); // SparklyPaper - Add PlayerPreMoveEvent
|
||||
+ this.player.doCheckFallDamage(vec3.x, vec3.y, vec3.z, isOnGround); // SparklyPaper - Add PlayerPreMoveEvent
|
||||
this.player.recordMovementThroughBlocks(new Vec3(x, y, z), this.player.position());
|
||||
if (!this.player.isSpectator() && this.player.isAffectedByBlocks()) this.player.recordMovementThroughBlocks(new Vec3(x, y, z), this.player.position());
|
||||
this.handlePlayerKnownMovement(vec3);
|
||||
if (flag) {
|
||||
this.player.resetFallDistance();
|
||||
@@ -75,7 +75,7 @@ index da190c2ab2080344dc11903aec51598af18d7556..f637d2be3d67a928ed7f78eaa7aa80cb
|
||||
|| this.player.hasLandedInLiquid()
|
||||
|| this.player.onClimbable()
|
||||
|| this.player.isSpectator()
|
||||
@@ -1613,7 +1643,7 @@ public class ServerGamePacketListenerImpl
|
||||
@@ -1620,7 +1650,7 @@ public class ServerGamePacketListenerImpl
|
||||
this.lastGoodZ = this.player.getZ();
|
||||
} else {
|
||||
this.internalTeleport(x, y, z, f, f1); // CraftBukkit - SPIGOT-1807: Don't call teleport event, when the client thinks the player is falling, because the chunks are not loaded on the client yet.
|
||||
|
||||
Reference in New Issue
Block a user