13
0
geforkt von Mirrors/Paper

Updated Upstream (CraftBukkit)

Upstream has released updates that appear to apply and compile correctly.
This update has not been tested by PaperMC and as with ANY update, please do your own testing

CraftBukkit Changes:
ef0946409 PR-1091: Fix exit position in entity travel with portals
d12768f75 PR-1090: Remove no longer needed world reference from CraftMerchantCustom
7550f6854 SPIGOT-7115: Support hex color codes in custom merchant inventory titles
Dieser Commit ist enthalten in:
Nassim Jahnke 2022-07-25 18:44:24 +02:00
Ursprung af3f0a17cf
Commit 5946313531
3 geänderte Dateien mit 6 neuen und 6 gelöschten Zeilen

Datei anzeigen

@ -12,14 +12,14 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
double d0 = DimensionType.getTeleportationScale(this.level.dimensionType(), destination.dimensionType()); double d0 = DimensionType.getTeleportationScale(this.level.dimensionType(), destination.dimensionType());
BlockPos blockposition = worldborder.clampToBounds(this.getX() * d0, this.getY(), this.getZ() * d0); BlockPos blockposition = worldborder.clampToBounds(this.getX() * d0, this.getY(), this.getZ() * d0);
// CraftBukkit start // CraftBukkit start
- CraftPortalEvent event = this.callPortalEvent(this, destination, blockposition, PlayerTeleportEvent.TeleportCause.NETHER_PORTAL, flag2 ? 16 : 128, 16); - CraftPortalEvent event = this.callPortalEvent(this, destination, new PositionImpl(blockposition.getX(), blockposition.getY(), blockposition.getZ()), PlayerTeleportEvent.TeleportCause.NETHER_PORTAL, flag2 ? 16 : 128, 16);
+ // Paper start + // Paper start
+ int portalSearchRadius = destination.paperConfig().environment.portalSearchRadius; + int portalSearchRadius = destination.paperConfig().environment.portalSearchRadius;
+ if (level.paperConfig().environment.portalSearchVanillaDimensionScaling && flag2) { // == THE_NETHER + if (level.paperConfig().environment.portalSearchVanillaDimensionScaling && flag2) { // == THE_NETHER
+ portalSearchRadius = (int) (portalSearchRadius / destination.dimensionType().coordinateScale()); + portalSearchRadius = (int) (portalSearchRadius / destination.dimensionType().coordinateScale());
+ } + }
+ // Paper end + // Paper end
+ CraftPortalEvent event = this.callPortalEvent(this, destination, blockposition, PlayerTeleportEvent.TeleportCause.NETHER_PORTAL, portalSearchRadius, destination.paperConfig().environment.portalCreateRadius); // Paper start - configurable portal radius + CraftPortalEvent event = this.callPortalEvent(this, destination, new PositionImpl(blockposition.getX(), blockposition.getY(), blockposition.getZ()), PlayerTeleportEvent.TeleportCause.NETHER_PORTAL, portalSearchRadius, destination.paperConfig().environment.portalCreateRadius); // Paper start - configurable portal radius
if (event == null) { if (event == null) {
return null; return null;
} }

Datei anzeigen

@ -3118,7 +3118,7 @@ diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftMerchantCustom.
index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644 index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644
--- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftMerchantCustom.java --- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftMerchantCustom.java
+++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftMerchantCustom.java +++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftMerchantCustom.java
@@ -0,0 +0,0 @@ import org.apache.commons.lang.Validate; @@ -0,0 +0,0 @@ import org.bukkit.craftbukkit.util.CraftChatMessage;
public class CraftMerchantCustom extends CraftMerchant { public class CraftMerchantCustom extends CraftMerchant {
@ -3137,13 +3137,13 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
@Override @Override
public String toString() { public String toString() {
@@ -0,0 +0,0 @@ public class CraftMerchantCustom extends CraftMerchant { @@ -0,0 +0,0 @@ public class CraftMerchantCustom extends CraftMerchant {
private Level tradingWorld; private Player tradingPlayer;
protected CraftMerchant craftMerchant; protected CraftMerchant craftMerchant;
+ @Deprecated // Paper - Adventure + @Deprecated // Paper - Adventure
public MinecraftMerchant(String title) { public MinecraftMerchant(String title) {
Validate.notNull(title, "Title cannot be null"); Validate.notNull(title, "Title cannot be null");
this.title = Component.literal(title); this.title = CraftChatMessage.fromString(title)[0];
} }
+ // Paper start + // Paper start
+ public MinecraftMerchant(net.kyori.adventure.text.Component title) { + public MinecraftMerchant(net.kyori.adventure.text.Component title) {

@ -1 +1 @@
Subproject commit fc3071161ce4ceacceafcf77c03e5fe8464c6675 Subproject commit ef094640942637ee78314416474425a1a53b2a64