Updated Upstream (CraftBukkit/Spigot)
Doesn't compile yet. CraftBukkit Changes: 90d6905b Repackage NMS 69cf961d Repackage patches Spigot Changes: 79d53c28 Repackage NMS
This commit is contained in:
@@ -8,10 +8,10 @@ For modifying a player's initial spawn location as they join the server
|
||||
This is a duplicate API from spigot, so use our duplicate subclass and
|
||||
improve setPosition to use raw
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/PlayerList.java b/src/main/java/net/minecraft/server/PlayerList.java
|
||||
diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java
|
||||
index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644
|
||||
--- a/src/main/java/net/minecraft/server/PlayerList.java
|
||||
+++ b/src/main/java/net/minecraft/server/PlayerList.java
|
||||
--- a/src/main/java/net/minecraft/server/players/PlayerList.java
|
||||
+++ b/src/main/java/net/minecraft/server/players/PlayerList.java
|
||||
@@ -0,0 +0,0 @@ public abstract class PlayerList {
|
||||
|
||||
// Spigot start - spawn location event
|
||||
@@ -25,8 +25,24 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
|
||||
|
||||
entityplayer.spawnIn(worldserver1);
|
||||
entityplayer.playerInteractManager.a((WorldServer) entityplayer.world);
|
||||
- entityplayer.setPosition(loc.getX(), loc.getY(), loc.getZ());
|
||||
+ entityplayer.setPositionRaw(loc.getX(), loc.getY(), loc.getZ()); // Paper - set raw so we aren't fully joined to the world (not added to chunk or world)
|
||||
entityplayer.setYawPitch(loc.getYaw(), loc.getPitch());
|
||||
- entityplayer.setLocation(loc.getX(), loc.getY(), loc.getZ(), loc.getYaw(), loc.getPitch());
|
||||
+ // Paper start - set raw so we aren't fully joined to the world (not added to chunk or world)
|
||||
+ entityplayer.setPositionRaw(loc.getX(), loc.getY(), loc.getZ());
|
||||
+ entityplayer.setYawPitch(loc.getYaw(), loc.getPitch());
|
||||
+ // Paper end
|
||||
// Spigot end
|
||||
|
||||
// CraftBukkit - Moved message to after join
|
||||
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
|
||||
index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644
|
||||
--- a/src/main/java/net/minecraft/world/entity/Entity.java
|
||||
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
|
||||
@@ -0,0 +0,0 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne
|
||||
return d1 * d1 + d2 * d2 + d3 * d3 < d0 * d0;
|
||||
}
|
||||
|
||||
- protected void setYawPitch(float f, float f1) {
|
||||
+ public void setYawPitch(float f, float f1) { // Paper - protected -> public
|
||||
// CraftBukkit start - yaw was sometimes set to NaN, so we need to set it back to 0
|
||||
if (Float.isNaN(f)) {
|
||||
f = 0;
|
||||
|
||||
Reference in New Issue
Block a user