mirror of
https://github.com/PurpurMC/Purpur.git
synced 2026-02-21 10:27:44 +01:00
Updated Upstream (Paper)
Upstream has released updates that appear to apply and compile correctly Paper Changes: PaperMC/Paper@e3aca921 Replace ConcurrentUtil's Validate with Objects PaperMC/Paper@9a626dd7 Rewrite ticket counter system PaperMC/Paper@65250cbe Drop "Optimize Collision to not load chunks" PaperMC/Paper@55d56d91 Apply "Flush regionfiles on save configuration option" PaperMC/Paper@920e8d35 Apply "Optimise collision checking in player move packet handling" PaperMC/Paper@ec492d3f Apply "Improve keepalive ping system" PaperMC/Paper@8f659478 Apply "Optimise EntityScheduler ticking" PaperMC/Paper@086b4fd4 Apply "Optional per player mob spawns" PaperMC/Paper@2f4211ed Apply "Improve cancelling PreCreatureSpawnEvent with per player mob spawns" PaperMC/Paper@b6d95574 Apply "Optimize Hoppers" PaperMC/Paper@388e6936 update generator PaperMC/Paper@a3c89a8f add javadocs for new api PaperMC/Paper@fcc763ad Call BlockRedstoneEvent for the shelf PaperMC/Paper@03eb18bb replace requireNonNull by checkArgument and deprecate MCUtil#toLocation PaperMC/Paper@6b7bf014 bump built-in datapack version PaperMC/Paper@2779a538 deprecate #lanterns material tag in favour of vanilla tag PaperMC/Paper@6f9957e8 Mannequin#createDefaultProfile -> Mannequin#defaultProfile PaperMC/Paper@24874e53 Also rename Mannequin profile getter/setters for consistency PaperMC/Paper@bc2ae107 Fix default respawn dimension being null for new worlds PaperMC/Paper@eb421583 Use 0.0.4 release of ConcurrentUtil PaperMC/Paper@bb017458 1.21.9-pre2 PaperMC/Paper@02492043 1.21.9-pre2 feature patches PaperMC/Paper@9360ba42 Identifying comments for MinecraftServer PaperMC/Paper@5d3aa537 Some diff improvements in prepare spawn task PaperMC/Paper@22ad4519 Move some stuff to ATs PaperMC/Paper@0ea15c97 Drop no longer applicable ATs PaperMC/Paper@cf78f2a2 bump api-version/datapack format and add a copper torch tag PaperMC/Paper@60cb0dfc generate ClientOption enums and mark CraftBlockData impl as null marked PaperMC/Paper@40252892 Add pre2 to api version PaperMC/Paper@f2cb073a Set build channel to alpha PaperMC/Paper@90b29c4c Port most of the anti-xray patch PaperMC/Paper@4a8e88dc Disable oldPaperCommit to fix CI build PaperMC/Paper@121ac2eb Port the last Anti-XRay hunk PaperMC/Paper@f43641f8 Use ConcurrentUtil 0.0.5 PaperMC/Paper@1f79388d fix end portal teleportation PaperMC/Paper@2efb400a [ci/skip] Adjust spawn location event docs PaperMC/Paper@cb9fc05d simplify overloads PaperMC/Paper@25ecc590 Enable Anti-Xray PaperMC/Paper@4d7185f6 Add AsyncPlayerSpawnLocationEvent#isNewPlayer (#13081) PaperMC/Paper@dc474a89 Fixup vanilla code for Anti-Xray changes PaperMC/Paper@0e23b024 Add back null check for chunkPacketBlockController
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
--- a/src/main/java/com/destroystokyo/paper/entity/ai/MobGoalHelper.java
|
||||
+++ b/src/main/java/com/destroystokyo/paper/entity/ai/MobGoalHelper.java
|
||||
@@ -144,6 +_,11 @@
|
||||
private static final Map<String, String> NESTED_CLASS_NAMES = Util.make(new HashMap<>(), map -> {
|
||||
@@ -143,6 +_,11 @@
|
||||
private static final Map<String, String> RENAMES = Util.make(new HashMap<>(), map -> {
|
||||
map.put("AbstractSkeleton$1", "AbstractSkeletonMelee");
|
||||
|
||||
+ // Purpur start - Add option to disable zombie aggressiveness towards villagers
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
|
||||
@@ -417,6 +_,20 @@
|
||||
@@ -416,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());
|
||||
|
||||
@@ -1029,6 +_,7 @@
|
||||
@@ -992,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 && world.getGameRules().getBoolean(GameRules.RULE_SPAWN_MONSTERS)); // Paper - per level difficulty (from MinecraftServer#setDifficulty(ServerLevel, Difficulty, boolean))
|
||||
@@ -1044,6 +_,7 @@
|
||||
@@ -1007,6 +_,7 @@
|
||||
}
|
||||
}
|
||||
world.spigotConfig.init(); // Spigot
|
||||
@@ -37,7 +37,7 @@
|
||||
}
|
||||
|
||||
Plugin[] pluginClone = pluginManager.getPlugins().clone(); // Paper
|
||||
@@ -1061,6 +_,7 @@
|
||||
@@ -1024,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");
|
||||
|
||||
@@ -1526,6 +_,60 @@
|
||||
@@ -1482,6 +_,60 @@
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -106,7 +106,7 @@
|
||||
@Override
|
||||
public List<Recipe> getRecipesFor(ItemStack result) {
|
||||
Preconditions.checkArgument(result != null, "ItemStack cannot be null");
|
||||
@@ -2827,6 +_,18 @@
|
||||
@@ -2725,6 +_,18 @@
|
||||
return CraftServer.this.console.paperConfigurations.createLegacyObject(CraftServer.this.console);
|
||||
}
|
||||
|
||||
@@ -125,7 +125,7 @@
|
||||
@Override
|
||||
public void restart() {
|
||||
CraftServer.this.restart();
|
||||
@@ -2859,6 +_,7 @@
|
||||
@@ -2757,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()
|
||||
@@ -3066,4 +_,18 @@
|
||||
@@ -2964,4 +_,18 @@
|
||||
public void allowPausing(final Plugin plugin, final boolean value) {
|
||||
this.console.addPluginAllowingSleep(plugin.getName(), value);
|
||||
}
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
||||
@@ -2379,6 +_,50 @@
|
||||
@@ -1954,6 +_,50 @@
|
||||
return (this.getHandle().getDragonFight() == null) ? null : new CraftDragonBattle(this.getHandle().getDragonFight());
|
||||
}
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java
|
||||
@@ -294,6 +_,7 @@
|
||||
@@ -289,6 +_,7 @@
|
||||
@Override
|
||||
public void recalculatePermissions() {
|
||||
this.perm.recalculatePermissions();
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java
|
||||
@@ -516,7 +_,7 @@
|
||||
@@ -506,7 +_,7 @@
|
||||
net.minecraft.server.level.ServerPlayer nmsKiller = killer == null ? null : ((CraftPlayer) killer).getHandle();
|
||||
this.getHandle().setLastHurtByMob(nmsKiller);
|
||||
if (nmsKiller != null) {
|
||||
|
||||
@@ -15,9 +15,9 @@
|
||||
- this.getHandle().listName = name.equals(this.getName()) ? null : CraftChatMessage.fromStringOrNull(name);
|
||||
+ this.getHandle().listName = name.equals(this.getName()) ? null : useMM ? io.papermc.paper.adventure.PaperAdventure.asVanilla(net.kyori.adventure.text.minimessage.MiniMessage.miniMessage().deserialize(name)) : CraftChatMessage.fromStringOrNull(name); // Purpur - AFK API
|
||||
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) {
|
||||
for (ServerPlayer player : this.server.getHandle().players) {
|
||||
if (player.getBukkitEntity().canSee(this)) {
|
||||
@@ -1025,6 +_,78 @@
|
||||
@@ -978,6 +_,78 @@
|
||||
}
|
||||
}
|
||||
|
||||
@@ -94,9 +94,9 @@
|
||||
+ // Purpur end - Death screen API
|
||||
+
|
||||
@Override
|
||||
public void sendBlockDamage(Location loc, float progress) {
|
||||
this.sendBlockDamage(loc, progress, this.getEntityId());
|
||||
@@ -2695,6 +_,28 @@
|
||||
public void sendBlockDamage(Location loc, float progress, org.bukkit.entity.Entity source) {
|
||||
Preconditions.checkArgument(source != null, "source must not be null");
|
||||
@@ -2590,6 +_,28 @@
|
||||
public float getWalkSpeed() {
|
||||
return this.getHandle().getAbilities().walkingSpeed * 2f;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user