Updated Upstream (Paper)

Upstream has released updates that appear to apply and compile correctly

Paper Changes:
PaperMC/Paper@9e873f50 Fix inconsistencies between offline/online spawn position getter (#11960)
PaperMC/Paper@fc0c3717 Fix handling of resultant crafting container from craftItemResult (#12307)
PaperMC/Paper@a7a76c8f Add methods for Armadillo (#12031)
PaperMC/Paper@a74400d9 Update adventure to 4.21.0 (#12499)
PaperMC/Paper@1e930763 Fix ipv6 loopback addresses being able to get connection throttled (#12155)
PaperMC/Paper@646b80ca Fix unnecessary map data saves (#12296)
PaperMC/Paper@e663f999 Add combat tracker API (#11853)
PaperMC/Paper@cd4fe5b7 [ci/skip] Drop non-applicable ATs (#12498)
PaperMC/Paper@5acfdd6a Fix save/load NaN Entity Motion (#12269)
PaperMC/Paper@2754d7c3 Add Throw EntityChangeBlockEvent for BrushableBlockEntity#brush (#12133)
PaperMC/Paper@567f63ae Parity for respawn events (#11792)
This commit is contained in:
granny
2025-04-30 17:34:43 -07:00
parent 4fdf1d117c
commit 8c77678e81
16 changed files with 54 additions and 54 deletions

View File

@@ -24,12 +24,12 @@ index f48d9dbd75e62621f7e4c8cd11f9fd4084db9097..8feb78c4d7fa793f01991756b618fc49
Preconditions.checkArgument(entity != null, "Unknown entity");
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java
index 61750e2e36d7654a2284637c7b84908416705fe6..5b74ca7c52fb0437726a2a00483134884dc50b2f 100644
index 3527864c55862f9ab4ed2762c1a6606cf3240cc0..6d654afe8d9e2f90510e68904a6e90ac9269810b 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java
@@ -1167,4 +1167,16 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity {
public boolean canUseEquipmentSlot(org.bukkit.inventory.EquipmentSlot slot) {
return this.getHandle().canUseSlot(org.bukkit.craftbukkit.CraftEquipmentSlot.getNMS(slot));
@@ -1179,4 +1179,16 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity {
public CombatTracker getCombatTracker() {
return this.combatTracker;
}
+
+ // Purpur start - API for any mob to burn daylight

View File

@@ -1,6 +1,6 @@
--- a/src/main/java/org/bukkit/craftbukkit/CraftOfflinePlayer.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftOfflinePlayer.java
@@ -339,6 +_,12 @@
@@ -336,6 +_,12 @@
@Override
public Location getLocation() {
@@ -13,7 +13,7 @@
CompoundTag data = this.getData();
if (data == null) {
return null;
@@ -571,4 +_,183 @@
@@ -573,4 +_,183 @@
manager.save();
}
}

View File

@@ -1,6 +1,6 @@
--- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
@@ -424,6 +_,20 @@
@@ -425,6 +_,20 @@
this.paperPluginManager = new io.papermc.paper.plugin.manager.PaperPluginManagerImpl(this, this.commandMap, pluginManager);
this.pluginManager.paperPluginManager = this.paperPluginManager;
// Paper end
@@ -21,7 +21,7 @@
CraftRegistry.setMinecraftRegistry(console.registryAccess());
@@ -1068,6 +_,7 @@
@@ -1069,6 +_,7 @@
org.spigotmc.SpigotConfig.init((File) this.console.options.valueOf("spigot-settings")); // Spigot
this.console.paperConfigurations.reloadConfigs(this.console);
@@ -29,7 +29,7 @@
for (ServerLevel world : this.console.getAllLevels()) {
// world.serverLevelData.setDifficulty(config.difficulty); // Paper - per level difficulty
world.setSpawnSettings(world.serverLevelData.getDifficulty() != Difficulty.PEACEFUL && config.spawnMonsters); // Paper - per level difficulty (from MinecraftServer#setDifficulty(ServerLevel, Difficulty, boolean))
@@ -1083,6 +_,7 @@
@@ -1084,6 +_,7 @@
}
}
world.spigotConfig.init(); // Spigot
@@ -37,7 +37,7 @@
}
Plugin[] pluginClone = pluginManager.getPlugins().clone(); // Paper
@@ -1100,6 +_,7 @@
@@ -1101,6 +_,7 @@
org.spigotmc.SpigotConfig.registerCommands(); // Spigot
io.papermc.paper.command.PaperCommands.registerCommands(this.console); // Paper
this.spark.registerCommandBeforePlugins(this); // Paper - spark
@@ -45,7 +45,7 @@
this.overrideAllCommandBlockCommands = this.commandsConfiguration.getStringList("command-block-overrides").contains("*");
this.ignoreVanillaPermissions = this.commandsConfiguration.getBoolean("ignore-vanilla-permissions");
@@ -1599,6 +_,60 @@
@@ -1600,6 +_,60 @@
return true;
}
@@ -106,7 +106,7 @@
@Override
public List<Recipe> getRecipesFor(ItemStack result) {
Preconditions.checkArgument(result != null, "ItemStack cannot be null");
@@ -2951,6 +_,18 @@
@@ -2958,6 +_,18 @@
return CraftServer.this.console.paperConfigurations.createLegacyObject(CraftServer.this.console);
}
@@ -125,7 +125,7 @@
@Override
public void restart() {
CraftServer.this.restart();
@@ -2983,6 +_,7 @@
@@ -2990,6 +_,7 @@
@Override
public double[] getTPS() {
return new double[] {
@@ -133,7 +133,7 @@
net.minecraft.server.MinecraftServer.getServer().tps1.getAverage(),
net.minecraft.server.MinecraftServer.getServer().tps5.getAverage(),
net.minecraft.server.MinecraftServer.getServer().tps15.getAverage()
@@ -3190,4 +_,18 @@
@@ -3197,4 +_,18 @@
public void allowPausing(final Plugin plugin, final boolean value) {
this.console.addPluginAllowingSleep(plugin.getName(), value);
}

View File

@@ -1,6 +1,6 @@
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java
@@ -520,7 +_,7 @@
@@ -527,7 +_,7 @@
net.minecraft.server.level.ServerPlayer nmsKiller = killer == null ? null : ((CraftPlayer) killer).getHandle();
this.getHandle().setLastHurtByMob(nmsKiller);
if (nmsKiller != null) {

View File

@@ -17,7 +17,7 @@
if (this.getHandle().connection == null) return; // Paper - Updates are possible before the player has fully joined
for (ServerPlayer player : (List<ServerPlayer>) this.server.getHandle().players) {
if (player.getBukkitEntity().canSee(this)) {
@@ -2731,6 +_,28 @@
@@ -2732,6 +_,28 @@
return this.getHandle().getAbilities().walkingSpeed * 2f;
}
@@ -46,7 +46,7 @@
private void validateSpeed(float value) {
Preconditions.checkArgument(value <= 1f && value >= -1f, "Speed value (%s) need to be between -1f and 1f", value);
}
@@ -3593,4 +_,76 @@
@@ -3594,4 +_,76 @@
public void setSimplifyContainerDesyncCheck(final boolean simplifyContainerDesyncCheck) {
this.simplifyContainerDesyncCheck = simplifyContainerDesyncCheck;
}