Updated Upstream (Paper)

Upstream has released updates that appear to apply and compile correctly

Paper Changes:
b79bc31 Fix MerchantOffer BuyB Only AssertionError (#6206)
d6c81c8 Don't apply cramming damage to players (#5903)
12942dc Add rate options and timings for sensors and behaviors (#6027)
fc47872 Use mapped names for sensor and behavior timings/config (#6228)
c75a837 Don't expose ASM in API (#6229)
c225bf9 Fix book title and author being improperly serialized as components (#6190)
f25facb Update email & name (DenWav)
44516b1 [ci skip] Put mappings util in a separate class to the stacktrace deobfuscator
This commit is contained in:
William Blake Galbreath
2021-07-21 10:49:16 -05:00
parent e60af1d45d
commit 31306b4b0e
192 changed files with 469 additions and 508 deletions

View File

@@ -1,39 +0,0 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Encode42 <me@encode42.dev>
Date: Mon, 8 Mar 2021 16:46:54 -0500
Subject: [PATCH] Config to ignore nearby mobs when sleeping
diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java
index 4951eefa3e8fe40751ca2d2c3871da1d17bf53dc..3774d2f5bf18cb448e81a1776207edf9064465f6 100644
--- a/src/main/java/net/minecraft/server/level/ServerPlayer.java
+++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java
@@ -1304,7 +1304,7 @@ public class ServerPlayer extends Player {
return entitymonster.isPreventingPlayerRest((Player) this);
});
- if (!list.isEmpty()) {
+ if (!this.level.purpurConfig.playerSleepNearMonsters && !list.isEmpty()) { // Purpur
return Either.left(Player.BedSleepingProblem.NOT_SAFE);
}
}
diff --git a/src/main/java/net/pl3x/purpur/PurpurWorldConfig.java b/src/main/java/net/pl3x/purpur/PurpurWorldConfig.java
index c76285978d8d485652541985b190444d4e6e08c2..281bd07cfc1c78e5831cab4147a941b65313ed26 100644
--- a/src/main/java/net/pl3x/purpur/PurpurWorldConfig.java
+++ b/src/main/java/net/pl3x/purpur/PurpurWorldConfig.java
@@ -310,6 +310,7 @@ public class PurpurWorldConfig {
public boolean totemOfUndyingWorksInInventory = false;
public boolean playerFixStuckPortal = false;
public boolean creativeOnePunch = false;
+ public boolean playerSleepNearMonsters = false;
private void playerSettings() {
idleTimeoutKick = getBoolean("gameplay-mechanics.player.idle-timeout.kick-if-idle", idleTimeoutKick);
idleTimeoutTickNearbyEntities = getBoolean("gameplay-mechanics.player.idle-timeout.tick-nearby-entities", idleTimeoutTickNearbyEntities);
@@ -324,6 +325,7 @@ public class PurpurWorldConfig {
totemOfUndyingWorksInInventory = getBoolean("gameplay-mechanics.player.totem-of-undying-works-in-inventory", totemOfUndyingWorksInInventory);
playerFixStuckPortal = getBoolean("gameplay-mechanics.player.fix-stuck-in-portal", playerFixStuckPortal);
creativeOnePunch = getBoolean("gameplay-mechanics.player.one-punch-in-creative", creativeOnePunch);
+ playerSleepNearMonsters = getBoolean("gameplay-mechanics.player.sleep-ignore-nearby-mobs", playerSleepNearMonsters);
}
public int snowballDamage = -1;