From 70bec0e28e24a84ab56a970c77364b0ace2c10a3 Mon Sep 17 00:00:00 2001 From: Jason Penilla <11360596+jpenilla@users.noreply.github.com> Date: Wed, 24 Nov 2021 02:04:30 -0800 Subject: [PATCH] patches --- .../Add-Raw-Byte-ItemStack-Serialization.patch | 0 .../api/Add-tick-times-API.patch | 0 ...ents-firing-Async-errors-during-shutd.patch | 0 .../api/Expose-MinecraftServer-isRunning.patch | 0 .../Make-JavaPluginLoader-thread-safe.patch | 0 .../Add-Raw-Byte-ItemStack-Serialization.patch | 0 .../Add-tick-times-API-and-mspt-command.patch | 0 ...ad-Player-s-shouldn-t-be-able-to-move.patch | 0 ...llow-bees-to-load-chunks-for-beehives.patch | 0 ...-move-existing-players-to-world-spawn.patch | 4 ++-- .../server/Don-t-tick-dead-players.patch | 0 .../Expose-MinecraftServer-isRunning.patch | 0 ...-spawn-settings-and-per-player-option.patch | 18 ++---------------- ...e-PlayerChunkMap-adds-crashing-server.patch | 0 ...onnections-shouldn-t-hold-up-shutdown.patch | 0 ...verbose-world-setting-to-false-by-def.patch | 0 16 files changed, 4 insertions(+), 18 deletions(-) rename patches/{unapplied => }/api/Add-Raw-Byte-ItemStack-Serialization.patch (100%) rename patches/{unapplied => }/api/Add-tick-times-API.patch (100%) rename patches/{unapplied => }/api/Disable-Sync-Events-firing-Async-errors-during-shutd.patch (100%) rename patches/{unapplied => }/api/Expose-MinecraftServer-isRunning.patch (100%) rename patches/{unapplied => }/api/Make-JavaPluginLoader-thread-safe.patch (100%) rename patches/{unapplied => }/server/Add-Raw-Byte-ItemStack-Serialization.patch (100%) rename patches/{unapplied => }/server/Add-tick-times-API-and-mspt-command.patch (100%) rename patches/{unapplied => }/server/Dead-Player-s-shouldn-t-be-able-to-move.patch (100%) rename patches/{unapplied => }/server/Do-not-allow-bees-to-load-chunks-for-beehives.patch (100%) rename patches/{unapplied => }/server/Don-t-move-existing-players-to-world-spawn.patch (93%) rename patches/{unapplied => }/server/Don-t-tick-dead-players.patch (100%) rename patches/{unapplied => }/server/Expose-MinecraftServer-isRunning.patch (100%) rename patches/{unapplied => }/server/Pillager-patrol-spawn-settings-and-per-player-option.patch (87%) rename patches/{unapplied => }/server/Prevent-Double-PlayerChunkMap-adds-crashing-server.patch (100%) rename patches/{unapplied => }/server/Remote-Connections-shouldn-t-hold-up-shutdown.patch (100%) rename patches/{unapplied => }/server/Set-spigots-verbose-world-setting-to-false-by-def.patch (100%) diff --git a/patches/unapplied/api/Add-Raw-Byte-ItemStack-Serialization.patch b/patches/api/Add-Raw-Byte-ItemStack-Serialization.patch similarity index 100% rename from patches/unapplied/api/Add-Raw-Byte-ItemStack-Serialization.patch rename to patches/api/Add-Raw-Byte-ItemStack-Serialization.patch diff --git a/patches/unapplied/api/Add-tick-times-API.patch b/patches/api/Add-tick-times-API.patch similarity index 100% rename from patches/unapplied/api/Add-tick-times-API.patch rename to patches/api/Add-tick-times-API.patch diff --git a/patches/unapplied/api/Disable-Sync-Events-firing-Async-errors-during-shutd.patch b/patches/api/Disable-Sync-Events-firing-Async-errors-during-shutd.patch similarity index 100% rename from patches/unapplied/api/Disable-Sync-Events-firing-Async-errors-during-shutd.patch rename to patches/api/Disable-Sync-Events-firing-Async-errors-during-shutd.patch diff --git a/patches/unapplied/api/Expose-MinecraftServer-isRunning.patch b/patches/api/Expose-MinecraftServer-isRunning.patch similarity index 100% rename from patches/unapplied/api/Expose-MinecraftServer-isRunning.patch rename to patches/api/Expose-MinecraftServer-isRunning.patch diff --git a/patches/unapplied/api/Make-JavaPluginLoader-thread-safe.patch b/patches/api/Make-JavaPluginLoader-thread-safe.patch similarity index 100% rename from patches/unapplied/api/Make-JavaPluginLoader-thread-safe.patch rename to patches/api/Make-JavaPluginLoader-thread-safe.patch diff --git a/patches/unapplied/server/Add-Raw-Byte-ItemStack-Serialization.patch b/patches/server/Add-Raw-Byte-ItemStack-Serialization.patch similarity index 100% rename from patches/unapplied/server/Add-Raw-Byte-ItemStack-Serialization.patch rename to patches/server/Add-Raw-Byte-ItemStack-Serialization.patch diff --git a/patches/unapplied/server/Add-tick-times-API-and-mspt-command.patch b/patches/server/Add-tick-times-API-and-mspt-command.patch similarity index 100% rename from patches/unapplied/server/Add-tick-times-API-and-mspt-command.patch rename to patches/server/Add-tick-times-API-and-mspt-command.patch diff --git a/patches/unapplied/server/Dead-Player-s-shouldn-t-be-able-to-move.patch b/patches/server/Dead-Player-s-shouldn-t-be-able-to-move.patch similarity index 100% rename from patches/unapplied/server/Dead-Player-s-shouldn-t-be-able-to-move.patch rename to patches/server/Dead-Player-s-shouldn-t-be-able-to-move.patch diff --git a/patches/unapplied/server/Do-not-allow-bees-to-load-chunks-for-beehives.patch b/patches/server/Do-not-allow-bees-to-load-chunks-for-beehives.patch similarity index 100% rename from patches/unapplied/server/Do-not-allow-bees-to-load-chunks-for-beehives.patch rename to patches/server/Do-not-allow-bees-to-load-chunks-for-beehives.patch diff --git a/patches/unapplied/server/Don-t-move-existing-players-to-world-spawn.patch b/patches/server/Don-t-move-existing-players-to-world-spawn.patch similarity index 93% rename from patches/unapplied/server/Don-t-move-existing-players-to-world-spawn.patch rename to patches/server/Don-t-move-existing-players-to-world-spawn.patch index e128b64886..85edab6168 100644 --- a/patches/unapplied/server/Don-t-move-existing-players-to-world-spawn.patch +++ b/patches/server/Don-t-move-existing-players-to-world-spawn.patch @@ -14,11 +14,11 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java @@ -0,0 +0,0 @@ public class ServerPlayer extends Player { - this.stats = server.getPlayerList().getStatisticManager(this); + this.stats = server.getPlayerList().getPlayerStats(this); this.advancements = server.getPlayerList().getPlayerAdvancements(this); this.maxUpStep = 1.0F; - this.fudgeSpawnLocation(world); -+ //this.c(worldserver); // Paper - don't move to spawn on login, only first join ++ //this.fudgeSpawnLocation(world); // Paper - don't move to spawn on login, only first join this.cachedSingleHashSet = new com.destroystokyo.paper.util.misc.PooledLinkedHashSets.PooledObjectLinkedOpenHashSet<>(this); // Paper diff --git a/patches/unapplied/server/Don-t-tick-dead-players.patch b/patches/server/Don-t-tick-dead-players.patch similarity index 100% rename from patches/unapplied/server/Don-t-tick-dead-players.patch rename to patches/server/Don-t-tick-dead-players.patch diff --git a/patches/unapplied/server/Expose-MinecraftServer-isRunning.patch b/patches/server/Expose-MinecraftServer-isRunning.patch similarity index 100% rename from patches/unapplied/server/Expose-MinecraftServer-isRunning.patch rename to patches/server/Expose-MinecraftServer-isRunning.patch diff --git a/patches/unapplied/server/Pillager-patrol-spawn-settings-and-per-player-option.patch b/patches/server/Pillager-patrol-spawn-settings-and-per-player-option.patch similarity index 87% rename from patches/unapplied/server/Pillager-patrol-spawn-settings-and-per-player-option.patch rename to patches/server/Pillager-patrol-spawn-settings-and-per-player-option.patch index 40c2386349..5094e0d197 100644 --- a/patches/unapplied/server/Pillager-patrol-spawn-settings-and-per-player-option.patch +++ b/patches/server/Pillager-patrol-spawn-settings-and-per-player-option.patch @@ -51,20 +51,6 @@ diff --git a/src/main/java/net/minecraft/world/level/levelgen/PatrolSpawner.java index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 --- a/src/main/java/net/minecraft/world/level/levelgen/PatrolSpawner.java +++ b/src/main/java/net/minecraft/world/level/levelgen/PatrolSpawner.java -@@ -0,0 +0,0 @@ import java.util.Random; - import net.minecraft.core.BlockPos; - import net.minecraft.nbt.CompoundTag; - import net.minecraft.server.level.ServerLevel; -+import net.minecraft.server.level.ServerPlayer; -+import net.minecraft.stats.Stats; - import net.minecraft.world.entity.EntityType; - import net.minecraft.world.entity.MobSpawnType; - import net.minecraft.world.entity.SpawnGroupData; - import net.minecraft.world.entity.monster.PatrollingMonster; --import net.minecraft.world.entity.player.Player; - import net.minecraft.world.level.BlockGetter; - import net.minecraft.world.level.CustomSpawner; - import net.minecraft.world.level.GameRules; @@ -0,0 +0,0 @@ public class PatrolSpawner implements CustomSpawner { @Override @@ -87,7 +73,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 return 0; + } + -+ ServerPlayer entityhuman = world.players().get(random.nextInt(j)); ++ net.minecraft.server.level.ServerPlayer entityhuman = world.players().get(random.nextInt(j)); + if (entityhuman.isSpectator()) { + return 0; + } @@ -108,7 +94,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 + } else { + long days; + if (world.paperConfig.patrolPerPlayerStart) { -+ days = entityhuman.getStats().getValue(Stats.CUSTOM.get(Stats.PLAY_TIME)) / 24000L; // PLAY_ONE_MINUTE is actually counting in ticks, a misnomer by Mojang ++ days = entityhuman.getStats().getValue(net.minecraft.stats.Stats.CUSTOM.get(net.minecraft.stats.Stats.PLAY_TIME)) / 24000L; // PLAY_ONE_MINUTE is actually counting in ticks, a misnomer by Mojang + } else { + days = world.getDayTime() / 24000L; + } diff --git a/patches/unapplied/server/Prevent-Double-PlayerChunkMap-adds-crashing-server.patch b/patches/server/Prevent-Double-PlayerChunkMap-adds-crashing-server.patch similarity index 100% rename from patches/unapplied/server/Prevent-Double-PlayerChunkMap-adds-crashing-server.patch rename to patches/server/Prevent-Double-PlayerChunkMap-adds-crashing-server.patch diff --git a/patches/unapplied/server/Remote-Connections-shouldn-t-hold-up-shutdown.patch b/patches/server/Remote-Connections-shouldn-t-hold-up-shutdown.patch similarity index 100% rename from patches/unapplied/server/Remote-Connections-shouldn-t-hold-up-shutdown.patch rename to patches/server/Remote-Connections-shouldn-t-hold-up-shutdown.patch diff --git a/patches/unapplied/server/Set-spigots-verbose-world-setting-to-false-by-def.patch b/patches/server/Set-spigots-verbose-world-setting-to-false-by-def.patch similarity index 100% rename from patches/unapplied/server/Set-spigots-verbose-world-setting-to-false-by-def.patch rename to patches/server/Set-spigots-verbose-world-setting-to-false-by-def.patch