the rest of the patches

This commit is contained in:
granny
2023-09-23 04:50:44 -07:00
parent 87e5f450c3
commit e74f718fdf
106 changed files with 958 additions and 1027 deletions

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Customizeable Zombie Villager curing times
diff --git a/src/main/java/net/minecraft/world/entity/monster/ZombieVillager.java b/src/main/java/net/minecraft/world/entity/monster/ZombieVillager.java diff --git a/src/main/java/net/minecraft/world/entity/monster/ZombieVillager.java b/src/main/java/net/minecraft/world/entity/monster/ZombieVillager.java
index c3f220a85b91a25662c943b5ee4508cd7a18c75d..40b3498c57c62f8bdaac50546ca47f4927db7bfa 100644 index 5933bff2db353644705f5e1cfec3b0f2dedbad87..ecf41531855e1f60d9739ac6d2d82df7794f072f 100644
--- a/src/main/java/net/minecraft/world/entity/monster/ZombieVillager.java --- a/src/main/java/net/minecraft/world/entity/monster/ZombieVillager.java
+++ b/src/main/java/net/minecraft/world/entity/monster/ZombieVillager.java +++ b/src/main/java/net/minecraft/world/entity/monster/ZombieVillager.java
@@ -218,7 +218,7 @@ public class ZombieVillager extends Zombie implements VillagerDataHolder { @@ -221,7 +221,7 @@ public class ZombieVillager extends Zombie implements VillagerDataHolder {
} }
if (!this.level().isClientSide) { if (!this.level().isClientSide) {
@@ -18,10 +18,10 @@ index c3f220a85b91a25662c943b5ee4508cd7a18c75d..40b3498c57c62f8bdaac50546ca47f49
return InteractionResult.SUCCESS; return InteractionResult.SUCCESS;
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index d13188a1207352a6ee5ff9c9ed633e7f834a81c9..b3a794d7181aecb8f734b98182f619ee82bb3dbf 100644 index 8cece9543a87ac86a8320fef4a23b39dbc76ab5c..b2f365ab51b56a83ed7ea67c921c163c3511b834 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -2774,6 +2774,8 @@ public class PurpurWorldConfig { @@ -2770,6 +2770,8 @@ public class PurpurWorldConfig {
public double zombieVillagerJockeyChance = 0.05D; public double zombieVillagerJockeyChance = 0.05D;
public boolean zombieVillagerJockeyTryExistingChickens = true; public boolean zombieVillagerJockeyTryExistingChickens = true;
public boolean zombieVillagerTakeDamageFromWater = false; public boolean zombieVillagerTakeDamageFromWater = false;
@@ -30,7 +30,7 @@ index d13188a1207352a6ee5ff9c9ed633e7f834a81c9..b3a794d7181aecb8f734b98182f619ee
private void zombieVillagerSettings() { private void zombieVillagerSettings() {
zombieVillagerRidable = getBoolean("mobs.zombie_villager.ridable", zombieVillagerRidable); zombieVillagerRidable = getBoolean("mobs.zombie_villager.ridable", zombieVillagerRidable);
zombieVillagerRidableInWater = getBoolean("mobs.zombie_villager.ridable-in-water", zombieVillagerRidableInWater); zombieVillagerRidableInWater = getBoolean("mobs.zombie_villager.ridable-in-water", zombieVillagerRidableInWater);
@@ -2789,6 +2791,8 @@ public class PurpurWorldConfig { @@ -2785,6 +2787,8 @@ public class PurpurWorldConfig {
zombieVillagerJockeyChance = getDouble("mobs.zombie_villager.jockey.chance", zombieVillagerJockeyChance); zombieVillagerJockeyChance = getDouble("mobs.zombie_villager.jockey.chance", zombieVillagerJockeyChance);
zombieVillagerJockeyTryExistingChickens = getBoolean("mobs.zombie_villager.jockey.try-existing-chickens", zombieVillagerJockeyTryExistingChickens); zombieVillagerJockeyTryExistingChickens = getBoolean("mobs.zombie_villager.jockey.try-existing-chickens", zombieVillagerJockeyTryExistingChickens);
zombieVillagerTakeDamageFromWater = getBoolean("mobs.zombie_villager.takes-damage-from-water", zombieVillagerTakeDamageFromWater); zombieVillagerTakeDamageFromWater = getBoolean("mobs.zombie_villager.takes-damage-from-water", zombieVillagerTakeDamageFromWater);

View File

@@ -6,10 +6,10 @@ Subject: [PATCH] Option for sponges to work on lava and mud
Co-authored by: granny <granny@purpurmc.org> Co-authored by: granny <granny@purpurmc.org>
diff --git a/src/main/java/net/minecraft/world/level/block/SpongeBlock.java b/src/main/java/net/minecraft/world/level/block/SpongeBlock.java diff --git a/src/main/java/net/minecraft/world/level/block/SpongeBlock.java b/src/main/java/net/minecraft/world/level/block/SpongeBlock.java
index 709dd0af07f2439d7c7e8b5cd0677580dc3f6278..2276fed1feb4fea59b5bd49b5e4586d49478b3cc 100644 index e7b19fa84d9dce28dd88a3b4adcb83576dcb98a8..cc1ac862526377b2ac7b66bc20f428dc1aed6e78 100644
--- a/src/main/java/net/minecraft/world/level/block/SpongeBlock.java --- a/src/main/java/net/minecraft/world/level/block/SpongeBlock.java
+++ b/src/main/java/net/minecraft/world/level/block/SpongeBlock.java +++ b/src/main/java/net/minecraft/world/level/block/SpongeBlock.java
@@ -67,7 +67,7 @@ public class SpongeBlock extends Block { @@ -70,7 +70,7 @@ public class SpongeBlock extends Block {
FluidState fluid = blockList.getFluidState(blockposition1); FluidState fluid = blockList.getFluidState(blockposition1);
// CraftBukkit end // CraftBukkit end
@@ -18,7 +18,7 @@ index 709dd0af07f2439d7c7e8b5cd0677580dc3f6278..2276fed1feb4fea59b5bd49b5e4586d4
return false; return false;
} else { } else {
Block block = iblockdata.getBlock(); Block block = iblockdata.getBlock();
@@ -82,6 +82,10 @@ public class SpongeBlock extends Block { @@ -85,6 +85,10 @@ public class SpongeBlock extends Block {
if (iblockdata.getBlock() instanceof LiquidBlock) { if (iblockdata.getBlock() instanceof LiquidBlock) {
blockList.setBlock(blockposition1, Blocks.AIR.defaultBlockState(), 3); // CraftBukkit blockList.setBlock(blockposition1, Blocks.AIR.defaultBlockState(), 3); // CraftBukkit
@@ -30,10 +30,10 @@ index 709dd0af07f2439d7c7e8b5cd0677580dc3f6278..2276fed1feb4fea59b5bd49b5e4586d4
if (!iblockdata.is(Blocks.KELP) && !iblockdata.is(Blocks.KELP_PLANT) && !iblockdata.is(Blocks.SEAGRASS) && !iblockdata.is(Blocks.TALL_SEAGRASS)) { if (!iblockdata.is(Blocks.KELP) && !iblockdata.is(Blocks.KELP_PLANT) && !iblockdata.is(Blocks.SEAGRASS) && !iblockdata.is(Blocks.TALL_SEAGRASS)) {
return false; return false;
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index b3a794d7181aecb8f734b98182f619ee82bb3dbf..309f2360d3faa4e7f6932329623b9b9647cd5f98 100644 index b2f365ab51b56a83ed7ea67c921c163c3511b834..13aa8ae8f33834793adf18c12541c2ecd2d0699f 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -953,9 +953,13 @@ public class PurpurWorldConfig { @@ -949,9 +949,13 @@ public class PurpurWorldConfig {
public int spongeAbsorptionArea = 65; public int spongeAbsorptionArea = 65;
public int spongeAbsorptionRadius = 6; public int spongeAbsorptionRadius = 6;

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Toggle for Wither's spawn sound
diff --git a/src/main/java/net/minecraft/world/entity/boss/wither/WitherBoss.java b/src/main/java/net/minecraft/world/entity/boss/wither/WitherBoss.java diff --git a/src/main/java/net/minecraft/world/entity/boss/wither/WitherBoss.java b/src/main/java/net/minecraft/world/entity/boss/wither/WitherBoss.java
index ff5d08f0cf323606ca2eb8bef3f487c7a86029e2..5bf7a6ecd58612c8502ed747263b6c0edd445294 100644 index 86b06182616fe07f1a5ef2b1799c434884cba149..9abc47eb3d0c1a0ee0868ec223431f4de4925c77 100644
--- a/src/main/java/net/minecraft/world/entity/boss/wither/WitherBoss.java --- a/src/main/java/net/minecraft/world/entity/boss/wither/WitherBoss.java
+++ b/src/main/java/net/minecraft/world/entity/boss/wither/WitherBoss.java +++ b/src/main/java/net/minecraft/world/entity/boss/wither/WitherBoss.java
@@ -425,7 +425,7 @@ public class WitherBoss extends Monster implements PowerableMob, RangedAttackMob @@ -418,7 +418,7 @@ public class WitherBoss extends Monster implements PowerableMob, RangedAttackMob
} }
// CraftBukkit end // CraftBukkit end
@@ -18,10 +18,10 @@ index ff5d08f0cf323606ca2eb8bef3f487c7a86029e2..5bf7a6ecd58612c8502ed747263b6c0e
// this.level().globalLevelEvent(1023, new BlockPosition(this), 0); // this.level().globalLevelEvent(1023, new BlockPosition(this), 0);
int viewDistance = ((ServerLevel) this.level()).getCraftServer().getViewDistance() * 16; int viewDistance = ((ServerLevel) this.level()).getCraftServer().getViewDistance() * 16;
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 309f2360d3faa4e7f6932329623b9b9647cd5f98..21c597f6f010bca75115354b8cf5d567d8d0f474 100644 index 13aa8ae8f33834793adf18c12541c2ecd2d0699f..7670e4e1291e8c48b960ee44977d4850b470a81e 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -2621,6 +2621,7 @@ public class PurpurWorldConfig { @@ -2617,6 +2617,7 @@ public class PurpurWorldConfig {
public boolean witherTakeDamageFromWater = false; public boolean witherTakeDamageFromWater = false;
public boolean witherCanRideVehicles = false; public boolean witherCanRideVehicles = false;
public float witherExplosionRadius = 1.0F; public float witherExplosionRadius = 1.0F;
@@ -29,7 +29,7 @@ index 309f2360d3faa4e7f6932329623b9b9647cd5f98..21c597f6f010bca75115354b8cf5d567
private void witherSettings() { private void witherSettings() {
witherRidable = getBoolean("mobs.wither.ridable", witherRidable); witherRidable = getBoolean("mobs.wither.ridable", witherRidable);
witherRidableInWater = getBoolean("mobs.wither.ridable-in-water", witherRidableInWater); witherRidableInWater = getBoolean("mobs.wither.ridable-in-water", witherRidableInWater);
@@ -2642,6 +2643,7 @@ public class PurpurWorldConfig { @@ -2638,6 +2639,7 @@ public class PurpurWorldConfig {
witherTakeDamageFromWater = getBoolean("mobs.wither.takes-damage-from-water", witherTakeDamageFromWater); witherTakeDamageFromWater = getBoolean("mobs.wither.takes-damage-from-water", witherTakeDamageFromWater);
witherCanRideVehicles = getBoolean("mobs.wither.can-ride-vehicles", witherCanRideVehicles); witherCanRideVehicles = getBoolean("mobs.wither.can-ride-vehicles", witherCanRideVehicles);
witherExplosionRadius = (float) getDouble("mobs.wither.explosion-radius", witherExplosionRadius); witherExplosionRadius = (float) getDouble("mobs.wither.explosion-radius", witherExplosionRadius);

View File

@@ -18,10 +18,10 @@ index 0003fb51ae3a6575575e10b4c86719f3061e2577..c2ca3432a47124d02e1aaf8ffb621f9a
return false; return false;
} }
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 21c597f6f010bca75115354b8cf5d567d8d0f474..45d77adb73d0df1e856088d3df6cffb6a4623cd7 100644 index 7670e4e1291e8c48b960ee44977d4850b470a81e..2951c05d64f7c1667343dd781800816b7fae5cb9 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -779,6 +779,11 @@ public class PurpurWorldConfig { @@ -775,6 +775,11 @@ public class PurpurWorldConfig {
}); });
} }

View File

@@ -5,7 +5,7 @@ Subject: [PATCH] Config to remove curse of binding with weakness
diff --git a/src/main/java/net/minecraft/world/inventory/InventoryMenu.java b/src/main/java/net/minecraft/world/inventory/InventoryMenu.java diff --git a/src/main/java/net/minecraft/world/inventory/InventoryMenu.java b/src/main/java/net/minecraft/world/inventory/InventoryMenu.java
index c549618421c5d077c3d977d8d2064eca2acc438a..5972fa434847d24fa98b7895fd8386d20a636885 100644 index b399903e8f11ec6c12fe7e724b7d9c8292acd573..a4afa946cd47238eb0fed297a27b24013d5ba77c 100644
--- a/src/main/java/net/minecraft/world/inventory/InventoryMenu.java --- a/src/main/java/net/minecraft/world/inventory/InventoryMenu.java
+++ b/src/main/java/net/minecraft/world/inventory/InventoryMenu.java +++ b/src/main/java/net/minecraft/world/inventory/InventoryMenu.java
@@ -4,6 +4,7 @@ import com.mojang.datafixers.util.Pair; @@ -4,6 +4,7 @@ import com.mojang.datafixers.util.Pair;
@@ -26,10 +26,10 @@ index c549618421c5d077c3d977d8d2064eca2acc438a..5972fa434847d24fa98b7895fd8386d2
@Override @Override
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 45d77adb73d0df1e856088d3df6cffb6a4623cd7..8e5912f9a1e3d4b97306bf31833afc435cd026e8 100644 index 2951c05d64f7c1667343dd781800816b7fae5cb9..f64c758f51134e8102ca4092bc313eefd346d211 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -408,6 +408,7 @@ public class PurpurWorldConfig { @@ -406,6 +406,7 @@ public class PurpurWorldConfig {
public int playerPortalWaitTime = 80; public int playerPortalWaitTime = 80;
public int playerCreativePortalWaitTime = 1; public int playerCreativePortalWaitTime = 1;
public boolean playerRidableInWater = false; public boolean playerRidableInWater = false;
@@ -37,7 +37,7 @@ index 45d77adb73d0df1e856088d3df6cffb6a4623cd7..8e5912f9a1e3d4b97306bf31833afc43
private void playerSettings() { private void playerSettings() {
if (PurpurConfig.version < 19) { if (PurpurConfig.version < 19) {
boolean oldVal = getBoolean("gameplay-mechanics.player.idle-timeout.mods-target", idleTimeoutTargetPlayer); boolean oldVal = getBoolean("gameplay-mechanics.player.idle-timeout.mods-target", idleTimeoutTargetPlayer);
@@ -435,6 +436,7 @@ public class PurpurWorldConfig { @@ -431,6 +432,7 @@ public class PurpurWorldConfig {
playerPortalWaitTime = getInt("gameplay-mechanics.player.portal-wait-time", playerPortalWaitTime); playerPortalWaitTime = getInt("gameplay-mechanics.player.portal-wait-time", playerPortalWaitTime);
playerCreativePortalWaitTime = getInt("gameplay-mechanics.player.creative-portal-wait-time", playerCreativePortalWaitTime); playerCreativePortalWaitTime = getInt("gameplay-mechanics.player.creative-portal-wait-time", playerCreativePortalWaitTime);
playerRidableInWater = getBoolean("gameplay-mechanics.player.ridable-in-water", playerRidableInWater); playerRidableInWater = getBoolean("gameplay-mechanics.player.ridable-in-water", playerRidableInWater);

View File

@@ -77,10 +77,10 @@ index 963a596154091b79ca139af6274aa323518ad1ad..4dcac3899a500d8586580bcfd5b4516e
}); });
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 8e5912f9a1e3d4b97306bf31833afc435cd026e8..97afdc6199fd2b3c2033c8b3a27d2e5059f780cb 100644 index f64c758f51134e8102ca4092bc313eefd346d211..5fd3e6bab03a2adcb776720b242c902b1330779e 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -2840,4 +2840,27 @@ public class PurpurWorldConfig { @@ -2836,4 +2836,27 @@ public class PurpurWorldConfig {
private void hungerSettings() { private void hungerSettings() {
hungerStarvationDamage = (float) getDouble("hunger.starvation-damage", hungerStarvationDamage); hungerStarvationDamage = (float) getDouble("hunger.starvation-damage", hungerStarvationDamage);
} }

View File

@@ -47,10 +47,10 @@ index cd943997f11f5ea5c600fdc6db96043fb0fa713c..4adeda49a2e422e11f885bffb311653d
if (dripChance < f1) { if (dripChance < f1) {
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 97afdc6199fd2b3c2033c8b3a27d2e5059f780cb..389ed035a2fb98675f6779628a620ad0680823f8 100644 index 5fd3e6bab03a2adcb776720b242c902b1330779e..909e6bb2781637e5f4c2525371de2ad0b5524afe 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -2863,4 +2863,15 @@ public class PurpurWorldConfig { @@ -2859,4 +2859,15 @@ public class PurpurWorldConfig {
}); });
conduitBlocks = conduitBlockList.toArray(Block[]::new); conduitBlocks = conduitBlockList.toArray(Block[]::new);
} }

View File

@@ -18,7 +18,7 @@ index 3583fcf5284bc5883308876dbd9886664b391e28..d976a6df54c1e817def2d588692abe25
if (node != null && (node.type == BlockPathTypes.OPEN || node.type == BlockPathTypes.WALKABLE) && this.mob.getBbWidth() < 1.0F) { if (node != null && (node.type == BlockPathTypes.OPEN || node.type == BlockPathTypes.WALKABLE) && this.mob.getBbWidth() < 1.0F) {
double g = (double)(x - direction.getStepX()) + 0.5D; double g = (double)(x - direction.getStepX()) + 0.5D;
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 389ed035a2fb98675f6779628a620ad0680823f8..14a9bbb6bda6ba245a84cfe7ed80dd591ae41dd7 100644 index 909e6bb2781637e5f4c2525371de2ad0b5524afe..8ae2e7f81d1d6a09d9b733ae27ad6c99a58aeb2e 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -138,6 +138,7 @@ public class PurpurWorldConfig { @@ -138,6 +138,7 @@ public class PurpurWorldConfig {

View File

@@ -5,7 +5,7 @@ Subject: [PATCH] Shulker change color with dye
diff --git a/src/main/java/net/minecraft/world/entity/monster/Shulker.java b/src/main/java/net/minecraft/world/entity/monster/Shulker.java diff --git a/src/main/java/net/minecraft/world/entity/monster/Shulker.java b/src/main/java/net/minecraft/world/entity/monster/Shulker.java
index a0b19ffbdb64c40d8b92ed82104dde323b466190..714adaf017813eb64bb3a9a60b5ff45737e4d95d 100644 index 786fe41cc743817f2ed613969c7eeec9fc001b4b..40f4a53cf244549e9cf392f4286bdec1a6852574 100644
--- a/src/main/java/net/minecraft/world/entity/monster/Shulker.java --- a/src/main/java/net/minecraft/world/entity/monster/Shulker.java
+++ b/src/main/java/net/minecraft/world/entity/monster/Shulker.java +++ b/src/main/java/net/minecraft/world/entity/monster/Shulker.java
@@ -22,6 +22,8 @@ import net.minecraft.tags.DamageTypeTags; @@ -22,6 +22,8 @@ import net.minecraft.tags.DamageTypeTags;
@@ -17,16 +17,16 @@ index a0b19ffbdb64c40d8b92ed82104dde323b466190..714adaf017813eb64bb3a9a60b5ff457
import net.minecraft.world.damagesource.DamageSource; import net.minecraft.world.damagesource.DamageSource;
import net.minecraft.world.entity.Entity; import net.minecraft.world.entity.Entity;
import net.minecraft.world.entity.EntityDimensions; import net.minecraft.world.entity.EntityDimensions;
@@ -50,6 +52,8 @@ import net.minecraft.world.entity.projectile.AbstractArrow; @@ -49,6 +51,8 @@ import net.minecraft.world.entity.player.Player;
import net.minecraft.world.entity.projectile.AbstractArrow;
import net.minecraft.world.entity.projectile.ShulkerBullet; import net.minecraft.world.entity.projectile.ShulkerBullet;
import net.minecraft.world.entity.vehicle.Boat;
import net.minecraft.world.item.DyeColor; import net.minecraft.world.item.DyeColor;
+import net.minecraft.world.item.DyeItem; +import net.minecraft.world.item.DyeItem;
+import net.minecraft.world.item.ItemStack; +import net.minecraft.world.item.ItemStack;
import net.minecraft.world.level.Level; import net.minecraft.world.level.Level;
import net.minecraft.world.level.ServerLevelAccessor; import net.minecraft.world.level.ServerLevelAccessor;
import net.minecraft.world.level.block.Blocks; import net.minecraft.world.level.block.Blocks;
@@ -125,6 +129,19 @@ public class Shulker extends AbstractGolem implements VariantHolder<Optional<Dye @@ -124,6 +128,19 @@ public class Shulker extends AbstractGolem implements VariantHolder<Optional<Dye
return this.level().purpurConfig.shulkerTakeDamageFromWater; return this.level().purpurConfig.shulkerTakeDamageFromWater;
} }
@@ -47,10 +47,10 @@ index a0b19ffbdb64c40d8b92ed82104dde323b466190..714adaf017813eb64bb3a9a60b5ff457
protected void registerGoals() { protected void registerGoals() {
this.goalSelector.addGoal(0, new org.purpurmc.purpur.entity.ai.HasRider(this)); // Purpur this.goalSelector.addGoal(0, new org.purpurmc.purpur.entity.ai.HasRider(this)); // Purpur
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 14a9bbb6bda6ba245a84cfe7ed80dd591ae41dd7..36bf7feb12b83f97612fa221a48fcffb61f9de88 100644 index 8ae2e7f81d1d6a09d9b733ae27ad6c99a58aeb2e..a8cddd10832e6be2704569b6c1fb995bd9caf0b9 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -2183,6 +2183,7 @@ public class PurpurWorldConfig { @@ -2179,6 +2179,7 @@ public class PurpurWorldConfig {
public double shulkerSpawnFromBulletNearbyRange = 8.0D; public double shulkerSpawnFromBulletNearbyRange = 8.0D;
public String shulkerSpawnFromBulletNearbyEquation = "(nearby - 1) / 5.0"; public String shulkerSpawnFromBulletNearbyEquation = "(nearby - 1) / 5.0";
public boolean shulkerSpawnFromBulletRandomColor = false; public boolean shulkerSpawnFromBulletRandomColor = false;
@@ -58,7 +58,7 @@ index 14a9bbb6bda6ba245a84cfe7ed80dd591ae41dd7..36bf7feb12b83f97612fa221a48fcffb
private void shulkerSettings() { private void shulkerSettings() {
shulkerRidable = getBoolean("mobs.shulker.ridable", shulkerRidable); shulkerRidable = getBoolean("mobs.shulker.ridable", shulkerRidable);
shulkerRidableInWater = getBoolean("mobs.shulker.ridable-in-water", shulkerRidableInWater); shulkerRidableInWater = getBoolean("mobs.shulker.ridable-in-water", shulkerRidableInWater);
@@ -2199,6 +2200,7 @@ public class PurpurWorldConfig { @@ -2195,6 +2196,7 @@ public class PurpurWorldConfig {
shulkerSpawnFromBulletNearbyRange = getDouble("mobs.shulker.spawn-from-bullet.nearby-range", shulkerSpawnFromBulletNearbyRange); shulkerSpawnFromBulletNearbyRange = getDouble("mobs.shulker.spawn-from-bullet.nearby-range", shulkerSpawnFromBulletNearbyRange);
shulkerSpawnFromBulletNearbyEquation = getString("mobs.shulker.spawn-from-bullet.nearby-equation", shulkerSpawnFromBulletNearbyEquation); shulkerSpawnFromBulletNearbyEquation = getString("mobs.shulker.spawn-from-bullet.nearby-equation", shulkerSpawnFromBulletNearbyEquation);
shulkerSpawnFromBulletRandomColor = getBoolean("mobs.shulker.spawn-from-bullet.random-color", shulkerSpawnFromBulletRandomColor); shulkerSpawnFromBulletRandomColor = getBoolean("mobs.shulker.spawn-from-bullet.random-color", shulkerSpawnFromBulletRandomColor);

View File

@@ -5,7 +5,7 @@ Subject: [PATCH] Extended OfflinePlayer API
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftOfflinePlayer.java b/src/main/java/org/bukkit/craftbukkit/CraftOfflinePlayer.java diff --git a/src/main/java/org/bukkit/craftbukkit/CraftOfflinePlayer.java b/src/main/java/org/bukkit/craftbukkit/CraftOfflinePlayer.java
index c1b874cd6e0498fce3cd53fdbaca30d290e004d7..23087d511b609693f0bb06cbaac8b6cf8d0defe2 100644 index 03fc90a470c0f63d44161843cac88bea09166858..88640ac32d70ced6e8b1984663e1c492dd673cb5 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftOfflinePlayer.java --- a/src/main/java/org/bukkit/craftbukkit/CraftOfflinePlayer.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftOfflinePlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftOfflinePlayer.java
@@ -567,4 +567,213 @@ public class CraftOfflinePlayer implements OfflinePlayer, ConfigurationSerializa @@ -567,4 +567,213 @@ public class CraftOfflinePlayer implements OfflinePlayer, ConfigurationSerializa
@@ -223,10 +223,10 @@ index c1b874cd6e0498fce3cd53fdbaca30d290e004d7..23087d511b609693f0bb06cbaac8b6cf
+ // Purpur end - OfflinePlayer API + // Purpur end - OfflinePlayer API
} }
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
index 5965b4e91e63a3d3b64e5193399ae3b6d774120b..5baf36d8d65574f3e57de0937a949cff03435d30 100644 index a0523c36af5a2e33f8f46663794a8df68409f80f..19f6bad1b81c5a5c249631b43e1f6c159dc994e0 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
@@ -2505,6 +2505,28 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -2521,6 +2521,28 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
return this.getHandle().getAbilities().walkingSpeed * 2f; return this.getHandle().getAbilities().walkingSpeed * 2f;
} }

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Added the ability to add combustible items
diff --git a/src/main/java/net/minecraft/world/inventory/AbstractFurnaceMenu.java b/src/main/java/net/minecraft/world/inventory/AbstractFurnaceMenu.java diff --git a/src/main/java/net/minecraft/world/inventory/AbstractFurnaceMenu.java b/src/main/java/net/minecraft/world/inventory/AbstractFurnaceMenu.java
index 35b41bceeba72c3896c91c2605bac3b0bf9c54e9..5c028f957661089ff502109c996692856b12ee27 100644 index 1af7e1548f0648890a1ef2fc0ff4e4c3a56c947c..decea1697c075e7549ccc7501c8e59357d198a60 100644
--- a/src/main/java/net/minecraft/world/inventory/AbstractFurnaceMenu.java --- a/src/main/java/net/minecraft/world/inventory/AbstractFurnaceMenu.java
+++ b/src/main/java/net/minecraft/world/inventory/AbstractFurnaceMenu.java +++ b/src/main/java/net/minecraft/world/inventory/AbstractFurnaceMenu.java
@@ -145,7 +145,13 @@ public abstract class AbstractFurnaceMenu extends RecipeBookMenu<Container> { @@ -147,7 +147,13 @@ public abstract class AbstractFurnaceMenu extends RecipeBookMenu<Container> {
} else if (slot != 1 && slot != 0) { } else if (slot != 1 && slot != 0) {
if (this.canSmelt(itemstack1)) { if (this.canSmelt(itemstack1)) {
if (!this.moveItemStackTo(itemstack1, 0, 1, false)) { if (!this.moveItemStackTo(itemstack1, 0, 1, false)) {
@@ -24,7 +24,7 @@ index 35b41bceeba72c3896c91c2605bac3b0bf9c54e9..5c028f957661089ff502109c99669285
} else if (this.isFuel(itemstack1)) { } else if (this.isFuel(itemstack1)) {
if (!this.moveItemStackTo(itemstack1, 1, 2, false)) { if (!this.moveItemStackTo(itemstack1, 1, 2, false)) {
diff --git a/src/main/java/net/minecraft/world/level/block/entity/AbstractFurnaceBlockEntity.java b/src/main/java/net/minecraft/world/level/block/entity/AbstractFurnaceBlockEntity.java diff --git a/src/main/java/net/minecraft/world/level/block/entity/AbstractFurnaceBlockEntity.java b/src/main/java/net/minecraft/world/level/block/entity/AbstractFurnaceBlockEntity.java
index ca2052804ad829a1528a9c5a0a792275beead113..997d0fab71eacc6466ffe3bc8f6349e5813d6d49 100644 index b0afc384907bb75dfa26e432a2328fe080660019..92e58d9503daf4cc9bc1f4c7785e159e0c1f4bf3 100644
--- a/src/main/java/net/minecraft/world/level/block/entity/AbstractFurnaceBlockEntity.java --- a/src/main/java/net/minecraft/world/level/block/entity/AbstractFurnaceBlockEntity.java
+++ b/src/main/java/net/minecraft/world/level/block/entity/AbstractFurnaceBlockEntity.java +++ b/src/main/java/net/minecraft/world/level/block/entity/AbstractFurnaceBlockEntity.java
@@ -208,6 +208,22 @@ public abstract class AbstractFurnaceBlockEntity extends BaseContainerBlockEntit @@ -208,6 +208,22 @@ public abstract class AbstractFurnaceBlockEntity extends BaseContainerBlockEntit
@@ -51,10 +51,10 @@ index ca2052804ad829a1528a9c5a0a792275beead113..997d0fab71eacc6466ffe3bc8f6349e5
private int maxStack = MAX_STACK; private int maxStack = MAX_STACK;
public List<HumanEntity> transaction = new java.util.ArrayList<HumanEntity>(); public List<HumanEntity> transaction = new java.util.ArrayList<HumanEntity>();
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
index 9bf5facac29591b7f6d5cfb7abb5a7bf6e9d382b..ab31661318beb96bc18b270cc614adcf0ea86d08 100644 index 3f06e418e1322b966f19b488beb2780e7168b45b..cb912efba182aff9e8f080aa473f78115eae8a47 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
@@ -1535,6 +1535,19 @@ public final class CraftServer implements Server { @@ -1532,6 +1532,19 @@ public final class CraftServer implements Server {
return true; return true;
} }

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Option for if rain and thunder should stop on sleep
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
index df8efd93ad6ab30974e3025187cd234b37111129..8cbb36b2dbcb9a1470c95746d7d481a142419164 100644 index bbb3052a3b2704e25696457d53d0940664fa263a..cb35bac1923fe40f172a521ce5892e0dcfd7e305 100644
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java --- a/src/main/java/net/minecraft/server/level/ServerLevel.java
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java +++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
@@ -1344,6 +1344,7 @@ public class ServerLevel extends Level implements WorldGenLevel { @@ -1241,6 +1241,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
private void resetWeatherCycle() { private void resetWeatherCycle() {
// CraftBukkit start // CraftBukkit start
@@ -16,7 +16,7 @@ index df8efd93ad6ab30974e3025187cd234b37111129..8cbb36b2dbcb9a1470c95746d7d481a1
this.serverLevelData.setRaining(false, org.bukkit.event.weather.WeatherChangeEvent.Cause.SLEEP); // Paper - when passing the night this.serverLevelData.setRaining(false, org.bukkit.event.weather.WeatherChangeEvent.Cause.SLEEP); // Paper - when passing the night
// If we stop due to everyone sleeping we should reset the weather duration to some other random value. // If we stop due to everyone sleeping we should reset the weather duration to some other random value.
// Not that everyone ever manages to get the whole server to sleep at the same time.... // Not that everyone ever manages to get the whole server to sleep at the same time....
@@ -1351,6 +1352,7 @@ public class ServerLevel extends Level implements WorldGenLevel { @@ -1248,6 +1249,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
this.serverLevelData.setRainTime(0); this.serverLevelData.setRainTime(0);
} }
// CraftBukkit end // CraftBukkit end
@@ -25,7 +25,7 @@ index df8efd93ad6ab30974e3025187cd234b37111129..8cbb36b2dbcb9a1470c95746d7d481a1
// CraftBukkit start // CraftBukkit start
// If we stop due to everyone sleeping we should reset the weather duration to some other random value. // If we stop due to everyone sleeping we should reset the weather duration to some other random value.
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 36bf7feb12b83f97612fa221a48fcffb61f9de88..8d8248e00a9235abffbf381398a13ff2bb9f2b08 100644 index a8cddd10832e6be2704569b6c1fb995bd9caf0b9..1da30e052c08c27370755cae3e1890a397a2f323 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -139,6 +139,8 @@ public class PurpurWorldConfig { @@ -139,6 +139,8 @@ public class PurpurWorldConfig {

View File

@@ -5,7 +5,7 @@ Subject: [PATCH] Chance for azalea blocks to grow into trees naturally
diff --git a/src/main/java/net/minecraft/world/level/block/AzaleaBlock.java b/src/main/java/net/minecraft/world/level/block/AzaleaBlock.java diff --git a/src/main/java/net/minecraft/world/level/block/AzaleaBlock.java b/src/main/java/net/minecraft/world/level/block/AzaleaBlock.java
index 95b53450a807fccfa55b59852da52785b8cf3e3d..c69f1d23979a0759472d22760a18d986b2d979b6 100644 index 087f3b3cc180e16195efdc0b402701fd9f5d78b4..aa4e13f1c77f10221128569483497668cd2eb7d3 100644
--- a/src/main/java/net/minecraft/world/level/block/AzaleaBlock.java --- a/src/main/java/net/minecraft/world/level/block/AzaleaBlock.java
+++ b/src/main/java/net/minecraft/world/level/block/AzaleaBlock.java +++ b/src/main/java/net/minecraft/world/level/block/AzaleaBlock.java
@@ -43,6 +43,20 @@ public class AzaleaBlock extends BushBlock implements BonemealableBlock { @@ -43,6 +43,20 @@ public class AzaleaBlock extends BushBlock implements BonemealableBlock {
@@ -30,10 +30,10 @@ index 95b53450a807fccfa55b59852da52785b8cf3e3d..c69f1d23979a0759472d22760a18d986
} }
diff --git a/src/main/java/net/minecraft/world/level/block/Blocks.java b/src/main/java/net/minecraft/world/level/block/Blocks.java diff --git a/src/main/java/net/minecraft/world/level/block/Blocks.java b/src/main/java/net/minecraft/world/level/block/Blocks.java
index 0453397c157c8c7968947445f41bc46b68b111e8..ed35878fdb9dffcd46c27d26ee8379401207cef5 100644 index b49e02ac7b3db9a5b79ce3f106ead19af4e7cfa6..6425bc42bb8024aa7936b841d6c2ee2c892eb329 100644
--- a/src/main/java/net/minecraft/world/level/block/Blocks.java --- a/src/main/java/net/minecraft/world/level/block/Blocks.java
+++ b/src/main/java/net/minecraft/world/level/block/Blocks.java +++ b/src/main/java/net/minecraft/world/level/block/Blocks.java
@@ -1093,8 +1093,8 @@ public class Blocks { @@ -1094,8 +1094,8 @@ public class Blocks {
public static final Block CAVE_VINES = register("cave_vines", new CaveVinesBlock(BlockBehaviour.Properties.of().mapColor(MapColor.PLANT).randomTicks().noCollission().lightLevel(CaveVines.emission(14)).instabreak().sound(SoundType.CAVE_VINES).pushReaction(PushReaction.DESTROY))); public static final Block CAVE_VINES = register("cave_vines", new CaveVinesBlock(BlockBehaviour.Properties.of().mapColor(MapColor.PLANT).randomTicks().noCollission().lightLevel(CaveVines.emission(14)).instabreak().sound(SoundType.CAVE_VINES).pushReaction(PushReaction.DESTROY)));
public static final Block CAVE_VINES_PLANT = register("cave_vines_plant", new CaveVinesPlantBlock(BlockBehaviour.Properties.of().mapColor(MapColor.PLANT).noCollission().lightLevel(CaveVines.emission(14)).instabreak().sound(SoundType.CAVE_VINES).pushReaction(PushReaction.DESTROY))); public static final Block CAVE_VINES_PLANT = register("cave_vines_plant", new CaveVinesPlantBlock(BlockBehaviour.Properties.of().mapColor(MapColor.PLANT).noCollission().lightLevel(CaveVines.emission(14)).instabreak().sound(SoundType.CAVE_VINES).pushReaction(PushReaction.DESTROY)));
public static final Block SPORE_BLOSSOM = register("spore_blossom", new SporeBlossomBlock(BlockBehaviour.Properties.of().mapColor(MapColor.PLANT).instabreak().noCollission().sound(SoundType.SPORE_BLOSSOM).pushReaction(PushReaction.DESTROY))); public static final Block SPORE_BLOSSOM = register("spore_blossom", new SporeBlossomBlock(BlockBehaviour.Properties.of().mapColor(MapColor.PLANT).instabreak().noCollission().sound(SoundType.SPORE_BLOSSOM).pushReaction(PushReaction.DESTROY)));
@@ -45,10 +45,10 @@ index 0453397c157c8c7968947445f41bc46b68b111e8..ed35878fdb9dffcd46c27d26ee837940
public static final Block PINK_PETALS = register("pink_petals", new PinkPetalsBlock(BlockBehaviour.Properties.of().mapColor(MapColor.PLANT).noCollission().sound(SoundType.PINK_PETALS).pushReaction(PushReaction.DESTROY))); public static final Block PINK_PETALS = register("pink_petals", new PinkPetalsBlock(BlockBehaviour.Properties.of().mapColor(MapColor.PLANT).noCollission().sound(SoundType.PINK_PETALS).pushReaction(PushReaction.DESTROY)));
public static final Block MOSS_BLOCK = register("moss_block", new MossBlock(BlockBehaviour.Properties.of().mapColor(MapColor.COLOR_GREEN).strength(0.1F).sound(SoundType.MOSS).pushReaction(PushReaction.DESTROY))); public static final Block MOSS_BLOCK = register("moss_block", new MossBlock(BlockBehaviour.Properties.of().mapColor(MapColor.COLOR_GREEN).strength(0.1F).sound(SoundType.MOSS).pushReaction(PushReaction.DESTROY)));
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 8d8248e00a9235abffbf381398a13ff2bb9f2b08..9e7c090c44edc98b3399046ad76c5ca144f5bb2d 100644 index 1da30e052c08c27370755cae3e1890a397a2f323..a3a5decf6586569c347d36f4416cf3cb3b0bef78 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -739,6 +739,11 @@ public class PurpurWorldConfig { @@ -735,6 +735,11 @@ public class PurpurWorldConfig {
anvilColorsUseMiniMessage = getBoolean("blocks.anvil.use-mini-message", anvilColorsUseMiniMessage); anvilColorsUseMiniMessage = getBoolean("blocks.anvil.use-mini-message", anvilColorsUseMiniMessage);
} }
@@ -60,7 +60,7 @@ index 8d8248e00a9235abffbf381398a13ff2bb9f2b08..9e7c090c44edc98b3399046ad76c5ca1
public int beaconLevelOne = 20; public int beaconLevelOne = 20;
public int beaconLevelTwo = 30; public int beaconLevelTwo = 30;
public int beaconLevelThree = 40; public int beaconLevelThree = 40;
@@ -876,6 +881,11 @@ public class PurpurWorldConfig { @@ -872,6 +877,11 @@ public class PurpurWorldConfig {
farmlandTramplingFeatherFalling = getBoolean("blocks.farmland.feather-fall-distance-affects-trampling", farmlandTramplingFeatherFalling); farmlandTramplingFeatherFalling = getBoolean("blocks.farmland.feather-fall-distance-affects-trampling", farmlandTramplingFeatherFalling);
} }

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Shift right click to use exp for mending
diff --git a/src/main/java/net/minecraft/server/level/ServerPlayerGameMode.java b/src/main/java/net/minecraft/server/level/ServerPlayerGameMode.java diff --git a/src/main/java/net/minecraft/server/level/ServerPlayerGameMode.java b/src/main/java/net/minecraft/server/level/ServerPlayerGameMode.java
index 1e0d07949e8b4450a400625a23d386024192eef1..f3bac087856f420aa6c14707e90288f4962967bf 100644 index 0488fe39acf7191754707b7c8f424e6a3e32c152..bcce65e453bec778739e8b2f9d89356f41dbbd20 100644
--- a/src/main/java/net/minecraft/server/level/ServerPlayerGameMode.java --- a/src/main/java/net/minecraft/server/level/ServerPlayerGameMode.java
+++ b/src/main/java/net/minecraft/server/level/ServerPlayerGameMode.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayerGameMode.java
@@ -518,6 +518,7 @@ public class ServerPlayerGameMode { @@ -516,6 +516,7 @@ public class ServerPlayerGameMode {
public InteractionHand interactHand; public InteractionHand interactHand;
public ItemStack interactItemStack; public ItemStack interactItemStack;
public InteractionResult useItemOn(ServerPlayer player, Level world, ItemStack stack, InteractionHand hand, BlockHitResult hitResult) { public InteractionResult useItemOn(ServerPlayer player, Level world, ItemStack stack, InteractionHand hand, BlockHitResult hitResult) {
@@ -16,7 +16,7 @@ index 1e0d07949e8b4450a400625a23d386024192eef1..f3bac087856f420aa6c14707e90288f4
BlockPos blockposition = hitResult.getBlockPos(); BlockPos blockposition = hitResult.getBlockPos();
BlockState iblockdata = world.getBlockState(blockposition); BlockState iblockdata = world.getBlockState(blockposition);
InteractionResult enuminteractionresult = InteractionResult.PASS; InteractionResult enuminteractionresult = InteractionResult.PASS;
@@ -620,4 +621,18 @@ public class ServerPlayerGameMode { @@ -618,4 +619,18 @@ public class ServerPlayerGameMode {
public void setLevel(ServerLevel world) { public void setLevel(ServerLevel world) {
this.level = world; this.level = world;
} }
@@ -36,10 +36,10 @@ index 1e0d07949e8b4450a400625a23d386024192eef1..f3bac087856f420aa6c14707e90288f4
+ // Purpur end + // Purpur end
} }
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
index 7ac39b9f7a0afabe4a6fde954a85f0d4f53a01df..cb1851fca9290edb502662c100bb2ac6fa4d70d1 100644 index fe4f8517f1d3614568be697720908609776f353e..70eaf9347d49924841f2cfa23932b3eadfe49c82 100644
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -2144,6 +2144,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic @@ -2019,6 +2019,7 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl
boolean cancelled; boolean cancelled;
if (movingobjectposition == null || movingobjectposition.getType() != HitResult.Type.BLOCK) { if (movingobjectposition == null || movingobjectposition.getType() != HitResult.Type.BLOCK) {
@@ -48,10 +48,10 @@ index 7ac39b9f7a0afabe4a6fde954a85f0d4f53a01df..cb1851fca9290edb502662c100bb2ac6
cancelled = event.useItemInHand() == Event.Result.DENY; cancelled = event.useItemInHand() == Event.Result.DENY;
} else { } else {
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 9e7c090c44edc98b3399046ad76c5ca144f5bb2d..8d59047a6ab10af7a4cc418345ff7b17ce5d6355 100644 index a3a5decf6586569c347d36f4416cf3cb3b0bef78..8e658c5e81b85fa4fa36b9e18a02bd0634e42554 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -415,6 +415,7 @@ public class PurpurWorldConfig { @@ -413,6 +413,7 @@ public class PurpurWorldConfig {
public int playerCreativePortalWaitTime = 1; public int playerCreativePortalWaitTime = 1;
public boolean playerRidableInWater = false; public boolean playerRidableInWater = false;
public boolean playerRemoveBindingWithWeakness = false; public boolean playerRemoveBindingWithWeakness = false;
@@ -59,7 +59,7 @@ index 9e7c090c44edc98b3399046ad76c5ca144f5bb2d..8d59047a6ab10af7a4cc418345ff7b17
private void playerSettings() { private void playerSettings() {
if (PurpurConfig.version < 19) { if (PurpurConfig.version < 19) {
boolean oldVal = getBoolean("gameplay-mechanics.player.idle-timeout.mods-target", idleTimeoutTargetPlayer); boolean oldVal = getBoolean("gameplay-mechanics.player.idle-timeout.mods-target", idleTimeoutTargetPlayer);
@@ -443,6 +444,7 @@ public class PurpurWorldConfig { @@ -439,6 +440,7 @@ public class PurpurWorldConfig {
playerCreativePortalWaitTime = getInt("gameplay-mechanics.player.creative-portal-wait-time", playerCreativePortalWaitTime); playerCreativePortalWaitTime = getInt("gameplay-mechanics.player.creative-portal-wait-time", playerCreativePortalWaitTime);
playerRidableInWater = getBoolean("gameplay-mechanics.player.ridable-in-water", playerRidableInWater); playerRidableInWater = getBoolean("gameplay-mechanics.player.ridable-in-water", playerRidableInWater);
playerRemoveBindingWithWeakness = getBoolean("gameplay-mechanics.player.curse-of-binding.remove-with-weakness", playerRemoveBindingWithWeakness); playerRemoveBindingWithWeakness = getBoolean("gameplay-mechanics.player.curse-of-binding.remove-with-weakness", playerRemoveBindingWithWeakness);

View File

@@ -48,10 +48,10 @@ index 77746eeffdc612793a6c907f222753bce5cd0ed4..b6342637f1b42b6368dcda17eea4b39a
public static AttributeSupplier.Builder createAttributes() { public static AttributeSupplier.Builder createAttributes() {
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 8d59047a6ab10af7a4cc418345ff7b17ce5d6355..80f7ae88760e6de74445271712929b3bdc2dda3c 100644 index 8e658c5e81b85fa4fa36b9e18a02bd0634e42554..c146356aa04126f2cd74aabf50c1436fa111aa6a 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -1281,6 +1281,7 @@ public class PurpurWorldConfig { @@ -1277,6 +1277,7 @@ public class PurpurWorldConfig {
public double dolphinMaxHealth = 10.0D; public double dolphinMaxHealth = 10.0D;
public boolean dolphinDisableTreasureSearching = false; public boolean dolphinDisableTreasureSearching = false;
public boolean dolphinTakeDamageFromWater = false; public boolean dolphinTakeDamageFromWater = false;
@@ -59,7 +59,7 @@ index 8d59047a6ab10af7a4cc418345ff7b17ce5d6355..80f7ae88760e6de74445271712929b3b
private void dolphinSettings() { private void dolphinSettings() {
dolphinRidable = getBoolean("mobs.dolphin.ridable", dolphinRidable); dolphinRidable = getBoolean("mobs.dolphin.ridable", dolphinRidable);
dolphinControllable = getBoolean("mobs.dolphin.controllable", dolphinControllable); dolphinControllable = getBoolean("mobs.dolphin.controllable", dolphinControllable);
@@ -1295,6 +1296,7 @@ public class PurpurWorldConfig { @@ -1291,6 +1292,7 @@ public class PurpurWorldConfig {
dolphinMaxHealth = getDouble("mobs.dolphin.attributes.max_health", dolphinMaxHealth); dolphinMaxHealth = getDouble("mobs.dolphin.attributes.max_health", dolphinMaxHealth);
dolphinDisableTreasureSearching = getBoolean("mobs.dolphin.disable-treasure-searching", dolphinDisableTreasureSearching); dolphinDisableTreasureSearching = getBoolean("mobs.dolphin.disable-treasure-searching", dolphinDisableTreasureSearching);
dolphinTakeDamageFromWater = getBoolean("mobs.dolphin.takes-damage-from-water", dolphinTakeDamageFromWater); dolphinTakeDamageFromWater = getBoolean("mobs.dolphin.takes-damage-from-water", dolphinTakeDamageFromWater);

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Cows naturally aggressive to players chance
diff --git a/src/main/java/net/minecraft/world/entity/animal/Cow.java b/src/main/java/net/minecraft/world/entity/animal/Cow.java diff --git a/src/main/java/net/minecraft/world/entity/animal/Cow.java b/src/main/java/net/minecraft/world/entity/animal/Cow.java
index 8d714c029cf3b62af1ff8140a82ed3ae463e0e18..37f073e821a1b0f8efe89a7d88ce732cda402dff 100644 index f76b0d92150fd985a8fc699f6f884527d589dfd3..3c12e179861b5514e081d0db1664f7173955629c 100644
--- a/src/main/java/net/minecraft/world/entity/animal/Cow.java --- a/src/main/java/net/minecraft/world/entity/animal/Cow.java
+++ b/src/main/java/net/minecraft/world/entity/animal/Cow.java +++ b/src/main/java/net/minecraft/world/entity/animal/Cow.java
@@ -39,6 +39,7 @@ import org.bukkit.event.player.PlayerBucketFillEvent; @@ -42,6 +42,7 @@ import org.bukkit.event.player.PlayerBucketFillEvent;
// CraftBukkit end // CraftBukkit end
public class Cow extends Animal { public class Cow extends Animal {
@@ -16,7 +16,7 @@ index 8d714c029cf3b62af1ff8140a82ed3ae463e0e18..37f073e821a1b0f8efe89a7d88ce732c
public Cow(EntityType<? extends Cow> type, Level world) { public Cow(EntityType<? extends Cow> type, Level world) {
super(type, world); super(type, world);
@@ -64,6 +65,7 @@ public class Cow extends Animal { @@ -67,6 +68,7 @@ public class Cow extends Animal {
@Override @Override
public void initAttributes() { public void initAttributes() {
this.getAttribute(Attributes.MAX_HEALTH).setBaseValue(this.level().purpurConfig.cowMaxHealth); this.getAttribute(Attributes.MAX_HEALTH).setBaseValue(this.level().purpurConfig.cowMaxHealth);
@@ -24,7 +24,7 @@ index 8d714c029cf3b62af1ff8140a82ed3ae463e0e18..37f073e821a1b0f8efe89a7d88ce732c
} }
@Override @Override
@@ -76,11 +78,18 @@ public class Cow extends Animal { @@ -79,11 +81,18 @@ public class Cow extends Animal {
return this.level().purpurConfig.cowTakeDamageFromWater; return this.level().purpurConfig.cowTakeDamageFromWater;
} }
@@ -43,7 +43,7 @@ index 8d714c029cf3b62af1ff8140a82ed3ae463e0e18..37f073e821a1b0f8efe89a7d88ce732c
this.goalSelector.addGoal(2, new BreedGoal(this, 1.0D)); this.goalSelector.addGoal(2, new BreedGoal(this, 1.0D));
if (level().purpurConfig.cowFeedMushrooms > 0) this.goalSelector.addGoal(3, new TemptGoal(this, 1.25D, Ingredient.of(Items.WHEAT, Blocks.RED_MUSHROOM.asItem(), Blocks.BROWN_MUSHROOM.asItem()), false)); else // Purpur if (level().purpurConfig.cowFeedMushrooms > 0) this.goalSelector.addGoal(3, new TemptGoal(this, 1.25D, Ingredient.of(Items.WHEAT, Blocks.RED_MUSHROOM.asItem(), Blocks.BROWN_MUSHROOM.asItem()), false)); else // Purpur
this.goalSelector.addGoal(3, new TemptGoal(this, 1.25D, Ingredient.of(Items.WHEAT), false)); this.goalSelector.addGoal(3, new TemptGoal(this, 1.25D, Ingredient.of(Items.WHEAT), false));
@@ -88,10 +97,11 @@ public class Cow extends Animal { @@ -91,10 +100,11 @@ public class Cow extends Animal {
this.goalSelector.addGoal(5, new WaterAvoidingRandomStrollGoal(this, 1.0D)); this.goalSelector.addGoal(5, new WaterAvoidingRandomStrollGoal(this, 1.0D));
this.goalSelector.addGoal(6, new LookAtPlayerGoal(this, Player.class, 6.0F)); this.goalSelector.addGoal(6, new LookAtPlayerGoal(this, Player.class, 6.0F));
this.goalSelector.addGoal(7, new RandomLookAroundGoal(this)); this.goalSelector.addGoal(7, new RandomLookAroundGoal(this));
@@ -57,10 +57,10 @@ index 8d714c029cf3b62af1ff8140a82ed3ae463e0e18..37f073e821a1b0f8efe89a7d88ce732c
@Override @Override
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 80f7ae88760e6de74445271712929b3bdc2dda3c..1913ace7da1ba4beda5373d51a63ca7d3da7a564 100644 index c146356aa04126f2cd74aabf50c1436fa111aa6a..e752c2050b696a0f1db12c5301fbe940488d87d1 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -1230,7 +1230,14 @@ public class PurpurWorldConfig { @@ -1226,7 +1226,14 @@ public class PurpurWorldConfig {
public int cowFeedMushrooms = 0; public int cowFeedMushrooms = 0;
public int cowBreedingTicks = 6000; public int cowBreedingTicks = 6000;
public boolean cowTakeDamageFromWater = false; public boolean cowTakeDamageFromWater = false;
@@ -75,7 +75,7 @@ index 80f7ae88760e6de74445271712929b3bdc2dda3c..1913ace7da1ba4beda5373d51a63ca7d
cowRidable = getBoolean("mobs.cow.ridable", cowRidable); cowRidable = getBoolean("mobs.cow.ridable", cowRidable);
cowRidableInWater = getBoolean("mobs.cow.ridable-in-water", cowRidableInWater); cowRidableInWater = getBoolean("mobs.cow.ridable-in-water", cowRidableInWater);
cowControllable = getBoolean("mobs.cow.controllable", cowControllable); cowControllable = getBoolean("mobs.cow.controllable", cowControllable);
@@ -1243,6 +1250,8 @@ public class PurpurWorldConfig { @@ -1239,6 +1246,8 @@ public class PurpurWorldConfig {
cowFeedMushrooms = getInt("mobs.cow.feed-mushrooms-for-mooshroom", cowFeedMushrooms); cowFeedMushrooms = getInt("mobs.cow.feed-mushrooms-for-mooshroom", cowFeedMushrooms);
cowBreedingTicks = getInt("mobs.cow.breeding-delay-ticks", cowBreedingTicks); cowBreedingTicks = getInt("mobs.cow.breeding-delay-ticks", cowBreedingTicks);
cowTakeDamageFromWater = getBoolean("mobs.cow.takes-damage-from-water", cowTakeDamageFromWater); cowTakeDamageFromWater = getBoolean("mobs.cow.takes-damage-from-water", cowTakeDamageFromWater);

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Option for beds to explode on villager sleep
diff --git a/src/main/java/net/minecraft/world/entity/npc/Villager.java b/src/main/java/net/minecraft/world/entity/npc/Villager.java diff --git a/src/main/java/net/minecraft/world/entity/npc/Villager.java b/src/main/java/net/minecraft/world/entity/npc/Villager.java
index 444dbab9a1c95d1f8bc97e165e5302473a29c7e8..2ffceda6ce3cfe515f9348dafc28b04689d5a460 100644 index d24f970c50c1a4937b66e7eb6e3edc1d3b61a07e..bae27f98d3deaa855da9bc2dc6e8bd7d80fea786 100644
--- a/src/main/java/net/minecraft/world/entity/npc/Villager.java --- a/src/main/java/net/minecraft/world/entity/npc/Villager.java
+++ b/src/main/java/net/minecraft/world/entity/npc/Villager.java +++ b/src/main/java/net/minecraft/world/entity/npc/Villager.java
@@ -1110,6 +1110,12 @@ public class Villager extends AbstractVillager implements ReputationEventHandler @@ -1113,6 +1113,12 @@ public class Villager extends AbstractVillager implements ReputationEventHandler
@Override @Override
public void startSleeping(BlockPos pos) { public void startSleeping(BlockPos pos) {
@@ -22,10 +22,10 @@ index 444dbab9a1c95d1f8bc97e165e5302473a29c7e8..2ffceda6ce3cfe515f9348dafc28b046
this.brain.setMemory(MemoryModuleType.LAST_SLEPT, this.level().getGameTime()); // CraftBukkit - decompile error this.brain.setMemory(MemoryModuleType.LAST_SLEPT, this.level().getGameTime()); // CraftBukkit - decompile error
this.brain.eraseMemory(MemoryModuleType.WALK_TARGET); this.brain.eraseMemory(MemoryModuleType.WALK_TARGET);
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 1913ace7da1ba4beda5373d51a63ca7d3da7a564..af78db690b3d3437aedcb72bca76b01a4689921d 100644 index e752c2050b696a0f1db12c5301fbe940488d87d1..dae834b637164fabea2b17d2d752a04df31ee88a 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -758,6 +758,7 @@ public class PurpurWorldConfig { @@ -754,6 +754,7 @@ public class PurpurWorldConfig {
} }
public boolean bedExplode = true; public boolean bedExplode = true;
@@ -33,7 +33,7 @@ index 1913ace7da1ba4beda5373d51a63ca7d3da7a564..af78db690b3d3437aedcb72bca76b01a
public double bedExplosionPower = 5.0D; public double bedExplosionPower = 5.0D;
public boolean bedExplosionFire = true; public boolean bedExplosionFire = true;
public net.minecraft.world.level.Level.ExplosionInteraction bedExplosionEffect = net.minecraft.world.level.Level.ExplosionInteraction.BLOCK; public net.minecraft.world.level.Level.ExplosionInteraction bedExplosionEffect = net.minecraft.world.level.Level.ExplosionInteraction.BLOCK;
@@ -768,6 +769,7 @@ public class PurpurWorldConfig { @@ -764,6 +765,7 @@ public class PurpurWorldConfig {
} }
} }
bedExplode = getBoolean("blocks.bed.explode", bedExplode); bedExplode = getBoolean("blocks.bed.explode", bedExplode);

View File

@@ -5,7 +5,7 @@ Subject: [PATCH] Halloween options and optimizations
diff --git a/src/main/java/net/minecraft/world/entity/ambient/Bat.java b/src/main/java/net/minecraft/world/entity/ambient/Bat.java diff --git a/src/main/java/net/minecraft/world/entity/ambient/Bat.java b/src/main/java/net/minecraft/world/entity/ambient/Bat.java
index c3d1d77a5703db4e1e3eb38fdd0b8903f691bf25..c103c3da165ec4a9717400fdf278de2a667edd2a 100644 index 91c7295b75cee5b9fc18434b94a67cb8db0151e3..fb3fff24d0146711faf1cd5eba706004ce203618 100644
--- a/src/main/java/net/minecraft/world/entity/ambient/Bat.java --- a/src/main/java/net/minecraft/world/entity/ambient/Bat.java
+++ b/src/main/java/net/minecraft/world/entity/ambient/Bat.java +++ b/src/main/java/net/minecraft/world/entity/ambient/Bat.java
@@ -300,7 +300,7 @@ public class Bat extends AmbientCreature { @@ -300,7 +300,7 @@ public class Bat extends AmbientCreature {
@@ -17,16 +17,16 @@ index c3d1d77a5703db4e1e3eb38fdd0b8903f691bf25..c103c3da165ec4a9717400fdf278de2a
b0 = 7; b0 = 7;
} else if (random.nextBoolean()) { } else if (random.nextBoolean()) {
return false; return false;
@@ -314,6 +314,7 @@ public class Bat extends AmbientCreature { @@ -310,6 +310,7 @@ public class Bat extends AmbientCreature {
private static boolean isSpookySeason = false; }
private static final int ONE_HOUR = 20 * 60 * 60; }
private static int lastSpookyCheck = -ONE_HOUR;
+ public static boolean isHalloweenSeason(Level level) { return level.purpurConfig.forceHalloweenSeason || isHalloween(); } // Purpur + public static boolean isHalloweenSeason(Level level) { return level.purpurConfig.forceHalloweenSeason || isHalloween(); } // Purpur
private static boolean isHalloween() { private static boolean isHalloween() {
if (net.minecraft.server.MinecraftServer.currentTick - lastSpookyCheck > ONE_HOUR) {
LocalDate localdate = LocalDate.now(); LocalDate localdate = LocalDate.now();
int i = localdate.get(ChronoField.DAY_OF_MONTH);
diff --git a/src/main/java/net/minecraft/world/entity/monster/AbstractSkeleton.java b/src/main/java/net/minecraft/world/entity/monster/AbstractSkeleton.java diff --git a/src/main/java/net/minecraft/world/entity/monster/AbstractSkeleton.java b/src/main/java/net/minecraft/world/entity/monster/AbstractSkeleton.java
index 892ae3a9ac2395896ff7881c49eaece8d46e831e..41376b705748e14c1c4174e07732ce09ad8e581f 100644 index f35637a105d5aa12fb57c2456f2b2a7db12a49f0..f3e1fa62d9f067c0fe8aacb88bf30b01ee0562c1 100644
--- a/src/main/java/net/minecraft/world/entity/monster/AbstractSkeleton.java --- a/src/main/java/net/minecraft/world/entity/monster/AbstractSkeleton.java
+++ b/src/main/java/net/minecraft/world/entity/monster/AbstractSkeleton.java +++ b/src/main/java/net/minecraft/world/entity/monster/AbstractSkeleton.java
@@ -143,11 +143,7 @@ public abstract class AbstractSkeleton extends Monster implements RangedAttackMo @@ -143,11 +143,7 @@ public abstract class AbstractSkeleton extends Monster implements RangedAttackMo
@@ -43,10 +43,10 @@ index 892ae3a9ac2395896ff7881c49eaece8d46e831e..41376b705748e14c1c4174e07732ce09
this.armorDropChances[EquipmentSlot.HEAD.getIndex()] = 0.0F; this.armorDropChances[EquipmentSlot.HEAD.getIndex()] = 0.0F;
} }
diff --git a/src/main/java/net/minecraft/world/entity/monster/Zombie.java b/src/main/java/net/minecraft/world/entity/monster/Zombie.java diff --git a/src/main/java/net/minecraft/world/entity/monster/Zombie.java b/src/main/java/net/minecraft/world/entity/monster/Zombie.java
index 0bc90b6d5c5a3cb3477d41336a9bb1130ff32fa1..a8d2f8654ee370e98bb1c4e7e1111debd62a7429 100644 index 143ac5fac02a29516d03b69008b1345555857640..c265d2abd36857f6a25f8e0584e7cf939637b7a9 100644
--- a/src/main/java/net/minecraft/world/entity/monster/Zombie.java --- a/src/main/java/net/minecraft/world/entity/monster/Zombie.java
+++ b/src/main/java/net/minecraft/world/entity/monster/Zombie.java +++ b/src/main/java/net/minecraft/world/entity/monster/Zombie.java
@@ -593,11 +593,7 @@ public class Zombie extends Monster { @@ -594,11 +594,7 @@ public class Zombie extends Monster {
} }
if (this.getItemBySlot(EquipmentSlot.HEAD).isEmpty()) { if (this.getItemBySlot(EquipmentSlot.HEAD).isEmpty()) {
@@ -60,10 +60,10 @@ index 0bc90b6d5c5a3cb3477d41336a9bb1130ff32fa1..a8d2f8654ee370e98bb1c4e7e1111deb
this.armorDropChances[EquipmentSlot.HEAD.getIndex()] = 0.0F; this.armorDropChances[EquipmentSlot.HEAD.getIndex()] = 0.0F;
} }
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index af78db690b3d3437aedcb72bca76b01a4689921d..af6de9d4d6dace3f26b7012606d399f5c398ef0a 100644 index dae834b637164fabea2b17d2d752a04df31ee88a..9f3fe0265904da5a4be55fd3bc0ed1d283d241a9 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -1623,6 +1623,13 @@ public class PurpurWorldConfig { @@ -1619,6 +1619,13 @@ public class PurpurWorldConfig {
guardianTakeDamageFromWater = getBoolean("mobs.guardian.takes-damage-from-water", guardianTakeDamageFromWater); guardianTakeDamageFromWater = getBoolean("mobs.guardian.takes-damage-from-water", guardianTakeDamageFromWater);
} }

View File

@@ -5,7 +5,7 @@ Subject: [PATCH] Config for grindstones
diff --git a/src/main/java/net/minecraft/world/inventory/GrindstoneMenu.java b/src/main/java/net/minecraft/world/inventory/GrindstoneMenu.java diff --git a/src/main/java/net/minecraft/world/inventory/GrindstoneMenu.java b/src/main/java/net/minecraft/world/inventory/GrindstoneMenu.java
index b56766ff0e61691294b40ea8c2370940c0e8b640..6860e3467bf785e9d017fc98fce1e3cf71f9b6ee 100644 index a21eadcdfbdc4be803c5793bc97996db3e706071..132a07e226ae3ac6b5abc6f53c62345e2ab2f31f 100644
--- a/src/main/java/net/minecraft/world/inventory/GrindstoneMenu.java --- a/src/main/java/net/minecraft/world/inventory/GrindstoneMenu.java
+++ b/src/main/java/net/minecraft/world/inventory/GrindstoneMenu.java +++ b/src/main/java/net/minecraft/world/inventory/GrindstoneMenu.java
@@ -130,7 +130,7 @@ public class GrindstoneMenu extends AbstractContainerMenu { @@ -130,7 +130,7 @@ public class GrindstoneMenu extends AbstractContainerMenu {
@@ -57,7 +57,7 @@ index b56766ff0e61691294b40ea8c2370940c0e8b640..6860e3467bf785e9d017fc98fce1e3cf
} }
diff --git a/src/main/java/org/purpurmc/purpur/PurpurConfig.java b/src/main/java/org/purpurmc/purpur/PurpurConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurConfig.java b/src/main/java/org/purpurmc/purpur/PurpurConfig.java
index 853cf54077d760f1118ce494b401d286d789e5fc..19313ea70f105e71019947e34669384472b0aaab 100644 index 62fa79eccbb6f679c0460a6dfd457c405b3a8e67..f3449eb7a1433a8420c0de6f4649f0fae70b2294 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurConfig.java
@@ -309,6 +309,9 @@ public class PurpurConfig { @@ -309,6 +309,9 @@ public class PurpurConfig {

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] UPnP Port Forwarding
diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java
index 49286716235f3bd49cbc42ef693daafba746f930..3a9fe6d9f2e7406ffc368e2dadaab803b591f5c2 100644 index caaa154082fef69c6bf3ff6101242de5b037c583..5018f85fd87fe167389706bda04327bbe7d2c17a 100644
--- a/src/main/java/net/minecraft/server/MinecraftServer.java --- a/src/main/java/net/minecraft/server/MinecraftServer.java
+++ b/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java
@@ -308,6 +308,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa @@ -303,6 +303,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
public final io.papermc.paper.configuration.PaperConfigurations paperConfigurations; public final io.papermc.paper.configuration.PaperConfigurations paperConfigurations;
public static long currentTickLong = 0L; // Paper public static long currentTickLong = 0L; // Paper
public boolean lagging = false; // Purpur public boolean lagging = false; // Purpur
@@ -16,7 +16,7 @@ index 49286716235f3bd49cbc42ef693daafba746f930..3a9fe6d9f2e7406ffc368e2dadaab803
public volatile Thread shutdownThread; // Paper public volatile Thread shutdownThread; // Paper
public volatile boolean abnormalExit = false; // Paper public volatile boolean abnormalExit = false; // Paper
@@ -941,6 +942,14 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa @@ -924,6 +925,14 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
MinecraftServer.LOGGER.info("Stopping server"); MinecraftServer.LOGGER.info("Stopping server");
Commands.COMMAND_SENDING_POOL.shutdownNow(); // Paper - Shutdown and don't bother finishing Commands.COMMAND_SENDING_POOL.shutdownNow(); // Paper - Shutdown and don't bother finishing
MinecraftTimings.stopServer(); // Paper MinecraftTimings.stopServer(); // Paper
@@ -32,10 +32,10 @@ index 49286716235f3bd49cbc42ef693daafba746f930..3a9fe6d9f2e7406ffc368e2dadaab803
if (this.server != null) { if (this.server != null) {
this.server.disablePlugins(); this.server.disablePlugins();
diff --git a/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java b/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java diff --git a/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java b/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java
index 8089e9ff60c6f7a5f06bbb46b53b07d6a588cea3..c8902e2783026c85eaf0c16541adf67173ed4058 100644 index f7e15e75333ae24ab97483aedccb60bb631a506d..2075f8f6096178930708268d0c4e2862824cbc45 100644
--- a/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java --- a/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java
+++ b/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java +++ b/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java
@@ -278,6 +278,30 @@ public class DedicatedServer extends MinecraftServer implements ServerInterface @@ -276,6 +276,30 @@ public class DedicatedServer extends MinecraftServer implements ServerInterface
DedicatedServer.LOGGER.warn("Perhaps a server is already running on that port?"); DedicatedServer.LOGGER.warn("Perhaps a server is already running on that port?");
return false; return false;
} }

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Campfire option for lit when placed
diff --git a/src/main/java/net/minecraft/world/level/block/CampfireBlock.java b/src/main/java/net/minecraft/world/level/block/CampfireBlock.java diff --git a/src/main/java/net/minecraft/world/level/block/CampfireBlock.java b/src/main/java/net/minecraft/world/level/block/CampfireBlock.java
index 219c87dcf065e86512f330fbeec59e55f4675083..f8fd3b320494d1c1e8ee3d170f2feebd152230fa 100644 index 7700461b8cd0bde1bf6c0d5e4b73184bed1adc4e..cfa02b274286374c7555919d0e8d66a2c8fb8b88 100644
--- a/src/main/java/net/minecraft/world/level/block/CampfireBlock.java --- a/src/main/java/net/minecraft/world/level/block/CampfireBlock.java
+++ b/src/main/java/net/minecraft/world/level/block/CampfireBlock.java +++ b/src/main/java/net/minecraft/world/level/block/CampfireBlock.java
@@ -122,7 +122,7 @@ public class CampfireBlock extends BaseEntityBlock implements SimpleWaterloggedB @@ -123,7 +123,7 @@ public class CampfireBlock extends BaseEntityBlock implements SimpleWaterloggedB
BlockPos blockposition = ctx.getClickedPos(); BlockPos blockposition = ctx.getClickedPos();
boolean flag = world.getFluidState(blockposition).getType() == Fluids.WATER; boolean flag = world.getFluidState(blockposition).getType() == Fluids.WATER;
@@ -18,10 +18,10 @@ index 219c87dcf065e86512f330fbeec59e55f4675083..f8fd3b320494d1c1e8ee3d170f2feebd
@Override @Override
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index af6de9d4d6dace3f26b7012606d399f5c398ef0a..002074c521209190fcdf9f3d7ebbbfdc2fa8c8f5 100644 index 9f3fe0265904da5a4be55fd3bc0ed1d283d241a9..19684e9d59f57d587818dcf5debd4873944298bf 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -801,6 +801,11 @@ public class PurpurWorldConfig { @@ -797,6 +797,11 @@ public class PurpurWorldConfig {
cactusBreaksFromSolidNeighbors = getBoolean("blocks.cactus.breaks-from-solid-neighbors", cactusBreaksFromSolidNeighbors); cactusBreaksFromSolidNeighbors = getBoolean("blocks.cactus.breaks-from-solid-neighbors", cactusBreaksFromSolidNeighbors);
} }

View File

@@ -46,7 +46,7 @@ index b90cedad282e95a067aca176fafa9f72a726f520..440d3d72d8b2dac14f83a83caa5ae9db
protected void onHit(HitResult hitResult) { protected void onHit(HitResult hitResult) {
super.onHit(hitResult); super.onHit(hitResult);
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 002074c521209190fcdf9f3d7ebbbfdc2fa8c8f5..dc4e59fab1f89379dfce02d6090ed8e700aaa145 100644 index 19684e9d59f57d587818dcf5debd4873944298bf..51350d67992bba19be24bfbc75968cae29ca5d98 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -231,6 +231,9 @@ public class PurpurWorldConfig { @@ -231,6 +231,9 @@ public class PurpurWorldConfig {

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Add option to disable zombie villagers cure
diff --git a/src/main/java/net/minecraft/world/entity/monster/ZombieVillager.java b/src/main/java/net/minecraft/world/entity/monster/ZombieVillager.java diff --git a/src/main/java/net/minecraft/world/entity/monster/ZombieVillager.java b/src/main/java/net/minecraft/world/entity/monster/ZombieVillager.java
index 40b3498c57c62f8bdaac50546ca47f4927db7bfa..b8e0ae0714fd2b77831fb714b1bad901e7081cf4 100644 index ecf41531855e1f60d9739ac6d2d82df7794f072f..4bac02d30ec28ea0bce069f0f915b660b99b122d 100644
--- a/src/main/java/net/minecraft/world/entity/monster/ZombieVillager.java --- a/src/main/java/net/minecraft/world/entity/monster/ZombieVillager.java
+++ b/src/main/java/net/minecraft/world/entity/monster/ZombieVillager.java +++ b/src/main/java/net/minecraft/world/entity/monster/ZombieVillager.java
@@ -212,7 +212,7 @@ public class ZombieVillager extends Zombie implements VillagerDataHolder { @@ -215,7 +215,7 @@ public class ZombieVillager extends Zombie implements VillagerDataHolder {
ItemStack itemstack = player.getItemInHand(hand); ItemStack itemstack = player.getItemInHand(hand);
if (itemstack.is(Items.GOLDEN_APPLE)) { if (itemstack.is(Items.GOLDEN_APPLE)) {
@@ -18,10 +18,10 @@ index 40b3498c57c62f8bdaac50546ca47f4927db7bfa..b8e0ae0714fd2b77831fb714b1bad901
itemstack.shrink(1); itemstack.shrink(1);
} }
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index dc4e59fab1f89379dfce02d6090ed8e700aaa145..ad07b4769487f8f4709bea1691b95738cd58aa41 100644 index 51350d67992bba19be24bfbc75968cae29ca5d98..cbf30293766899b7aa66dc922ba76395feca1094 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -2840,6 +2840,7 @@ public class PurpurWorldConfig { @@ -2836,6 +2836,7 @@ public class PurpurWorldConfig {
public boolean zombieVillagerTakeDamageFromWater = false; public boolean zombieVillagerTakeDamageFromWater = false;
public int zombieVillagerCuringTimeMin = 3600; public int zombieVillagerCuringTimeMin = 3600;
public int zombieVillagerCuringTimeMax = 6000; public int zombieVillagerCuringTimeMax = 6000;
@@ -29,7 +29,7 @@ index dc4e59fab1f89379dfce02d6090ed8e700aaa145..ad07b4769487f8f4709bea1691b95738
private void zombieVillagerSettings() { private void zombieVillagerSettings() {
zombieVillagerRidable = getBoolean("mobs.zombie_villager.ridable", zombieVillagerRidable); zombieVillagerRidable = getBoolean("mobs.zombie_villager.ridable", zombieVillagerRidable);
zombieVillagerRidableInWater = getBoolean("mobs.zombie_villager.ridable-in-water", zombieVillagerRidableInWater); zombieVillagerRidableInWater = getBoolean("mobs.zombie_villager.ridable-in-water", zombieVillagerRidableInWater);
@@ -2857,6 +2858,7 @@ public class PurpurWorldConfig { @@ -2853,6 +2854,7 @@ public class PurpurWorldConfig {
zombieVillagerTakeDamageFromWater = getBoolean("mobs.zombie_villager.takes-damage-from-water", zombieVillagerTakeDamageFromWater); zombieVillagerTakeDamageFromWater = getBoolean("mobs.zombie_villager.takes-damage-from-water", zombieVillagerTakeDamageFromWater);
zombieVillagerCuringTimeMin = getInt("mobs.zombie_villager.curing_time.min", zombieVillagerCuringTimeMin); zombieVillagerCuringTimeMin = getInt("mobs.zombie_villager.curing_time.min", zombieVillagerCuringTimeMin);
zombieVillagerCuringTimeMax = getInt("mobs.zombie_villager.curing_time.max", zombieVillagerCuringTimeMax); zombieVillagerCuringTimeMax = getInt("mobs.zombie_villager.curing_time.max", zombieVillagerCuringTimeMax);

View File

@@ -7,7 +7,7 @@ Makes it so that when a BlockEntity is placed in the world and then broken,
the dropped ItemStack retains any original custom display name/lore. the dropped ItemStack retains any original custom display name/lore.
diff --git a/src/main/java/net/minecraft/world/item/BlockItem.java b/src/main/java/net/minecraft/world/item/BlockItem.java diff --git a/src/main/java/net/minecraft/world/item/BlockItem.java b/src/main/java/net/minecraft/world/item/BlockItem.java
index dc45899a677cef389fca23938e201daeaafaa4a3..3802025f4739b7cb58bd039f52ce2744ebe6f345 100644 index ec58193ebd73130f14dc5d8f51caa913b2036fc5..41728bcbd5ca3585da64f7c3289b26977f90c229 100644
--- a/src/main/java/net/minecraft/world/item/BlockItem.java --- a/src/main/java/net/minecraft/world/item/BlockItem.java
+++ b/src/main/java/net/minecraft/world/item/BlockItem.java +++ b/src/main/java/net/minecraft/world/item/BlockItem.java
@@ -153,7 +153,24 @@ public class BlockItem extends Item { @@ -153,7 +153,24 @@ public class BlockItem extends Item {
@@ -37,7 +37,7 @@ index dc45899a677cef389fca23938e201daeaafaa4a3..3802025f4739b7cb58bd039f52ce2744
@Nullable @Nullable
diff --git a/src/main/java/net/minecraft/world/level/block/Block.java b/src/main/java/net/minecraft/world/level/block/Block.java diff --git a/src/main/java/net/minecraft/world/level/block/Block.java b/src/main/java/net/minecraft/world/level/block/Block.java
index 48682f0ebec49a04e36f96423cda483a6736fd24..69c78ee2d012344505063c9b297c9c550bde80c4 100644 index f65b54919d19d2ddc7261cc36853babbaef3c822..cee9e07a250ed61570cf9787236308f91724f02f 100644
--- a/src/main/java/net/minecraft/world/level/block/Block.java --- a/src/main/java/net/minecraft/world/level/block/Block.java
+++ b/src/main/java/net/minecraft/world/level/block/Block.java +++ b/src/main/java/net/minecraft/world/level/block/Block.java
@@ -62,6 +62,13 @@ import net.minecraft.world.phys.shapes.Shapes; @@ -62,6 +62,13 @@ import net.minecraft.world.phys.shapes.Shapes;
@@ -195,7 +195,7 @@ index 370a25d2deb54f10a35ee24d9e7e92fbfde60edf..2f19f6ac5de454845f5d13a3ebb93af6
+ // Purpur end + // Purpur end
} }
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index ad07b4769487f8f4709bea1691b95738cd58aa41..33f0396c06e1063acb11b8e283b9cb6e6509b821 100644 index cbf30293766899b7aa66dc922ba76395feca1094..0f8384ba3bb9b6f36bb36bf833c260076b49014e 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -130,6 +130,7 @@ public class PurpurWorldConfig { @@ -130,6 +130,7 @@ public class PurpurWorldConfig {

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Signs allow color codes
diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java
index cc313235863910b4978f96d594abff0a20c13e18..01f001c39581c4af5765548e221e254465fe0195 100644 index 3e08dcd1a46adc6ef769f2cfc85970ad9cbbdd10..4f9796dfb1243befb6fa41b4fd633951a4bf0fc6 100644
--- a/src/main/java/net/minecraft/server/level/ServerPlayer.java --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java
+++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java
@@ -1583,6 +1583,7 @@ public class ServerPlayer extends Player { @@ -1576,6 +1576,7 @@ public class ServerPlayer extends Player {
@Override @Override
public void openTextEdit(SignBlockEntity sign, boolean front) { public void openTextEdit(SignBlockEntity sign, boolean front) {
@@ -84,10 +84,10 @@ index 38cde466714e5663cd416b6afd5d2558e139ec09..2d625f18f2ba42ee5a1ebeea78ca395a
public CompoundTag getUpdateTag() { public CompoundTag getUpdateTag() {
return this.saveWithoutMetadata(); return this.saveWithoutMetadata();
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 33f0396c06e1063acb11b8e283b9cb6e6509b821..0a43e97fa389cdfd3a542c25878f28afb88d15b7 100644 index 0f8384ba3bb9b6f36bb36bf833c260076b49014e..3d07df1fbe7116df6f97a2fb3931e739c38b671e 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -981,6 +981,11 @@ public class PurpurWorldConfig { @@ -977,6 +977,11 @@ public class PurpurWorldConfig {
shulkerBoxAllowOversizedStacks = getBoolean("blocks.shulker_box.allow-oversized-stacks", shulkerBoxAllowOversizedStacks); shulkerBoxAllowOversizedStacks = getBoolean("blocks.shulker_box.allow-oversized-stacks", shulkerBoxAllowOversizedStacks);
} }

View File

@@ -6,7 +6,7 @@ Subject: [PATCH] Kelp, cave, weeping, and twisting vines configurable max
diff --git a/src/main/java/net/minecraft/world/level/block/CaveVinesBlock.java b/src/main/java/net/minecraft/world/level/block/CaveVinesBlock.java diff --git a/src/main/java/net/minecraft/world/level/block/CaveVinesBlock.java b/src/main/java/net/minecraft/world/level/block/CaveVinesBlock.java
index 18b5bce1138d50be32e5da013221be69dc47e21f..58b4a0d97af37f7164db86ef821f04102c6c5ddd 100644 index ead7b37122c76d43af2cdd17af7f0da8014efb26..1acc2dcda68ec8e462d51927f2ea985e7952a830 100644
--- a/src/main/java/net/minecraft/world/level/block/CaveVinesBlock.java --- a/src/main/java/net/minecraft/world/level/block/CaveVinesBlock.java
+++ b/src/main/java/net/minecraft/world/level/block/CaveVinesBlock.java +++ b/src/main/java/net/minecraft/world/level/block/CaveVinesBlock.java
@@ -88,4 +88,11 @@ public class CaveVinesBlock extends GrowingPlantHeadBlock implements Bonemealabl @@ -88,4 +88,11 @@ public class CaveVinesBlock extends GrowingPlantHeadBlock implements Bonemealabl
@@ -22,7 +22,7 @@ index 18b5bce1138d50be32e5da013221be69dc47e21f..58b4a0d97af37f7164db86ef821f0410
+ // Purpur end + // Purpur end
} }
diff --git a/src/main/java/net/minecraft/world/level/block/GrowingPlantHeadBlock.java b/src/main/java/net/minecraft/world/level/block/GrowingPlantHeadBlock.java diff --git a/src/main/java/net/minecraft/world/level/block/GrowingPlantHeadBlock.java b/src/main/java/net/minecraft/world/level/block/GrowingPlantHeadBlock.java
index 3a1aa4e2405090ccebefb7f5944f36462929e221..f3cf9f06de40054720d1847c1869a9d82592134d 100644 index b325fdec8eb99ce57152a5c0fefa5059685276e4..c93e60b01dd46e7de6a6b5a5149a522304f28178 100644
--- a/src/main/java/net/minecraft/world/level/block/GrowingPlantHeadBlock.java --- a/src/main/java/net/minecraft/world/level/block/GrowingPlantHeadBlock.java
+++ b/src/main/java/net/minecraft/world/level/block/GrowingPlantHeadBlock.java +++ b/src/main/java/net/minecraft/world/level/block/GrowingPlantHeadBlock.java
@@ -30,12 +30,12 @@ public abstract class GrowingPlantHeadBlock extends GrowingPlantBlock implements @@ -30,12 +30,12 @@ public abstract class GrowingPlantHeadBlock extends GrowingPlantBlock implements
@@ -87,10 +87,10 @@ index 3a1aa4e2405090ccebefb7f5944f36462929e221..f3cf9f06de40054720d1847c1869a9d8
+ public abstract int getMaxGrowthAge(); // Purpur + public abstract int getMaxGrowthAge(); // Purpur
} }
diff --git a/src/main/java/net/minecraft/world/level/block/KelpBlock.java b/src/main/java/net/minecraft/world/level/block/KelpBlock.java diff --git a/src/main/java/net/minecraft/world/level/block/KelpBlock.java b/src/main/java/net/minecraft/world/level/block/KelpBlock.java
index bc66fa91ec3e13431d5d9b6e17935cab73066be7..0f16b5ed2e249f3d8f583dc941e32066d354cf95 100644 index ff30a93f4160e8e22b40c7a7033c14fa15839160..bf043e1b9f0ec5876a2fa2d0597ec3c60b32b2c0 100644
--- a/src/main/java/net/minecraft/world/level/block/KelpBlock.java --- a/src/main/java/net/minecraft/world/level/block/KelpBlock.java
+++ b/src/main/java/net/minecraft/world/level/block/KelpBlock.java +++ b/src/main/java/net/minecraft/world/level/block/KelpBlock.java
@@ -64,4 +64,11 @@ public class KelpBlock extends GrowingPlantHeadBlock implements LiquidBlockConta @@ -65,4 +65,11 @@ public class KelpBlock extends GrowingPlantHeadBlock implements LiquidBlockConta
public FluidState getFluidState(BlockState state) { public FluidState getFluidState(BlockState state) {
return Fluids.WATER.getSource(false); return Fluids.WATER.getSource(false);
} }
@@ -135,7 +135,7 @@ index e5c135ec059746b75fe58516809584221285cdbe..713c7e6e31a3e1097b612c77a4fce147
+ // Purpur end + // Purpur end
} }
diff --git a/src/main/java/org/purpurmc/purpur/PurpurConfig.java b/src/main/java/org/purpurmc/purpur/PurpurConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurConfig.java b/src/main/java/org/purpurmc/purpur/PurpurConfig.java
index 37764d22804fecf704963d3208039834f1525b0d..b359b106f51e68d8a1e59d40dff75d656cd3b6e4 100644 index f6cd1c56dcc3f7d118edc6d7a63e42da166ebd5f..f562729f543ef2b5998c6c38c0a08b3ae4dab1bf 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurConfig.java
@@ -312,6 +312,10 @@ public class PurpurConfig { @@ -312,6 +312,10 @@ public class PurpurConfig {

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Potion NamespacedKey
diff --git a/src/main/java/net/minecraft/world/effect/MobEffectInstance.java b/src/main/java/net/minecraft/world/effect/MobEffectInstance.java diff --git a/src/main/java/net/minecraft/world/effect/MobEffectInstance.java b/src/main/java/net/minecraft/world/effect/MobEffectInstance.java
index 14fab63346d56c72cd7534a04760efd10eef4295..745e792482f61c571e2efbd4200dd1bdaef6e474 100644 index 68e1b8271475996020af50b3b2cf04cd25aa6c85..4f2fcbcf90d6f5ee89e35c993a65cae6c5b7ed91 100644
--- a/src/main/java/net/minecraft/world/effect/MobEffectInstance.java --- a/src/main/java/net/minecraft/world/effect/MobEffectInstance.java
+++ b/src/main/java/net/minecraft/world/effect/MobEffectInstance.java +++ b/src/main/java/net/minecraft/world/effect/MobEffectInstance.java
@@ -14,6 +14,7 @@ import net.minecraft.util.ExtraCodecs; @@ -16,6 +16,7 @@ import net.minecraft.util.ExtraCodecs;
import net.minecraft.util.Mth; import net.minecraft.util.Mth;
import net.minecraft.world.entity.LivingEntity; import net.minecraft.world.entity.LivingEntity;
import org.slf4j.Logger; import org.slf4j.Logger;
@@ -16,7 +16,7 @@ index 14fab63346d56c72cd7534a04760efd10eef4295..745e792482f61c571e2efbd4200dd1bd
public class MobEffectInstance implements Comparable<MobEffectInstance> { public class MobEffectInstance implements Comparable<MobEffectInstance> {
private static final Logger LOGGER = LogUtils.getLogger(); private static final Logger LOGGER = LogUtils.getLogger();
@@ -25,6 +26,7 @@ public class MobEffectInstance implements Comparable<MobEffectInstance> { @@ -35,6 +36,7 @@ public class MobEffectInstance implements Comparable<MobEffectInstance> {
private boolean visible; private boolean visible;
private boolean showIcon; private boolean showIcon;
@Nullable @Nullable
@@ -24,7 +24,7 @@ index 14fab63346d56c72cd7534a04760efd10eef4295..745e792482f61c571e2efbd4200dd1bd
private MobEffectInstance hiddenEffect; private MobEffectInstance hiddenEffect;
private final Optional<MobEffectInstance.FactorData> factorData; private final Optional<MobEffectInstance.FactorData> factorData;
@@ -44,17 +46,36 @@ public class MobEffectInstance implements Comparable<MobEffectInstance> { @@ -54,17 +56,36 @@ public class MobEffectInstance implements Comparable<MobEffectInstance> {
this(type, duration, amplifier, ambient, visible, visible); this(type, duration, amplifier, ambient, visible, visible);
} }
@@ -62,7 +62,7 @@ index 14fab63346d56c72cd7534a04760efd10eef4295..745e792482f61c571e2efbd4200dd1bd
this.hiddenEffect = hiddenEffect; this.hiddenEffect = hiddenEffect;
this.factorData = factorCalculationData; this.factorData = factorCalculationData;
} }
@@ -75,6 +96,7 @@ public class MobEffectInstance implements Comparable<MobEffectInstance> { @@ -85,6 +106,7 @@ public class MobEffectInstance implements Comparable<MobEffectInstance> {
this.ambient = that.ambient; this.ambient = that.ambient;
this.visible = that.visible; this.visible = that.visible;
this.showIcon = that.showIcon; this.showIcon = that.showIcon;
@@ -70,7 +70,7 @@ index 14fab63346d56c72cd7534a04760efd10eef4295..745e792482f61c571e2efbd4200dd1bd
} }
public boolean update(MobEffectInstance that) { public boolean update(MobEffectInstance that) {
@@ -120,6 +142,13 @@ public class MobEffectInstance implements Comparable<MobEffectInstance> { @@ -129,6 +151,13 @@ public class MobEffectInstance implements Comparable<MobEffectInstance> {
bl = true; bl = true;
} }
@@ -84,7 +84,7 @@ index 14fab63346d56c72cd7534a04760efd10eef4295..745e792482f61c571e2efbd4200dd1bd
return bl; return bl;
} }
@@ -163,6 +192,17 @@ public class MobEffectInstance implements Comparable<MobEffectInstance> { @@ -172,6 +201,17 @@ public class MobEffectInstance implements Comparable<MobEffectInstance> {
return this.showIcon; return this.showIcon;
} }
@@ -102,7 +102,7 @@ index 14fab63346d56c72cd7534a04760efd10eef4295..745e792482f61c571e2efbd4200dd1bd
public boolean tick(LivingEntity entity, Runnable overwriteCallback) { public boolean tick(LivingEntity entity, Runnable overwriteCallback) {
if (this.hasRemainingDuration()) { if (this.hasRemainingDuration()) {
int i = this.isInfiniteDuration() ? entity.tickCount : this.duration; int i = this.isInfiniteDuration() ? entity.tickCount : this.duration;
@@ -226,6 +266,12 @@ public class MobEffectInstance implements Comparable<MobEffectInstance> { @@ -232,6 +272,12 @@ public class MobEffectInstance implements Comparable<MobEffectInstance> {
string = string + ", Show Icon: false"; string = string + ", Show Icon: false";
} }
@@ -115,7 +115,7 @@ index 14fab63346d56c72cd7534a04760efd10eef4295..745e792482f61c571e2efbd4200dd1bd
return string; return string;
} }
@@ -241,7 +287,7 @@ public class MobEffectInstance implements Comparable<MobEffectInstance> { @@ -247,7 +293,7 @@ public class MobEffectInstance implements Comparable<MobEffectInstance> {
return false; return false;
} else { } else {
MobEffectInstance mobEffectInstance = (MobEffectInstance)object; MobEffectInstance mobEffectInstance = (MobEffectInstance)object;
@@ -124,33 +124,33 @@ index 14fab63346d56c72cd7534a04760efd10eef4295..745e792482f61c571e2efbd4200dd1bd
} }
} }
@@ -265,6 +311,11 @@ public class MobEffectInstance implements Comparable<MobEffectInstance> { @@ -272,6 +318,11 @@ public class MobEffectInstance implements Comparable<MobEffectInstance> {
nbt.putBoolean("Ambient", this.isAmbient()); nbt.putBoolean("ambient", this.isAmbient());
nbt.putBoolean("ShowParticles", this.isVisible()); nbt.putBoolean("show_particles", this.isVisible());
nbt.putBoolean("ShowIcon", this.showIcon()); nbt.putBoolean("show_icon", this.showIcon());
+ // Purpur start + // Purpur start
+ if (this.key != null) { + if (this.key != null) {
+ nbt.putString("Key", this.key.toString()); + nbt.putString("key", this.key.toString());
+ } + }
+ // Purpur end + // Purpur end
if (this.hiddenEffect != null) { if (this.hiddenEffect != null) {
CompoundTag compoundTag = new CompoundTag(); CompoundTag compoundTag = new CompoundTag();
this.hiddenEffect.save(compoundTag); this.hiddenEffect.save(compoundTag);
@@ -299,6 +350,13 @@ public class MobEffectInstance implements Comparable<MobEffectInstance> { @@ -306,6 +357,13 @@ public class MobEffectInstance implements Comparable<MobEffectInstance> {
bl3 = nbt.getBoolean("ShowIcon"); bl3 = nbt.getBoolean("show_icon");
} }
+ // Purpur start + // Purpur start
+ NamespacedKey key = null; + NamespacedKey key = null;
+ if (nbt.contains("Key")) { + if (nbt.contains("key")) {
+ key = NamespacedKey.fromString(nbt.getString("Key")); + key = NamespacedKey.fromString(nbt.getString("key"));
+ } + }
+ // Purpur end + // Purpur end
+ +
MobEffectInstance mobEffectInstance = null; MobEffectInstance mobEffectInstance = null;
if (nbt.contains("HiddenEffect", 10)) { if (nbt.contains("hidden_effect", 10)) {
mobEffectInstance = loadSpecifiedEffect(type, nbt.getCompound("HiddenEffect")); mobEffectInstance = loadSpecifiedEffect(type, nbt.getCompound("hidden_effect"));
@@ -311,7 +369,7 @@ public class MobEffectInstance implements Comparable<MobEffectInstance> { @@ -318,7 +376,7 @@ public class MobEffectInstance implements Comparable<MobEffectInstance> {
optional = Optional.empty(); optional = Optional.empty();
} }
@@ -160,24 +160,24 @@ index 14fab63346d56c72cd7534a04760efd10eef4295..745e792482f61c571e2efbd4200dd1bd
@Override @Override
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java
index 72dcac5708c06556549d268e54ecb4b6e71c93be..7f1c7532adace841baec500598133981a6feb78a 100644 index a6934034c9fc8e3f04365d7595fccbe68fc093b6..5ca34447926510f1d4c5c5ba9eb3c7c6369a85de 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java
@@ -465,7 +465,7 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { @@ -465,7 +465,7 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity {
@Override @Override
public boolean addPotionEffect(PotionEffect effect, boolean force) { public boolean addPotionEffect(PotionEffect effect, boolean force) {
org.spigotmc.AsyncCatcher.catchOp("effect add"); // Paper org.spigotmc.AsyncCatcher.catchOp("effect add"); // Paper
- this.getHandle().addEffect(new MobEffectInstance(MobEffect.byId(effect.getType().getId()), effect.getDuration(), effect.getAmplifier(), effect.isAmbient(), effect.hasParticles(), effect.hasIcon()), EntityPotionEffectEvent.Cause.PLUGIN); // Paper - Don't ignore icon - this.getHandle().addEffect(new MobEffectInstance(CraftPotionEffectType.bukkitToMinecraft(effect.getType()), effect.getDuration(), effect.getAmplifier(), effect.isAmbient(), effect.hasParticles(), effect.hasIcon()), EntityPotionEffectEvent.Cause.PLUGIN); // Paper - Don't ignore icon
+ this.getHandle().addEffect(new MobEffectInstance(MobEffect.byId(effect.getType().getId()), effect.getDuration(), effect.getAmplifier(), effect.isAmbient(), effect.hasParticles(), effect.hasIcon(), effect.getKey()), EntityPotionEffectEvent.Cause.PLUGIN); // Purpur - add key // Paper - Don't ignore icon + this.getHandle().addEffect(new MobEffectInstance(CraftPotionEffectType.bukkitToMinecraft(effect.getType()), effect.getDuration(), effect.getAmplifier(), effect.isAmbient(), effect.hasParticles(), effect.hasIcon(), effect.getKey()), EntityPotionEffectEvent.Cause.PLUGIN); // Purpur - add key // Paper - Don't ignore icon
return true; return true;
} }
@@ -486,7 +486,7 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { @@ -486,7 +486,7 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity {
@Override @Override
public PotionEffect getPotionEffect(PotionEffectType type) { public PotionEffect getPotionEffect(PotionEffectType type) {
MobEffectInstance handle = this.getHandle().getEffect(MobEffect.byId(type.getId())); MobEffectInstance handle = this.getHandle().getEffect(CraftPotionEffectType.bukkitToMinecraft(type));
- return (handle == null) ? null : new PotionEffect(PotionEffectType.getById(MobEffect.getId(handle.getEffect())), handle.getDuration(), handle.getAmplifier(), handle.isAmbient(), handle.isVisible()); - return (handle == null) ? null : new PotionEffect(CraftPotionEffectType.minecraftToBukkit(handle.getEffect()), handle.getDuration(), handle.getAmplifier(), handle.isAmbient(), handle.isVisible());
+ return (handle == null) ? null : new PotionEffect(PotionEffectType.getById(MobEffect.getId(handle.getEffect())), handle.getDuration(), handle.getAmplifier(), handle.isAmbient(), handle.isVisible(), handle.getKey()); // Purpur - add key + return (handle == null) ? null : new PotionEffect(CraftPotionEffectType.minecraftToBukkit(handle.getEffect()), handle.getDuration(), handle.getAmplifier(), handle.isAmbient(), handle.isVisible(), handle.getKey()); // Purpur - add key
} }
@Override @Override
@@ -185,32 +185,24 @@ index 72dcac5708c06556549d268e54ecb4b6e71c93be..7f1c7532adace841baec500598133981
public Collection<PotionEffect> getActivePotionEffects() { public Collection<PotionEffect> getActivePotionEffects() {
List<PotionEffect> effects = new ArrayList<PotionEffect>(); List<PotionEffect> effects = new ArrayList<PotionEffect>();
for (MobEffectInstance handle : this.getHandle().activeEffects.values()) { for (MobEffectInstance handle : this.getHandle().activeEffects.values()) {
- effects.add(new PotionEffect(PotionEffectType.getById(MobEffect.getId(handle.getEffect())), handle.getDuration(), handle.getAmplifier(), handle.isAmbient(), handle.isVisible())); - effects.add(new PotionEffect(CraftPotionEffectType.minecraftToBukkit(handle.getEffect()), handle.getDuration(), handle.getAmplifier(), handle.isAmbient(), handle.isVisible()));
+ effects.add(new PotionEffect(PotionEffectType.getById(MobEffect.getId(handle.getEffect())), handle.getDuration(), handle.getAmplifier(), handle.isAmbient(), handle.isVisible(), handle.getKey())); // Purpur - add key + effects.add(new PotionEffect(CraftPotionEffectType.minecraftToBukkit(handle.getEffect()), handle.getDuration(), handle.getAmplifier(), handle.isAmbient(), handle.isVisible()), handle.getKey()); // Purpur - add key
} }
return effects; return effects;
} }
diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaPotion.java b/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaPotion.java diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaPotion.java b/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaPotion.java
index d94ab2607d1ab657a6b37924ce5ebcbbc3984011..f594596029513426f974ba820ed4702703b667a4 100644 index 5a71efd27180004ee91495d9255867dbdfa1783e..1dcc3405393d11836a21aa16e435be64c04f6e7d 100644
--- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaPotion.java --- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaPotion.java
+++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaPotion.java +++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaPotion.java
@@ -13,6 +13,7 @@ import net.minecraft.nbt.CompoundTag; @@ -43,6 +43,7 @@ class CraftMetaPotion extends CraftMetaItem implements PotionMeta {
import net.minecraft.nbt.ListTag;
import org.bukkit.Color;
import org.bukkit.Material;
+import org.bukkit.NamespacedKey;
import org.bukkit.configuration.serialization.DelegateDeserialization;
import org.bukkit.craftbukkit.inventory.CraftMetaItem.SerializableMeta;
import org.bukkit.craftbukkit.potion.CraftPotionUtil;
@@ -42,6 +43,7 @@ class CraftMetaPotion extends CraftMetaItem implements PotionMeta {
static final ItemMetaKey POTION_COLOR = new ItemMetaKey("CustomPotionColor", "custom-color"); static final ItemMetaKey POTION_COLOR = new ItemMetaKey("CustomPotionColor", "custom-color");
static final ItemMetaKey ID = new ItemMetaKey("Id", "potion-id"); static final ItemMetaKey ID = new ItemMetaKey("id", "potion-id");
static final ItemMetaKey DEFAULT_POTION = new ItemMetaKey("Potion", "potion-type"); static final ItemMetaKey DEFAULT_POTION = new ItemMetaKey("Potion", "potion-type");
+ static final ItemMetaKey KEY = new ItemMetaKey("Key", "namespacedkey"); // Purpur - add key + static final ItemMetaKey KEY = new ItemMetaKey("key", "namespacedkey"); // Purpur - add key
// Having an initial "state" in ItemMeta seems bit dirty but the UNCRAFTABLE potion type // Having an initial "state" in ItemMeta seems bit dirty but the UNCRAFTABLE potion type
// is treated as the empty form of the meta because it represents an empty potion with no effect // is treated as the empty form of the meta because it represents an empty potion with no effect
@@ -91,7 +93,13 @@ class CraftMetaPotion extends CraftMetaItem implements PotionMeta { @@ -92,7 +93,13 @@ class CraftMetaPotion extends CraftMetaItem implements PotionMeta {
boolean ambient = effect.getBoolean(AMBIENT.NBT); boolean ambient = effect.getBoolean(AMBIENT.NBT);
boolean particles = effect.contains(SHOW_PARTICLES.NBT, CraftMagicNumbers.NBT.TAG_BYTE) ? effect.getBoolean(SHOW_PARTICLES.NBT) : true; boolean particles = effect.contains(SHOW_PARTICLES.NBT, CraftMagicNumbers.NBT.TAG_BYTE) ? effect.getBoolean(SHOW_PARTICLES.NBT) : true;
boolean icon = effect.contains(SHOW_ICON.NBT, CraftMagicNumbers.NBT.TAG_BYTE) ? effect.getBoolean(SHOW_ICON.NBT) : particles; boolean icon = effect.contains(SHOW_ICON.NBT, CraftMagicNumbers.NBT.TAG_BYTE) ? effect.getBoolean(SHOW_ICON.NBT) : particles;
@@ -225,7 +217,7 @@ index d94ab2607d1ab657a6b37924ce5ebcbbc3984011..f594596029513426f974ba820ed47027
} }
} }
} }
@@ -138,6 +146,11 @@ class CraftMetaPotion extends CraftMetaItem implements PotionMeta { @@ -139,6 +146,11 @@ class CraftMetaPotion extends CraftMetaItem implements PotionMeta {
effectData.putBoolean(AMBIENT.NBT, effect.isAmbient()); effectData.putBoolean(AMBIENT.NBT, effect.isAmbient());
effectData.putBoolean(SHOW_PARTICLES.NBT, effect.hasParticles()); effectData.putBoolean(SHOW_PARTICLES.NBT, effect.hasParticles());
effectData.putBoolean(SHOW_ICON.NBT, effect.hasIcon()); effectData.putBoolean(SHOW_ICON.NBT, effect.hasIcon());
@@ -237,7 +229,7 @@ index d94ab2607d1ab657a6b37924ce5ebcbbc3984011..f594596029513426f974ba820ed47027
effectList.add(effectData); effectList.add(effectData);
} }
} }
@@ -199,7 +212,7 @@ class CraftMetaPotion extends CraftMetaItem implements PotionMeta { @@ -200,7 +212,7 @@ class CraftMetaPotion extends CraftMetaItem implements PotionMeta {
if (index != -1) { if (index != -1) {
if (overwrite) { if (overwrite) {
PotionEffect old = this.customEffects.get(index); PotionEffect old = this.customEffects.get(index);
@@ -247,13 +239,13 @@ index d94ab2607d1ab657a6b37924ce5ebcbbc3984011..f594596029513426f974ba820ed47027
} }
this.customEffects.set(index, effect); this.customEffects.set(index, effect);
diff --git a/src/main/java/org/bukkit/craftbukkit/potion/CraftPotionUtil.java b/src/main/java/org/bukkit/craftbukkit/potion/CraftPotionUtil.java diff --git a/src/main/java/org/bukkit/craftbukkit/potion/CraftPotionUtil.java b/src/main/java/org/bukkit/craftbukkit/potion/CraftPotionUtil.java
index acb69821a99aa69bce6d127e10976089c85be223..c5abd73981c5f4b41605eba0d44e6573dfd2a77a 100644 index 354393cbf0f113f14e936b40da56125a3130cbd9..a1ef7ecdf272546bdd76bb4b2ecd86a69c51c777 100644
--- a/src/main/java/org/bukkit/craftbukkit/potion/CraftPotionUtil.java --- a/src/main/java/org/bukkit/craftbukkit/potion/CraftPotionUtil.java
+++ b/src/main/java/org/bukkit/craftbukkit/potion/CraftPotionUtil.java +++ b/src/main/java/org/bukkit/craftbukkit/potion/CraftPotionUtil.java
@@ -101,7 +101,7 @@ public class CraftPotionUtil { @@ -101,7 +101,7 @@ public class CraftPotionUtil {
public static MobEffectInstance fromBukkit(PotionEffect effect) { public static MobEffectInstance fromBukkit(PotionEffect effect) {
MobEffect type = MobEffect.byId(effect.getType().getId()); MobEffect type = CraftPotionEffectType.bukkitToMinecraft(effect.getType());
- return new MobEffectInstance(type, effect.getDuration(), effect.getAmplifier(), effect.isAmbient(), effect.hasParticles()); - return new MobEffectInstance(type, effect.getDuration(), effect.getAmplifier(), effect.isAmbient(), effect.hasParticles());
+ return new MobEffectInstance(type, effect.getDuration(), effect.getAmplifier(), effect.isAmbient(), effect.hasParticles(), effect.getKey()); // Purpur - add key + return new MobEffectInstance(type, effect.getDuration(), effect.getAmplifier(), effect.isAmbient(), effect.hasParticles(), effect.getKey()); // Purpur - add key
} }
@@ -269,7 +261,7 @@ index acb69821a99aa69bce6d127e10976089c85be223..c5abd73981c5f4b41605eba0d44e6573
public static boolean equals(MobEffect mobEffect, PotionEffectType type) { public static boolean equals(MobEffect mobEffect, PotionEffectType type) {
diff --git a/src/test/java/org/bukkit/potion/PotionTest.java b/src/test/java/org/bukkit/potion/PotionTest.java diff --git a/src/test/java/org/bukkit/potion/PotionTest.java b/src/test/java/org/bukkit/potion/PotionTest.java
index 83226ec2fa977819e12a499eb3765232543c17b3..a742774dabaee0629f4e6adabee5f3ec4b3be41c 100644 index 9457c66bd81f202e009c94f732c8e8e7f2ab9957..863f140260657f224fa3a2eb0bc6f929f74f5c0d 100644
--- a/src/test/java/org/bukkit/potion/PotionTest.java --- a/src/test/java/org/bukkit/potion/PotionTest.java
+++ b/src/test/java/org/bukkit/potion/PotionTest.java +++ b/src/test/java/org/bukkit/potion/PotionTest.java
@@ -9,6 +9,7 @@ import net.minecraft.resources.ResourceLocation; @@ -9,6 +9,7 @@ import net.minecraft.resources.ResourceLocation;
@@ -277,10 +269,10 @@ index 83226ec2fa977819e12a499eb3765232543c17b3..a742774dabaee0629f4e6adabee5f3ec
import net.minecraft.world.effect.MobEffectInstance; import net.minecraft.world.effect.MobEffectInstance;
import net.minecraft.world.item.alchemy.Potion; import net.minecraft.world.item.alchemy.Potion;
+import org.bukkit.NamespacedKey; +import org.bukkit.NamespacedKey;
import org.bukkit.craftbukkit.potion.CraftPotionEffectType;
import org.bukkit.support.AbstractTestingBase; import org.bukkit.support.AbstractTestingBase;
import org.junit.Test; import org.junit.Test;
@@ -46,4 +47,27 @@ public class PotionTest extends AbstractTestingBase {
@@ -47,4 +48,27 @@ public class PotionTest extends AbstractTestingBase {
assertEquals("Same type not returned by name " + key, bukkit, byName); assertEquals("Same type not returned by name " + key, bukkit, byName);
} }
} }

View File

@@ -5,7 +5,7 @@ Subject: [PATCH] Grindstone API
diff --git a/src/main/java/net/minecraft/world/inventory/GrindstoneMenu.java b/src/main/java/net/minecraft/world/inventory/GrindstoneMenu.java diff --git a/src/main/java/net/minecraft/world/inventory/GrindstoneMenu.java b/src/main/java/net/minecraft/world/inventory/GrindstoneMenu.java
index 6860e3467bf785e9d017fc98fce1e3cf71f9b6ee..23a8522b80475ad29ffb4afd2f4836acda2538e3 100644 index 132a07e226ae3ac6b5abc6f53c62345e2ab2f31f..3b721092a7a73472756064e0eb91d3220fdc4bc8 100644
--- a/src/main/java/net/minecraft/world/inventory/GrindstoneMenu.java --- a/src/main/java/net/minecraft/world/inventory/GrindstoneMenu.java
+++ b/src/main/java/net/minecraft/world/inventory/GrindstoneMenu.java +++ b/src/main/java/net/minecraft/world/inventory/GrindstoneMenu.java
@@ -95,9 +95,11 @@ public class GrindstoneMenu extends AbstractContainerMenu { @@ -95,9 +95,11 @@ public class GrindstoneMenu extends AbstractContainerMenu {

View File

@@ -34,10 +34,10 @@ index 03fde6e47c4a347c62fe9b4a3351769aedf874f6..ca906b0250e5332f7ececf1419ca6d2c
+ // Purpur end + // Purpur end
} }
diff --git a/src/main/java/net/minecraft/world/level/block/CropBlock.java b/src/main/java/net/minecraft/world/level/block/CropBlock.java diff --git a/src/main/java/net/minecraft/world/level/block/CropBlock.java b/src/main/java/net/minecraft/world/level/block/CropBlock.java
index 373fda589014c71c07170ec6707d5ff66d46ddd5..26b3f162f25bed3e9d8001e3d9c2f8d7d4b3e08a 100644 index 3f429f083f45d34effc273ccaa5db4da089f7355..61d051f42d8c3d1f039b97fdc7a61b54f57ee86a 100644
--- a/src/main/java/net/minecraft/world/level/block/CropBlock.java --- a/src/main/java/net/minecraft/world/level/block/CropBlock.java
+++ b/src/main/java/net/minecraft/world/level/block/CropBlock.java +++ b/src/main/java/net/minecraft/world/level/block/CropBlock.java
@@ -203,4 +203,15 @@ public class CropBlock extends BushBlock implements BonemealableBlock { @@ -207,4 +207,15 @@ public class CropBlock extends BushBlock implements BonemealableBlock {
protected void createBlockStateDefinition(StateDefinition.Builder<Block, BlockState> builder) { protected void createBlockStateDefinition(StateDefinition.Builder<Block, BlockState> builder) {
builder.add(CropBlock.AGE); builder.add(CropBlock.AGE);
} }
@@ -74,10 +74,10 @@ index e55720c4d2fbdf6aae526910e87a67c29cf906fd..74fedd3e401c6d58c03c0579f4b91911
+ // Purpur end + // Purpur end
} }
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index e184a95a4ff3028ffa05fb4dad68c0047d22a638..98c39a3297e676c7c780430180f5e98076b7e718 100644 index 41b856485bbb6872cc49cfdc460303e465c3143e..bda73dd90c7d5e72996efca0a41e7f4785c6f548 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -547,6 +547,8 @@ public class PurpurWorldConfig { @@ -543,6 +543,8 @@ public class PurpurWorldConfig {
public Map<Block, Weatherable> axeWeatherables = new HashMap<>(); public Map<Block, Weatherable> axeWeatherables = new HashMap<>();
public Map<Block, Tillable> hoeTillables = new HashMap<>(); public Map<Block, Tillable> hoeTillables = new HashMap<>();
public Map<Block, Flattenable> shovelFlattenables = new HashMap<>(); public Map<Block, Flattenable> shovelFlattenables = new HashMap<>();
@@ -86,7 +86,7 @@ index e184a95a4ff3028ffa05fb4dad68c0047d22a638..98c39a3297e676c7c780430180f5e980
private void toolSettings() { private void toolSettings() {
axeStrippables.clear(); axeStrippables.clear();
axeWaxables.clear(); axeWaxables.clear();
@@ -740,6 +742,8 @@ public class PurpurWorldConfig { @@ -736,6 +738,8 @@ public class PurpurWorldConfig {
}); });
shovelFlattenables.put(block, new Flattenable(into, drops)); shovelFlattenables.put(block, new Flattenable(into, drops));
}); });

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Shearing jeb produces random color wool
diff --git a/src/main/java/net/minecraft/world/entity/animal/Sheep.java b/src/main/java/net/minecraft/world/entity/animal/Sheep.java diff --git a/src/main/java/net/minecraft/world/entity/animal/Sheep.java b/src/main/java/net/minecraft/world/entity/animal/Sheep.java
index a1b323ecba25910e97f154e487acc94943117e0c..62d8ae4c689170420c7850fbbb402be85b565882 100644 index f2d0c67709e38209a8a02e98f4392b9e0a53c211..fb477c3c594bb81e92ae0c606635c309840d0dc5 100644
--- a/src/main/java/net/minecraft/world/entity/animal/Sheep.java --- a/src/main/java/net/minecraft/world/entity/animal/Sheep.java
+++ b/src/main/java/net/minecraft/world/entity/animal/Sheep.java +++ b/src/main/java/net/minecraft/world/entity/animal/Sheep.java
@@ -315,7 +315,7 @@ public class Sheep extends Animal implements Shearable { @@ -317,7 +317,7 @@ public class Sheep extends Animal implements Shearable {
for (int j = 0; j < i; ++j) { for (int j = 0; j < i; ++j) {
this.forceDrops = true; // CraftBukkit this.forceDrops = true; // CraftBukkit
@@ -18,10 +18,10 @@ index a1b323ecba25910e97f154e487acc94943117e0c..62d8ae4c689170420c7850fbbb402be8
if (entityitem != null) { if (entityitem != null) {
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 98c39a3297e676c7c780430180f5e98076b7e718..6edb5b4cac3ac9cf7d080293f0b582df31fe2c86 100644 index bda73dd90c7d5e72996efca0a41e7f4785c6f548..fad281ec8314d4431126abbcea997932401ea95e 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -2307,6 +2307,7 @@ public class PurpurWorldConfig { @@ -2303,6 +2303,7 @@ public class PurpurWorldConfig {
public boolean sheepBypassMobGriefing = false; public boolean sheepBypassMobGriefing = false;
public boolean sheepTakeDamageFromWater = false; public boolean sheepTakeDamageFromWater = false;
public boolean sheepAlwaysDropExp = false; public boolean sheepAlwaysDropExp = false;
@@ -29,7 +29,7 @@ index 98c39a3297e676c7c780430180f5e98076b7e718..6edb5b4cac3ac9cf7d080293f0b582df
private void sheepSettings() { private void sheepSettings() {
sheepRidable = getBoolean("mobs.sheep.ridable", sheepRidable); sheepRidable = getBoolean("mobs.sheep.ridable", sheepRidable);
sheepRidableInWater = getBoolean("mobs.sheep.ridable-in-water", sheepRidableInWater); sheepRidableInWater = getBoolean("mobs.sheep.ridable-in-water", sheepRidableInWater);
@@ -2321,6 +2322,7 @@ public class PurpurWorldConfig { @@ -2317,6 +2318,7 @@ public class PurpurWorldConfig {
sheepBypassMobGriefing = getBoolean("mobs.sheep.bypass-mob-griefing", sheepBypassMobGriefing); sheepBypassMobGriefing = getBoolean("mobs.sheep.bypass-mob-griefing", sheepBypassMobGriefing);
sheepTakeDamageFromWater = getBoolean("mobs.sheep.takes-damage-from-water", sheepTakeDamageFromWater); sheepTakeDamageFromWater = getBoolean("mobs.sheep.takes-damage-from-water", sheepTakeDamageFromWater);
sheepAlwaysDropExp = getBoolean("mobs.sheep.always-drop-exp", sheepAlwaysDropExp); sheepAlwaysDropExp = getBoolean("mobs.sheep.always-drop-exp", sheepAlwaysDropExp);

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Turtle eggs random tick crack chance
diff --git a/src/main/java/net/minecraft/world/level/block/TurtleEggBlock.java b/src/main/java/net/minecraft/world/level/block/TurtleEggBlock.java diff --git a/src/main/java/net/minecraft/world/level/block/TurtleEggBlock.java b/src/main/java/net/minecraft/world/level/block/TurtleEggBlock.java
index 86360fad47e4cda64b02ce4c8c0227649ed69a5d..b211d7b37095b52424ead1bb0be0c81bc4322985 100644 index 9c834e3deed07eb70e6a57df2db732c1e2334737..8e975daca6a50c95d7fb620f2756b8bb2b7c7d6b 100644
--- a/src/main/java/net/minecraft/world/level/block/TurtleEggBlock.java --- a/src/main/java/net/minecraft/world/level/block/TurtleEggBlock.java
+++ b/src/main/java/net/minecraft/world/level/block/TurtleEggBlock.java +++ b/src/main/java/net/minecraft/world/level/block/TurtleEggBlock.java
@@ -160,7 +160,7 @@ public class TurtleEggBlock extends Block { @@ -162,7 +162,7 @@ public class TurtleEggBlock extends Block {
private boolean shouldUpdateHatchLevel(Level world) { private boolean shouldUpdateHatchLevel(Level world) {
float f = world.getTimeOfDay(1.0F); float f = world.getTimeOfDay(1.0F);
@@ -18,10 +18,10 @@ index 86360fad47e4cda64b02ce4c8c0227649ed69a5d..b211d7b37095b52424ead1bb0be0c81b
@Override @Override
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 6edb5b4cac3ac9cf7d080293f0b582df31fe2c86..30e63ae6bc35efc64a016966f55bfb1e7df52d89 100644 index fad281ec8314d4431126abbcea997932401ea95e..c300838d83652a36389694e7afbec5feff11cd8a 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -1015,11 +1015,13 @@ public class PurpurWorldConfig { @@ -1011,11 +1011,13 @@ public class PurpurWorldConfig {
public boolean turtleEggsBreakFromItems = true; public boolean turtleEggsBreakFromItems = true;
public boolean turtleEggsBreakFromMinecarts = true; public boolean turtleEggsBreakFromMinecarts = true;
public boolean turtleEggsBypassMobGriefing = false; public boolean turtleEggsBypassMobGriefing = false;

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Mob head visibility percent
diff --git a/src/main/java/net/minecraft/world/entity/LivingEntity.java b/src/main/java/net/minecraft/world/entity/LivingEntity.java diff --git a/src/main/java/net/minecraft/world/entity/LivingEntity.java b/src/main/java/net/minecraft/world/entity/LivingEntity.java
index 21d6851cb903f214db92109a6c16bb7367e40e1c..aff8b1b0683e52038b6d92e052a012c9198bf8ce 100644 index 7c91aa226517d9d574f102e3e4976904b419e657..11761085514d54e23fece41a408b74a2bde3effc 100644
--- a/src/main/java/net/minecraft/world/entity/LivingEntity.java --- a/src/main/java/net/minecraft/world/entity/LivingEntity.java
+++ b/src/main/java/net/minecraft/world/entity/LivingEntity.java +++ b/src/main/java/net/minecraft/world/entity/LivingEntity.java
@@ -1040,9 +1040,20 @@ public abstract class LivingEntity extends Entity implements Attackable { @@ -1041,9 +1041,20 @@ public abstract class LivingEntity extends Entity implements Attackable {
ItemStack itemstack = this.getItemBySlot(EquipmentSlot.HEAD); ItemStack itemstack = this.getItemBySlot(EquipmentSlot.HEAD);
EntityType<?> entitytypes = entity.getType(); EntityType<?> entitytypes = entity.getType();
@@ -32,10 +32,10 @@ index 21d6851cb903f214db92109a6c16bb7367e40e1c..aff8b1b0683e52038b6d92e052a012c9
// Purpur start // Purpur start
if (entity instanceof LivingEntity entityliving) { if (entity instanceof LivingEntity entityliving) {
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 30e63ae6bc35efc64a016966f55bfb1e7df52d89..91af2d4187b2e61426539d018900c810d048efc9 100644 index c300838d83652a36389694e7afbec5feff11cd8a..a5f86aa5c3cd08dddb147c338a124953cacbf178 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -1309,6 +1309,7 @@ public class PurpurWorldConfig { @@ -1305,6 +1305,7 @@ public class PurpurWorldConfig {
public boolean creeperExplodeWhenKilled = false; public boolean creeperExplodeWhenKilled = false;
public boolean creeperHealthRadius = false; public boolean creeperHealthRadius = false;
public boolean creeperAlwaysDropExp = false; public boolean creeperAlwaysDropExp = false;
@@ -43,7 +43,7 @@ index 30e63ae6bc35efc64a016966f55bfb1e7df52d89..91af2d4187b2e61426539d018900c810
private void creeperSettings() { private void creeperSettings() {
creeperRidable = getBoolean("mobs.creeper.ridable", creeperRidable); creeperRidable = getBoolean("mobs.creeper.ridable", creeperRidable);
creeperRidableInWater = getBoolean("mobs.creeper.ridable-in-water", creeperRidableInWater); creeperRidableInWater = getBoolean("mobs.creeper.ridable-in-water", creeperRidableInWater);
@@ -1326,6 +1327,7 @@ public class PurpurWorldConfig { @@ -1322,6 +1323,7 @@ public class PurpurWorldConfig {
creeperExplodeWhenKilled = getBoolean("mobs.creeper.explode-when-killed", creeperExplodeWhenKilled); creeperExplodeWhenKilled = getBoolean("mobs.creeper.explode-when-killed", creeperExplodeWhenKilled);
creeperHealthRadius = getBoolean("mobs.creeper.health-impacts-explosion", creeperHealthRadius); creeperHealthRadius = getBoolean("mobs.creeper.health-impacts-explosion", creeperHealthRadius);
creeperAlwaysDropExp = getBoolean("mobs.creeper.always-drop-exp", creeperAlwaysDropExp); creeperAlwaysDropExp = getBoolean("mobs.creeper.always-drop-exp", creeperAlwaysDropExp);
@@ -51,7 +51,7 @@ index 30e63ae6bc35efc64a016966f55bfb1e7df52d89..91af2d4187b2e61426539d018900c810
} }
public boolean dolphinRidable = false; public boolean dolphinRidable = false;
@@ -2112,6 +2114,7 @@ public class PurpurWorldConfig { @@ -2108,6 +2110,7 @@ public class PurpurWorldConfig {
public boolean piglinTakeDamageFromWater = false; public boolean piglinTakeDamageFromWater = false;
public int piglinPortalSpawnModifier = 2000; public int piglinPortalSpawnModifier = 2000;
public boolean piglinAlwaysDropExp = false; public boolean piglinAlwaysDropExp = false;
@@ -59,7 +59,7 @@ index 30e63ae6bc35efc64a016966f55bfb1e7df52d89..91af2d4187b2e61426539d018900c810
private void piglinSettings() { private void piglinSettings() {
piglinRidable = getBoolean("mobs.piglin.ridable", piglinRidable); piglinRidable = getBoolean("mobs.piglin.ridable", piglinRidable);
piglinRidableInWater = getBoolean("mobs.piglin.ridable-in-water", piglinRidableInWater); piglinRidableInWater = getBoolean("mobs.piglin.ridable-in-water", piglinRidableInWater);
@@ -2126,6 +2129,7 @@ public class PurpurWorldConfig { @@ -2122,6 +2125,7 @@ public class PurpurWorldConfig {
piglinTakeDamageFromWater = getBoolean("mobs.piglin.takes-damage-from-water", piglinTakeDamageFromWater); piglinTakeDamageFromWater = getBoolean("mobs.piglin.takes-damage-from-water", piglinTakeDamageFromWater);
piglinPortalSpawnModifier = getInt("mobs.piglin.portal-spawn-modifier", piglinPortalSpawnModifier); piglinPortalSpawnModifier = getInt("mobs.piglin.portal-spawn-modifier", piglinPortalSpawnModifier);
piglinAlwaysDropExp = getBoolean("mobs.piglin.always-drop-exp", piglinAlwaysDropExp); piglinAlwaysDropExp = getBoolean("mobs.piglin.always-drop-exp", piglinAlwaysDropExp);
@@ -67,7 +67,7 @@ index 30e63ae6bc35efc64a016966f55bfb1e7df52d89..91af2d4187b2e61426539d018900c810
} }
public boolean piglinBruteRidable = false; public boolean piglinBruteRidable = false;
@@ -2387,6 +2391,7 @@ public class PurpurWorldConfig { @@ -2383,6 +2387,7 @@ public class PurpurWorldConfig {
public double skeletonMaxHealth = 20.0D; public double skeletonMaxHealth = 20.0D;
public boolean skeletonTakeDamageFromWater = false; public boolean skeletonTakeDamageFromWater = false;
public boolean skeletonAlwaysDropExp = false; public boolean skeletonAlwaysDropExp = false;
@@ -75,7 +75,7 @@ index 30e63ae6bc35efc64a016966f55bfb1e7df52d89..91af2d4187b2e61426539d018900c810
private void skeletonSettings() { private void skeletonSettings() {
skeletonRidable = getBoolean("mobs.skeleton.ridable", skeletonRidable); skeletonRidable = getBoolean("mobs.skeleton.ridable", skeletonRidable);
skeletonRidableInWater = getBoolean("mobs.skeleton.ridable-in-water", skeletonRidableInWater); skeletonRidableInWater = getBoolean("mobs.skeleton.ridable-in-water", skeletonRidableInWater);
@@ -2399,6 +2404,7 @@ public class PurpurWorldConfig { @@ -2395,6 +2400,7 @@ public class PurpurWorldConfig {
skeletonMaxHealth = getDouble("mobs.skeleton.attributes.max_health", skeletonMaxHealth); skeletonMaxHealth = getDouble("mobs.skeleton.attributes.max_health", skeletonMaxHealth);
skeletonTakeDamageFromWater = getBoolean("mobs.skeleton.takes-damage-from-water", skeletonTakeDamageFromWater); skeletonTakeDamageFromWater = getBoolean("mobs.skeleton.takes-damage-from-water", skeletonTakeDamageFromWater);
skeletonAlwaysDropExp = getBoolean("mobs.skeleton.always-drop-exp", skeletonAlwaysDropExp); skeletonAlwaysDropExp = getBoolean("mobs.skeleton.always-drop-exp", skeletonAlwaysDropExp);
@@ -83,7 +83,7 @@ index 30e63ae6bc35efc64a016966f55bfb1e7df52d89..91af2d4187b2e61426539d018900c810
} }
public boolean skeletonHorseRidableInWater = true; public boolean skeletonHorseRidableInWater = true;
@@ -2933,6 +2939,7 @@ public class PurpurWorldConfig { @@ -2929,6 +2935,7 @@ public class PurpurWorldConfig {
public boolean zombieBypassMobGriefing = false; public boolean zombieBypassMobGriefing = false;
public boolean zombieTakeDamageFromWater = false; public boolean zombieTakeDamageFromWater = false;
public boolean zombieAlwaysDropExp = false; public boolean zombieAlwaysDropExp = false;
@@ -91,7 +91,7 @@ index 30e63ae6bc35efc64a016966f55bfb1e7df52d89..91af2d4187b2e61426539d018900c810
private void zombieSettings() { private void zombieSettings() {
zombieRidable = getBoolean("mobs.zombie.ridable", zombieRidable); zombieRidable = getBoolean("mobs.zombie.ridable", zombieRidable);
zombieRidableInWater = getBoolean("mobs.zombie.ridable-in-water", zombieRidableInWater); zombieRidableInWater = getBoolean("mobs.zombie.ridable-in-water", zombieRidableInWater);
@@ -2951,6 +2958,7 @@ public class PurpurWorldConfig { @@ -2947,6 +2954,7 @@ public class PurpurWorldConfig {
zombieBypassMobGriefing = getBoolean("mobs.zombie.bypass-mob-griefing", zombieBypassMobGriefing); zombieBypassMobGriefing = getBoolean("mobs.zombie.bypass-mob-griefing", zombieBypassMobGriefing);
zombieTakeDamageFromWater = getBoolean("mobs.zombie.takes-damage-from-water", zombieTakeDamageFromWater); zombieTakeDamageFromWater = getBoolean("mobs.zombie.takes-damage-from-water", zombieTakeDamageFromWater);
zombieAlwaysDropExp = getBoolean("mobs.zombie.always-drop-exp", zombieAlwaysDropExp); zombieAlwaysDropExp = getBoolean("mobs.zombie.always-drop-exp", zombieAlwaysDropExp);

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Configurable valid characters for usernames
diff --git a/src/main/java/net/minecraft/server/network/ServerLoginPacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerLoginPacketListenerImpl.java diff --git a/src/main/java/net/minecraft/server/network/ServerLoginPacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerLoginPacketListenerImpl.java
index b4b88a3d4dc66c44ca8f3bad1025c17a9993ac1d..01d5fa265fb2818465b5a71a2e2efeec751a7a05 100644 index e615e417627840d645db259bc9640a0471a52b05..f0bbc48e2df1da42e4bf9f7113451738b986fbbf 100644
--- a/src/main/java/net/minecraft/server/network/ServerLoginPacketListenerImpl.java --- a/src/main/java/net/minecraft/server/network/ServerLoginPacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerLoginPacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerLoginPacketListenerImpl.java
@@ -221,6 +221,8 @@ public class ServerLoginPacketListenerImpl implements ServerLoginPacketListener, @@ -141,6 +141,8 @@ public class ServerLoginPacketListenerImpl implements ServerLoginPacketListener,
return false; return false;
} }

View File

@@ -5,7 +5,7 @@ Subject: [PATCH] Shears can have looting enchantment
diff --git a/src/main/java/net/minecraft/core/dispenser/ShearsDispenseItemBehavior.java b/src/main/java/net/minecraft/core/dispenser/ShearsDispenseItemBehavior.java diff --git a/src/main/java/net/minecraft/core/dispenser/ShearsDispenseItemBehavior.java b/src/main/java/net/minecraft/core/dispenser/ShearsDispenseItemBehavior.java
index 9b0049dfeaec9b688bf276f2ac2b18943b5696b2..d7563904232353cbf3b9255cedfb75920e35220c 100644 index e17090003988ad2c890d48666c2234b14d511345..433f1f11b8b92c7d48352416f79ab5a394c33287 100644
--- a/src/main/java/net/minecraft/core/dispenser/ShearsDispenseItemBehavior.java --- a/src/main/java/net/minecraft/core/dispenser/ShearsDispenseItemBehavior.java
+++ b/src/main/java/net/minecraft/core/dispenser/ShearsDispenseItemBehavior.java +++ b/src/main/java/net/minecraft/core/dispenser/ShearsDispenseItemBehavior.java
@@ -107,7 +107,7 @@ public class ShearsDispenseItemBehavior extends OptionalDispenseItemBehavior { @@ -107,7 +107,7 @@ public class ShearsDispenseItemBehavior extends OptionalDispenseItemBehavior {
@@ -37,10 +37,10 @@ index 5e8cc5cfac8888628c6d513148f41be09ca65a2c..a089fc61ec09be6b7490375489178dc6
boolean readyForShearing(); boolean readyForShearing();
} }
diff --git a/src/main/java/net/minecraft/world/entity/animal/MushroomCow.java b/src/main/java/net/minecraft/world/entity/animal/MushroomCow.java diff --git a/src/main/java/net/minecraft/world/entity/animal/MushroomCow.java b/src/main/java/net/minecraft/world/entity/animal/MushroomCow.java
index 1b0a0e36baa0f664f06b2d166aa907b320066b6e..e462b81aa1276a8f1222b74459359f6c6d57f739 100644 index ab5b150b379598861666ad32906e1fe454437063..59ef1070c6c1ac876e097cd23835e4ed8b6e732f 100644
--- a/src/main/java/net/minecraft/world/entity/animal/MushroomCow.java --- a/src/main/java/net/minecraft/world/entity/animal/MushroomCow.java
+++ b/src/main/java/net/minecraft/world/entity/animal/MushroomCow.java +++ b/src/main/java/net/minecraft/world/entity/animal/MushroomCow.java
@@ -164,7 +164,7 @@ public class MushroomCow extends Cow implements Shearable, VariantHolder<Mushroo @@ -163,7 +163,7 @@ public class MushroomCow extends Cow implements Shearable, VariantHolder<Mushroo
return tryRide(player, hand); // Purpur return tryRide(player, hand); // Purpur
} }
// CraftBukkit end // CraftBukkit end
@@ -49,7 +49,7 @@ index 1b0a0e36baa0f664f06b2d166aa907b320066b6e..e462b81aa1276a8f1222b74459359f6c
this.gameEvent(GameEvent.SHEAR, player); this.gameEvent(GameEvent.SHEAR, player);
if (!this.level().isClientSide) { if (!this.level().isClientSide) {
itemstack.hurtAndBreak(1, player, (entityhuman1) -> { itemstack.hurtAndBreak(1, player, (entityhuman1) -> {
@@ -207,7 +207,7 @@ public class MushroomCow extends Cow implements Shearable, VariantHolder<Mushroo @@ -203,7 +203,7 @@ public class MushroomCow extends Cow implements Shearable, VariantHolder<Mushroo
} }
@Override @Override
@@ -58,7 +58,7 @@ index 1b0a0e36baa0f664f06b2d166aa907b320066b6e..e462b81aa1276a8f1222b74459359f6c
this.level().playSound((Player) null, (Entity) this, SoundEvents.MOOSHROOM_SHEAR, shearedSoundCategory, 1.0F, 1.0F); this.level().playSound((Player) null, (Entity) this, SoundEvents.MOOSHROOM_SHEAR, shearedSoundCategory, 1.0F, 1.0F);
if (!this.level().isClientSide()) { if (!this.level().isClientSide()) {
Cow entitycow = (Cow) EntityType.COW.create(this.level()); Cow entitycow = (Cow) EntityType.COW.create(this.level());
@@ -243,7 +243,7 @@ public class MushroomCow extends Cow implements Shearable, VariantHolder<Mushroo @@ -239,7 +239,7 @@ public class MushroomCow extends Cow implements Shearable, VariantHolder<Mushroo
this.discard(); // CraftBukkit - from above this.discard(); // CraftBukkit - from above
// CraftBukkit end // CraftBukkit end
@@ -68,10 +68,10 @@ index 1b0a0e36baa0f664f06b2d166aa907b320066b6e..e462b81aa1276a8f1222b74459359f6c
ItemEntity entityitem = new ItemEntity(this.level(), this.getX(), this.getY(1.0D), this.getZ(), new ItemStack(this.getVariant().blockState.getBlock())); ItemEntity entityitem = new ItemEntity(this.level(), this.getX(), this.getY(1.0D), this.getZ(), new ItemStack(this.getVariant().blockState.getBlock()));
EntityDropItemEvent event = new EntityDropItemEvent(this.getBukkitEntity(), (org.bukkit.entity.Item) entityitem.getBukkitEntity()); EntityDropItemEvent event = new EntityDropItemEvent(this.getBukkitEntity(), (org.bukkit.entity.Item) entityitem.getBukkitEntity());
diff --git a/src/main/java/net/minecraft/world/entity/animal/Sheep.java b/src/main/java/net/minecraft/world/entity/animal/Sheep.java diff --git a/src/main/java/net/minecraft/world/entity/animal/Sheep.java b/src/main/java/net/minecraft/world/entity/animal/Sheep.java
index 62d8ae4c689170420c7850fbbb402be85b565882..54de1f782e45cb3e3b1442aeb56b6e8547b065c0 100644 index fb477c3c594bb81e92ae0c606635c309840d0dc5..8502fc1331c2e94992ab39e4e7ea0f36e83b06a5 100644
--- a/src/main/java/net/minecraft/world/entity/animal/Sheep.java --- a/src/main/java/net/minecraft/world/entity/animal/Sheep.java
+++ b/src/main/java/net/minecraft/world/entity/animal/Sheep.java +++ b/src/main/java/net/minecraft/world/entity/animal/Sheep.java
@@ -293,7 +293,7 @@ public class Sheep extends Animal implements Shearable { @@ -295,7 +295,7 @@ public class Sheep extends Animal implements Shearable {
return InteractionResult.PASS; return InteractionResult.PASS;
} }
// CraftBukkit end // CraftBukkit end
@@ -80,7 +80,7 @@ index 62d8ae4c689170420c7850fbbb402be85b565882..54de1f782e45cb3e3b1442aeb56b6e85
this.gameEvent(GameEvent.SHEAR, player); this.gameEvent(GameEvent.SHEAR, player);
itemstack.hurtAndBreak(1, player, (entityhuman1) -> { itemstack.hurtAndBreak(1, player, (entityhuman1) -> {
entityhuman1.broadcastBreakEvent(hand); entityhuman1.broadcastBreakEvent(hand);
@@ -308,10 +308,11 @@ public class Sheep extends Animal implements Shearable { @@ -310,10 +310,11 @@ public class Sheep extends Animal implements Shearable {
} }
@Override @Override
@@ -139,11 +139,11 @@ index 859435f747ceef860cb4e9e825a7353ea3b90798..fc2c35f57436371cb0111aedfd289ac9
}; };
diff --git a/src/main/java/net/minecraft/world/item/enchantment/LootBonusEnchantment.java b/src/main/java/net/minecraft/world/item/enchantment/LootBonusEnchantment.java diff --git a/src/main/java/net/minecraft/world/item/enchantment/LootBonusEnchantment.java b/src/main/java/net/minecraft/world/item/enchantment/LootBonusEnchantment.java
index 4007c16550683e23b396dfdff29530a82523fe05..8fe09c13643d99639fb242da4367c42ef31b38b4 100644 index 7f1ffc0ac402fcf0ec086986e959ecc9f78dde03..1351d52374d1c2367932e5ecd5f4637955fb14c9 100644
--- a/src/main/java/net/minecraft/world/item/enchantment/LootBonusEnchantment.java --- a/src/main/java/net/minecraft/world/item/enchantment/LootBonusEnchantment.java
+++ b/src/main/java/net/minecraft/world/item/enchantment/LootBonusEnchantment.java +++ b/src/main/java/net/minecraft/world/item/enchantment/LootBonusEnchantment.java
@@ -7,6 +7,14 @@ public class LootBonusEnchantment extends Enchantment { @@ -7,6 +7,14 @@ public class LootBonusEnchantment extends Enchantment {
super(weight, target, slotTypes); super(rarity, target, slotTypes);
} }
+ // Purpur start + // Purpur start

View File

@@ -17,10 +17,10 @@ index ac4ca4de2be18a08268b24dfe259cfd136b1a4da..e837500019157129007841c847d807eb
++this.timeSinceSting; ++this.timeSinceSting;
if (this.timeSinceSting % 5 == 0 && this.random.nextInt(Mth.clamp(1200 - this.timeSinceSting, 1, 1200)) == 0) { if (this.timeSinceSting % 5 == 0 && this.random.nextInt(Mth.clamp(1200 - this.timeSinceSting, 1, 1200)) == 0) {
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 91af2d4187b2e61426539d018900c810d048efc9..a419aa0b06d5215ec66649dde8822120eb91a0f3 100644 index a5f86aa5c3cd08dddb147c338a124953cacbf178..60beda5c1f3b7ca562b8ba9ff48e0c6e50e89649 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -1110,6 +1110,7 @@ public class PurpurWorldConfig { @@ -1106,6 +1106,7 @@ public class PurpurWorldConfig {
public boolean beeCanWorkAtNight = false; public boolean beeCanWorkAtNight = false;
public boolean beeCanWorkInRain = false; public boolean beeCanWorkInRain = false;
public boolean beeAlwaysDropExp = false; public boolean beeAlwaysDropExp = false;
@@ -28,7 +28,7 @@ index 91af2d4187b2e61426539d018900c810d048efc9..a419aa0b06d5215ec66649dde8822120
private void beeSettings() { private void beeSettings() {
beeRidable = getBoolean("mobs.bee.ridable", beeRidable); beeRidable = getBoolean("mobs.bee.ridable", beeRidable);
beeRidableInWater = getBoolean("mobs.bee.ridable-in-water", beeRidableInWater); beeRidableInWater = getBoolean("mobs.bee.ridable-in-water", beeRidableInWater);
@@ -1126,6 +1127,7 @@ public class PurpurWorldConfig { @@ -1122,6 +1123,7 @@ public class PurpurWorldConfig {
beeCanWorkAtNight = getBoolean("mobs.bee.can-work-at-night", beeCanWorkAtNight); beeCanWorkAtNight = getBoolean("mobs.bee.can-work-at-night", beeCanWorkAtNight);
beeCanWorkInRain = getBoolean("mobs.bee.can-work-in-rain", beeCanWorkInRain); beeCanWorkInRain = getBoolean("mobs.bee.can-work-in-rain", beeCanWorkInRain);
beeAlwaysDropExp = getBoolean("mobs.bee.always-drop-exp", beeAlwaysDropExp); beeAlwaysDropExp = getBoolean("mobs.bee.always-drop-exp", beeAlwaysDropExp);

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Give bee counts in beehives to Purpur clients
diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java
index 3a9fe6d9f2e7406ffc368e2dadaab803b591f5c2..d474e2ce24d822254c1ac0c9d9468ac13f9cca86 100644 index 5018f85fd87fe167389706bda04327bbe7d2c17a..ad403421711052faf36cb6b063997cfa90712423 100644
--- a/src/main/java/net/minecraft/server/MinecraftServer.java --- a/src/main/java/net/minecraft/server/MinecraftServer.java
+++ b/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java
@@ -1033,6 +1033,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa @@ -1014,6 +1014,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
} }
public void safeShutdown(boolean waitForShutdown, boolean isRestarting) { public void safeShutdown(boolean waitForShutdown, boolean isRestarting) {
org.purpurmc.purpur.task.BossBarTask.stopAll(); // Purpur org.purpurmc.purpur.task.BossBarTask.stopAll(); // Purpur
@@ -17,12 +17,12 @@ index 3a9fe6d9f2e7406ffc368e2dadaab803b591f5c2..d474e2ce24d822254c1ac0c9d9468ac1
this.hasLoggedStop = true; // Paper this.hasLoggedStop = true; // Paper
if (isDebugging()) io.papermc.paper.util.TraceUtil.dumpTraceForThread("Server stopped"); // Paper if (isDebugging()) io.papermc.paper.util.TraceUtil.dumpTraceForThread("Server stopped"); // Paper
diff --git a/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java b/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java diff --git a/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java b/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java
index c8902e2783026c85eaf0c16541adf67173ed4058..38e2c279d6a846a4d76c15e495bdf464bfcd5b96 100644 index 2075f8f6096178930708268d0c4e2862824cbc45..7b1b34566c38d26ababfc5dafe254749ebc075ea 100644
--- a/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java --- a/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java
+++ b/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java +++ b/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java
@@ -375,6 +375,7 @@ public class DedicatedServer extends MinecraftServer implements ServerInterface @@ -372,6 +372,7 @@ public class DedicatedServer extends MinecraftServer implements ServerInterface
}
if (gg.pufferfish.pufferfish.PufferfishConfig.enableAsyncMobSpawning) mobSpawnExecutor.start(); // Pufferfish
org.purpurmc.purpur.task.BossBarTask.startAll(); // Purpur org.purpurmc.purpur.task.BossBarTask.startAll(); // Purpur
+ org.purpurmc.purpur.task.BeehiveTask.instance().register(); // Purpur + org.purpurmc.purpur.task.BeehiveTask.instance().register(); // Purpur
return true; return true;

View File

@@ -35,10 +35,10 @@ index 56e66fcd840d0d3681ba671d1ffc51b232631461..d566f67f8f6f1748023430de4f191881
org.bukkit.event.Cancellable cancellable; org.bukkit.event.Cancellable cancellable;
if (entity instanceof Player) { if (entity instanceof Player) {
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index a419aa0b06d5215ec66649dde8822120eb91a0f3..948269a1ce9fe56bfa77e02a1671b993d5d44699 100644 index 60beda5c1f3b7ca562b8ba9ff48e0c6e50e89649..3d1107d954d8dd040895908ddadf2c11c437a9ef 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -893,6 +893,7 @@ public class PurpurWorldConfig { @@ -889,6 +889,7 @@ public class PurpurWorldConfig {
public boolean farmlandTramplingDisabled = false; public boolean farmlandTramplingDisabled = false;
public boolean farmlandTramplingOnlyPlayers = false; public boolean farmlandTramplingOnlyPlayers = false;
public boolean farmlandTramplingFeatherFalling = false; public boolean farmlandTramplingFeatherFalling = false;
@@ -46,7 +46,7 @@ index a419aa0b06d5215ec66649dde8822120eb91a0f3..948269a1ce9fe56bfa77e02a1671b993
private void farmlandSettings() { private void farmlandSettings() {
farmlandBypassMobGriefing = getBoolean("blocks.farmland.bypass-mob-griefing", farmlandBypassMobGriefing); farmlandBypassMobGriefing = getBoolean("blocks.farmland.bypass-mob-griefing", farmlandBypassMobGriefing);
farmlandGetsMoistFromBelow = getBoolean("blocks.farmland.gets-moist-from-below", farmlandGetsMoistFromBelow); farmlandGetsMoistFromBelow = getBoolean("blocks.farmland.gets-moist-from-below", farmlandGetsMoistFromBelow);
@@ -900,6 +901,7 @@ public class PurpurWorldConfig { @@ -896,6 +897,7 @@ public class PurpurWorldConfig {
farmlandTramplingDisabled = getBoolean("blocks.farmland.disable-trampling", farmlandTramplingDisabled); farmlandTramplingDisabled = getBoolean("blocks.farmland.disable-trampling", farmlandTramplingDisabled);
farmlandTramplingOnlyPlayers = getBoolean("blocks.farmland.only-players-trample", farmlandTramplingOnlyPlayers); farmlandTramplingOnlyPlayers = getBoolean("blocks.farmland.only-players-trample", farmlandTramplingOnlyPlayers);
farmlandTramplingFeatherFalling = getBoolean("blocks.farmland.feather-fall-distance-affects-trampling", farmlandTramplingFeatherFalling); farmlandTramplingFeatherFalling = getBoolean("blocks.farmland.feather-fall-distance-affects-trampling", farmlandTramplingFeatherFalling);

View File

@@ -22,12 +22,12 @@ index 2bd576849403bc2cfae298c2210616192ddc38db..b2233635b6acc35ea3668c36c56e57f1
int i = this.repairPlayerItems(player, this.value); int i = this.repairPlayerItems(player, this.value);
diff --git a/src/main/java/net/minecraft/world/entity/player/Player.java b/src/main/java/net/minecraft/world/entity/player/Player.java diff --git a/src/main/java/net/minecraft/world/entity/player/Player.java b/src/main/java/net/minecraft/world/entity/player/Player.java
index 0a9d8b22c7127b87826d9d256a5f36c34f2bfc0f..d00035e31cf4773a418d1cc6a6018d08e6b558f0 100644 index 52b4ffc17ac913bf64cf6a6b7a37ae6e5af9bd87..20c3d3c9d2150574e9b4761dc1bda11cee04862f 100644
--- a/src/main/java/net/minecraft/world/entity/player/Player.java --- a/src/main/java/net/minecraft/world/entity/player/Player.java
+++ b/src/main/java/net/minecraft/world/entity/player/Player.java +++ b/src/main/java/net/minecraft/world/entity/player/Player.java
@@ -630,7 +630,7 @@ public abstract class Player extends LivingEntity { @@ -636,7 +636,7 @@ public abstract class Player extends LivingEntity {
for (int i = 0; i < list.size(); ++i) { while (iterator.hasNext()) {
Entity entity = (Entity) list.get(i); Entity entity = (Entity) iterator.next();
- if (entity.getType() == EntityType.EXPERIENCE_ORB) { - if (entity.getType() == EntityType.EXPERIENCE_ORB) {
+ if (entity.getType() == EntityType.EXPERIENCE_ORB && entity.level().purpurConfig.playerExpPickupDelay >= 0) { // Purpur + if (entity.getType() == EntityType.EXPERIENCE_ORB && entity.level().purpurConfig.playerExpPickupDelay >= 0) { // Purpur
@@ -35,10 +35,10 @@ index 0a9d8b22c7127b87826d9d256a5f36c34f2bfc0f..d00035e31cf4773a418d1cc6a6018d08
} else if (!entity.isRemoved()) { } else if (!entity.isRemoved()) {
this.touch(entity); this.touch(entity);
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 948269a1ce9fe56bfa77e02a1671b993d5d44699..365849cce2cacd8c884d1e8e27b1b6723b1bb223 100644 index 3d1107d954d8dd040895908ddadf2c11c437a9ef..f0f83c4570c79ed88275631ee35aa20e5ef27748 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -424,6 +424,7 @@ public class PurpurWorldConfig { @@ -422,6 +422,7 @@ public class PurpurWorldConfig {
public boolean playerRidableInWater = false; public boolean playerRidableInWater = false;
public boolean playerRemoveBindingWithWeakness = false; public boolean playerRemoveBindingWithWeakness = false;
public int shiftRightClickRepairsMendingPoints = 0; public int shiftRightClickRepairsMendingPoints = 0;
@@ -46,7 +46,7 @@ index 948269a1ce9fe56bfa77e02a1671b993d5d44699..365849cce2cacd8c884d1e8e27b1b672
private void playerSettings() { private void playerSettings() {
if (PurpurConfig.version < 19) { if (PurpurConfig.version < 19) {
boolean oldVal = getBoolean("gameplay-mechanics.player.idle-timeout.mods-target", idleTimeoutTargetPlayer); boolean oldVal = getBoolean("gameplay-mechanics.player.idle-timeout.mods-target", idleTimeoutTargetPlayer);
@@ -453,6 +454,7 @@ public class PurpurWorldConfig { @@ -449,6 +450,7 @@ public class PurpurWorldConfig {
playerRidableInWater = getBoolean("gameplay-mechanics.player.ridable-in-water", playerRidableInWater); playerRidableInWater = getBoolean("gameplay-mechanics.player.ridable-in-water", playerRidableInWater);
playerRemoveBindingWithWeakness = getBoolean("gameplay-mechanics.player.curse-of-binding.remove-with-weakness", playerRemoveBindingWithWeakness); playerRemoveBindingWithWeakness = getBoolean("gameplay-mechanics.player.curse-of-binding.remove-with-weakness", playerRemoveBindingWithWeakness);
shiftRightClickRepairsMendingPoints = getInt("gameplay-mechanics.player.shift-right-click-repairs-mending-points", shiftRightClickRepairsMendingPoints); shiftRightClickRepairsMendingPoints = getInt("gameplay-mechanics.player.shift-right-click-repairs-mending-points", shiftRightClickRepairsMendingPoints);

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Allow void trading
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
index 8cbb36b2dbcb9a1470c95746d7d481a142419164..122defeec159165c5fef295ec1dd2da4a6ada622 100644 index cb35bac1923fe40f172a521ce5892e0dcfd7e305..7ded6820b9b0b493a72e158d7a92d5062d2948ef 100644
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java --- a/src/main/java/net/minecraft/server/level/ServerLevel.java
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java +++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
@@ -2837,7 +2837,7 @@ public class ServerLevel extends Level implements WorldGenLevel { @@ -2725,7 +2725,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
// Spigot Start // Spigot Start
if (entity.getBukkitEntity() instanceof org.bukkit.inventory.InventoryHolder && (!(entity instanceof ServerPlayer) || entity.getRemovalReason() != Entity.RemovalReason.KILLED)) { // SPIGOT-6876: closeInventory clears death message if (entity.getBukkitEntity() instanceof org.bukkit.inventory.InventoryHolder && (!(entity instanceof ServerPlayer) || entity.getRemovalReason() != Entity.RemovalReason.KILLED)) { // SPIGOT-6876: closeInventory clears death message
// Paper start // Paper start
@@ -18,10 +18,10 @@ index 8cbb36b2dbcb9a1470c95746d7d481a142419164..122defeec159165c5fef295ec1dd2da4
} }
// Paper end // Paper end
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 365849cce2cacd8c884d1e8e27b1b6723b1bb223..0f12ebf1ce10f66fd329e0b768891607238b52d1 100644 index f0f83c4570c79ed88275631ee35aa20e5ef27748..6008732a98759ac23daab766ea986162b816945f 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -425,6 +425,7 @@ public class PurpurWorldConfig { @@ -423,6 +423,7 @@ public class PurpurWorldConfig {
public boolean playerRemoveBindingWithWeakness = false; public boolean playerRemoveBindingWithWeakness = false;
public int shiftRightClickRepairsMendingPoints = 0; public int shiftRightClickRepairsMendingPoints = 0;
public int playerExpPickupDelay = 2; public int playerExpPickupDelay = 2;
@@ -29,7 +29,7 @@ index 365849cce2cacd8c884d1e8e27b1b6723b1bb223..0f12ebf1ce10f66fd329e0b768891607
private void playerSettings() { private void playerSettings() {
if (PurpurConfig.version < 19) { if (PurpurConfig.version < 19) {
boolean oldVal = getBoolean("gameplay-mechanics.player.idle-timeout.mods-target", idleTimeoutTargetPlayer); boolean oldVal = getBoolean("gameplay-mechanics.player.idle-timeout.mods-target", idleTimeoutTargetPlayer);
@@ -455,6 +456,7 @@ public class PurpurWorldConfig { @@ -451,6 +452,7 @@ public class PurpurWorldConfig {
playerRemoveBindingWithWeakness = getBoolean("gameplay-mechanics.player.curse-of-binding.remove-with-weakness", playerRemoveBindingWithWeakness); playerRemoveBindingWithWeakness = getBoolean("gameplay-mechanics.player.curse-of-binding.remove-with-weakness", playerRemoveBindingWithWeakness);
shiftRightClickRepairsMendingPoints = getInt("gameplay-mechanics.player.shift-right-click-repairs-mending-points", shiftRightClickRepairsMendingPoints); shiftRightClickRepairsMendingPoints = getInt("gameplay-mechanics.player.shift-right-click-repairs-mending-points", shiftRightClickRepairsMendingPoints);
playerExpPickupDelay = getInt("gameplay-mechanics.player.exp-pickup-delay-ticks", playerExpPickupDelay); playerExpPickupDelay = getInt("gameplay-mechanics.player.exp-pickup-delay-ticks", playerExpPickupDelay);

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Configurable phantom size
diff --git a/src/main/java/net/minecraft/world/entity/monster/Phantom.java b/src/main/java/net/minecraft/world/entity/monster/Phantom.java diff --git a/src/main/java/net/minecraft/world/entity/monster/Phantom.java b/src/main/java/net/minecraft/world/entity/monster/Phantom.java
index f71cbaabfff370f019f124203fb947ea7a817d95..17638b9d3340c86528a8ae597712c7590b98dba6 100644 index ab9ed9acc394dedf2151b83ff5cf998e0e0be21e..355445b7f8972cb789d33f59d03c382f238c294d 100644
--- a/src/main/java/net/minecraft/world/entity/monster/Phantom.java --- a/src/main/java/net/minecraft/world/entity/monster/Phantom.java
+++ b/src/main/java/net/minecraft/world/entity/monster/Phantom.java +++ b/src/main/java/net/minecraft/world/entity/monster/Phantom.java
@@ -271,7 +271,11 @@ public class Phantom extends FlyingMob implements Enemy { @@ -272,7 +272,11 @@ public class Phantom extends FlyingMob implements Enemy {
@Override @Override
public SpawnGroupData finalizeSpawn(ServerLevelAccessor world, DifficultyInstance difficulty, MobSpawnType spawnReason, @Nullable SpawnGroupData entityData, @Nullable CompoundTag entityNbt) { public SpawnGroupData finalizeSpawn(ServerLevelAccessor world, DifficultyInstance difficulty, MobSpawnType spawnReason, @Nullable SpawnGroupData entityData, @Nullable CompoundTag entityNbt) {
this.anchorPoint = this.blockPosition().above(5); this.anchorPoint = this.blockPosition().above(5);
@@ -22,10 +22,10 @@ index f71cbaabfff370f019f124203fb947ea7a817d95..17638b9d3340c86528a8ae597712c759
} }
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 0f12ebf1ce10f66fd329e0b768891607238b52d1..fdb99c7565e0b23443d783fa01aa3f9cea5b3132 100644 index 6008732a98759ac23daab766ea986162b816945f..807ca55a5734fccb10b1aae2d99e0b37aeffc614 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -2052,6 +2052,8 @@ public class PurpurWorldConfig { @@ -2048,6 +2048,8 @@ public class PurpurWorldConfig {
public boolean phantomFlamesOnSwoop = false; public boolean phantomFlamesOnSwoop = false;
public boolean phantomTakeDamageFromWater = false; public boolean phantomTakeDamageFromWater = false;
public boolean phantomAlwaysDropExp = false; public boolean phantomAlwaysDropExp = false;
@@ -34,7 +34,7 @@ index 0f12ebf1ce10f66fd329e0b768891607238b52d1..fdb99c7565e0b23443d783fa01aa3f9c
private void phantomSettings() { private void phantomSettings() {
phantomRidable = getBoolean("mobs.phantom.ridable", phantomRidable); phantomRidable = getBoolean("mobs.phantom.ridable", phantomRidable);
phantomRidableInWater = getBoolean("mobs.phantom.ridable-in-water", phantomRidableInWater); phantomRidableInWater = getBoolean("mobs.phantom.ridable-in-water", phantomRidableInWater);
@@ -2088,6 +2090,13 @@ public class PurpurWorldConfig { @@ -2084,6 +2086,13 @@ public class PurpurWorldConfig {
phantomFlamesOnSwoop = getBoolean("mobs.phantom.flames-on-swoop", phantomFlamesOnSwoop); phantomFlamesOnSwoop = getBoolean("mobs.phantom.flames-on-swoop", phantomFlamesOnSwoop);
phantomTakeDamageFromWater = getBoolean("mobs.phantom.takes-damage-from-water", phantomTakeDamageFromWater); phantomTakeDamageFromWater = getBoolean("mobs.phantom.takes-damage-from-water", phantomTakeDamageFromWater);
phantomAlwaysDropExp = getBoolean("mobs.phantom.always-drop-exp", phantomAlwaysDropExp); phantomAlwaysDropExp = getBoolean("mobs.phantom.always-drop-exp", phantomAlwaysDropExp);

View File

@@ -6,10 +6,10 @@ Subject: [PATCH] Max joins per second
When this option is set to true the `max-joins-per-tick` setting in paper.yml will be used per second instead of per tick When this option is set to true the `max-joins-per-tick` setting in paper.yml will be used per second instead of per tick
diff --git a/src/main/java/net/minecraft/network/Connection.java b/src/main/java/net/minecraft/network/Connection.java diff --git a/src/main/java/net/minecraft/network/Connection.java b/src/main/java/net/minecraft/network/Connection.java
index cf20f0983fc25b26cf92b9d3a28746b1909fc56b..89c1b69ddeb420c2fbda5f588e7c9a467a76089d 100644 index 91fcb63835b0b725c53bc75be782b5c5bcc870e7..52639268f0db741e0eb67dc02f9d6e74aeccae6c 100644
--- a/src/main/java/net/minecraft/network/Connection.java --- a/src/main/java/net/minecraft/network/Connection.java
+++ b/src/main/java/net/minecraft/network/Connection.java +++ b/src/main/java/net/minecraft/network/Connection.java
@@ -579,11 +579,20 @@ public class Connection extends SimpleChannelInboundHandler<Packet<?>> { @@ -569,11 +569,20 @@ public class Connection extends SimpleChannelInboundHandler<Packet<?>> {
private static final int MAX_PER_TICK = io.papermc.paper.configuration.GlobalConfiguration.get().misc.maxJoinsPerTick; // Paper private static final int MAX_PER_TICK = io.papermc.paper.configuration.GlobalConfiguration.get().misc.maxJoinsPerTick; // Paper
private static int joinAttemptsThisTick; // Paper private static int joinAttemptsThisTick; // Paper
private static int currTick; // Paper private static int currTick; // Paper

View File

@@ -9,10 +9,10 @@ This patch adds a config option to allow the minimum demand to instead
be configurable. be configurable.
diff --git a/src/main/java/net/minecraft/world/entity/npc/Villager.java b/src/main/java/net/minecraft/world/entity/npc/Villager.java diff --git a/src/main/java/net/minecraft/world/entity/npc/Villager.java b/src/main/java/net/minecraft/world/entity/npc/Villager.java
index 903016cc402bc688f4fd92f339b242db6dfe3841..0d817148dedd9919e6e1dd0c38c96a57ad919ced 100644 index 1e054e727243b9d47cc913f82cf8e026a9f4af44..46a3f321e4673401ee597f779d5f61441e7c3598 100644
--- a/src/main/java/net/minecraft/world/entity/npc/Villager.java --- a/src/main/java/net/minecraft/world/entity/npc/Villager.java
+++ b/src/main/java/net/minecraft/world/entity/npc/Villager.java +++ b/src/main/java/net/minecraft/world/entity/npc/Villager.java
@@ -545,7 +545,7 @@ public class Villager extends AbstractVillager implements ReputationEventHandler @@ -540,7 +540,7 @@ public class Villager extends AbstractVillager implements ReputationEventHandler
while (iterator.hasNext()) { while (iterator.hasNext()) {
MerchantOffer merchantrecipe = (MerchantOffer) iterator.next(); MerchantOffer merchantrecipe = (MerchantOffer) iterator.next();
@@ -22,10 +22,10 @@ index 903016cc402bc688f4fd92f339b242db6dfe3841..0d817148dedd9919e6e1dd0c38c96a57
} }
diff --git a/src/main/java/net/minecraft/world/item/trading/MerchantOffer.java b/src/main/java/net/minecraft/world/item/trading/MerchantOffer.java diff --git a/src/main/java/net/minecraft/world/item/trading/MerchantOffer.java b/src/main/java/net/minecraft/world/item/trading/MerchantOffer.java
index 28bdcb14cb5b458d3c990fcf343ef97f08e4f3c6..48167334162443365bb8a6d082a51b2c626ab3d8 100644 index 4f7457578ab3118d10e0d5dfc23d79c9b20c2f44..e03ce53b93d1b9366f2a7f14f341750a163ae0db 100644
--- a/src/main/java/net/minecraft/world/item/trading/MerchantOffer.java --- a/src/main/java/net/minecraft/world/item/trading/MerchantOffer.java
+++ b/src/main/java/net/minecraft/world/item/trading/MerchantOffer.java +++ b/src/main/java/net/minecraft/world/item/trading/MerchantOffer.java
@@ -134,7 +134,12 @@ public class MerchantOffer { @@ -149,7 +149,12 @@ public class MerchantOffer {
} }
public void updateDemand() { public void updateDemand() {
@@ -40,10 +40,10 @@ index 28bdcb14cb5b458d3c990fcf343ef97f08e4f3c6..48167334162443365bb8a6d082a51b2c
public ItemStack assemble() { public ItemStack assemble() {
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index fdb99c7565e0b23443d783fa01aa3f9cea5b3132..fd141b5aaf45b6ae5aba56143c02f6a54133b9c8 100644 index 807ca55a5734fccb10b1aae2d99e0b37aeffc614..321c625b1374e1a5676459d33f071d62ad45437b 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -2735,6 +2735,7 @@ public class PurpurWorldConfig { @@ -2731,6 +2731,7 @@ public class PurpurWorldConfig {
public boolean villagerTakeDamageFromWater = false; public boolean villagerTakeDamageFromWater = false;
public boolean villagerAllowTrading = true; public boolean villagerAllowTrading = true;
public boolean villagerAlwaysDropExp = false; public boolean villagerAlwaysDropExp = false;
@@ -51,7 +51,7 @@ index fdb99c7565e0b23443d783fa01aa3f9cea5b3132..fd141b5aaf45b6ae5aba56143c02f6a5
private void villagerSettings() { private void villagerSettings() {
villagerRidable = getBoolean("mobs.villager.ridable", villagerRidable); villagerRidable = getBoolean("mobs.villager.ridable", villagerRidable);
villagerRidableInWater = getBoolean("mobs.villager.ridable-in-water", villagerRidableInWater); villagerRidableInWater = getBoolean("mobs.villager.ridable-in-water", villagerRidableInWater);
@@ -2755,6 +2756,7 @@ public class PurpurWorldConfig { @@ -2751,6 +2752,7 @@ public class PurpurWorldConfig {
villagerTakeDamageFromWater = getBoolean("mobs.villager.takes-damage-from-water", villagerTakeDamageFromWater); villagerTakeDamageFromWater = getBoolean("mobs.villager.takes-damage-from-water", villagerTakeDamageFromWater);
villagerAllowTrading = getBoolean("mobs.villager.allow-trading", villagerAllowTrading); villagerAllowTrading = getBoolean("mobs.villager.allow-trading", villagerAllowTrading);
villagerAlwaysDropExp = getBoolean("mobs.villager.always-drop-exp", villagerAlwaysDropExp); villagerAlwaysDropExp = getBoolean("mobs.villager.always-drop-exp", villagerAlwaysDropExp);

View File

@@ -5,19 +5,19 @@ Subject: [PATCH] Lobotomize stuck villagers
diff --git a/src/main/java/net/minecraft/world/entity/npc/Villager.java b/src/main/java/net/minecraft/world/entity/npc/Villager.java diff --git a/src/main/java/net/minecraft/world/entity/npc/Villager.java b/src/main/java/net/minecraft/world/entity/npc/Villager.java
index 0d817148dedd9919e6e1dd0c38c96a57ad919ced..3eb7ac97ea11d0c47ecbc047e2e64c17baaa70f4 100644 index 46a3f321e4673401ee597f779d5f61441e7c3598..d70639fef24b6a8a3b504723992a050edbc16f61 100644
--- a/src/main/java/net/minecraft/world/entity/npc/Villager.java --- a/src/main/java/net/minecraft/world/entity/npc/Villager.java
+++ b/src/main/java/net/minecraft/world/entity/npc/Villager.java +++ b/src/main/java/net/minecraft/world/entity/npc/Villager.java
@@ -140,6 +140,8 @@ public class Villager extends AbstractVillager implements ReputationEventHandler @@ -141,6 +141,8 @@ public class Villager extends AbstractVillager implements ReputationEventHandler
}, MemoryModuleType.MEETING_POINT, (entityvillager, holder) -> { }, MemoryModuleType.MEETING_POINT, (entityvillager, holder) -> {
return holder.is(PoiTypes.MEETING); return holder.is(PoiTypes.MEETING);
}); });
+ private boolean isLobotomized = false; public boolean isLobotomized() { return this.isLobotomized; } // Purpur + private boolean isLobotomized = false; public boolean isLobotomized() { return this.isLobotomized; } // Purpur
+ private int notLobotomizedCount = 0; // Purpur + private int notLobotomizedCount = 0; // Purpur
public long nextGolemPanic = -1; // Pufferfish public Villager(EntityType<? extends Villager> entityType, Level world) {
this(entityType, world, VillagerType.PLAINS);
@@ -199,6 +201,47 @@ public class Villager extends AbstractVillager implements ReputationEventHandler @@ -198,6 +200,47 @@ public class Villager extends AbstractVillager implements ReputationEventHandler
return this.level().purpurConfig.villagerAlwaysDropExp; return this.level().purpurConfig.villagerAlwaysDropExp;
} }
@@ -65,7 +65,7 @@ index 0d817148dedd9919e6e1dd0c38c96a57ad919ced..3eb7ac97ea11d0c47ecbc047e2e64c17
@Override @Override
public Brain<Villager> getBrain() { public Brain<Villager> getBrain() {
return (Brain<Villager>) super.getBrain(); // CraftBukkit - decompile error return (Brain<Villager>) super.getBrain(); // CraftBukkit - decompile error
@@ -296,14 +339,21 @@ public class Villager extends AbstractVillager implements ReputationEventHandler @@ -294,10 +337,21 @@ public class Villager extends AbstractVillager implements ReputationEventHandler
// Paper start // Paper start
this.customServerAiStep(false); this.customServerAiStep(false);
} }
@@ -73,9 +73,7 @@ index 0d817148dedd9919e6e1dd0c38c96a57ad919ced..3eb7ac97ea11d0c47ecbc047e2e64c17
+ protected void customServerAiStep(boolean inactive) { // Purpur - not final + protected void customServerAiStep(boolean inactive) { // Purpur - not final
// Paper end // Paper end
this.level().getProfiler().push("villagerBrain"); this.level().getProfiler().push("villagerBrain");
- // Pufferfish start - //if (!inactive && (getRider() == null || !this.isControllable()) && this.behaviorTick++ % this.activatedPriority == 0) { // Purpur - only use brain if no rider // Purpur - TODO: Pufferfish
- if (!inactive && (getRider() == null || !this.isControllable()) && this.behaviorTick++ % this.activatedPriority == 0) { // Purpur - only use brain if no rider
- this.getBrain().tick((ServerLevel) this.level(), this); // Paper
+ // Purpur start + // Purpur start
+ if (this.level().purpurConfig.villagerLobotomizeEnabled) { + if (this.level().purpurConfig.villagerLobotomizeEnabled) {
+ // treat as inactive if lobotomized + // treat as inactive if lobotomized
@@ -83,20 +81,19 @@ index 0d817148dedd9919e6e1dd0c38c96a57ad919ced..3eb7ac97ea11d0c47ecbc047e2e64c17
+ } else { + } else {
+ // clean up state for API + // clean up state for API
+ this.isLobotomized = false; + this.isLobotomized = false;
} + }
- // Pufferfish end + /*if (!inactive && (getRider() == null || !this.isControllable()) && this.behaviorTick++ % this.activatedPriority == 0) // Purpur - only use brain if no rider // Purpur - TODO: Pufferfish
+ if (!inactive && (getRider() == null || !this.isControllable()) && this.behaviorTick++ % this.activatedPriority == 0) // Purpur - only use brain if no rider
+ this.getBrain().tick((ServerLevel) this.level(), this); // Paper + this.getBrain().tick((ServerLevel) this.level(), this); // Paper
+ else if (this.isLobotomized && shouldRestock()) restock(); + else */if (this.isLobotomized && shouldRestock()) restock();
+ // Purpur end + // Purpur end
if (!inactive) this.getBrain().tick((ServerLevel) this.level(), this); // Paper
this.level().getProfiler().pop(); this.level().getProfiler().pop();
if (this.assignProfessionWhenSpawned) { if (this.assignProfessionWhenSpawned) {
this.assignProfessionWhenSpawned = false;
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftVillager.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftVillager.java diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftVillager.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftVillager.java
index f29e221e5b850516c169c03bfbd2b0885d1a841b..9e343d6e6393db17748fd13d76354464e128001f 100644 index a67b5d20b956e0bf801c9eeb9330567c21927010..15c7dd5ae4ea040b91b665e5ce05c0d35ab1604e 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftVillager.java --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftVillager.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftVillager.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftVillager.java
@@ -216,4 +216,11 @@ public class CraftVillager extends CraftAbstractVillager implements Villager { @@ -252,4 +252,11 @@ public class CraftVillager extends CraftAbstractVillager implements Villager {
getHandle().getGossips().gossips.clear(); getHandle().getGossips().gossips.clear();
} }
// Paper end // Paper end
@@ -109,10 +106,10 @@ index f29e221e5b850516c169c03bfbd2b0885d1a841b..9e343d6e6393db17748fd13d76354464
+ // Purpur end + // Purpur end
} }
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index fd141b5aaf45b6ae5aba56143c02f6a54133b9c8..852d04096a1d2eb747183407f850cc9eafe44e1a 100644 index 321c625b1374e1a5676459d33f071d62ad45437b..3fa481c71331a19b58511392a840f47915639ce2 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -2736,6 +2736,8 @@ public class PurpurWorldConfig { @@ -2732,6 +2732,8 @@ public class PurpurWorldConfig {
public boolean villagerAllowTrading = true; public boolean villagerAllowTrading = true;
public boolean villagerAlwaysDropExp = false; public boolean villagerAlwaysDropExp = false;
public int villagerMinimumDemand = 0; public int villagerMinimumDemand = 0;
@@ -121,7 +118,7 @@ index fd141b5aaf45b6ae5aba56143c02f6a54133b9c8..852d04096a1d2eb747183407f850cc9e
private void villagerSettings() { private void villagerSettings() {
villagerRidable = getBoolean("mobs.villager.ridable", villagerRidable); villagerRidable = getBoolean("mobs.villager.ridable", villagerRidable);
villagerRidableInWater = getBoolean("mobs.villager.ridable-in-water", villagerRidableInWater); villagerRidableInWater = getBoolean("mobs.villager.ridable-in-water", villagerRidableInWater);
@@ -2757,6 +2759,17 @@ public class PurpurWorldConfig { @@ -2753,6 +2755,17 @@ public class PurpurWorldConfig {
villagerAllowTrading = getBoolean("mobs.villager.allow-trading", villagerAllowTrading); villagerAllowTrading = getBoolean("mobs.villager.allow-trading", villagerAllowTrading);
villagerAlwaysDropExp = getBoolean("mobs.villager.always-drop-exp", villagerAlwaysDropExp); villagerAlwaysDropExp = getBoolean("mobs.villager.always-drop-exp", villagerAlwaysDropExp);
villagerMinimumDemand = getInt("mobs.villager.minimum-demand", villagerMinimumDemand); villagerMinimumDemand = getInt("mobs.villager.minimum-demand", villagerMinimumDemand);

View File

@@ -5,7 +5,7 @@ Subject: [PATCH] Option for villager display trade item
diff --git a/src/main/java/net/minecraft/world/entity/ai/behavior/ShowTradesToPlayer.java b/src/main/java/net/minecraft/world/entity/ai/behavior/ShowTradesToPlayer.java diff --git a/src/main/java/net/minecraft/world/entity/ai/behavior/ShowTradesToPlayer.java b/src/main/java/net/minecraft/world/entity/ai/behavior/ShowTradesToPlayer.java
index 050be72c815010bf3f4b72427e2052b00420e8ee..8a213205f57c8dcd2226d7194d74b1b13dec5a78 100644 index c3e0b1f11b58668f9f24eb421abc340e1b49dfac..d809fa4f96e2c528075f544355397903996ecaf6 100644
--- a/src/main/java/net/minecraft/world/entity/ai/behavior/ShowTradesToPlayer.java --- a/src/main/java/net/minecraft/world/entity/ai/behavior/ShowTradesToPlayer.java
+++ b/src/main/java/net/minecraft/world/entity/ai/behavior/ShowTradesToPlayer.java +++ b/src/main/java/net/minecraft/world/entity/ai/behavior/ShowTradesToPlayer.java
@@ -42,6 +42,7 @@ public class ShowTradesToPlayer extends Behavior<Villager> { @@ -42,6 +42,7 @@ public class ShowTradesToPlayer extends Behavior<Villager> {
@@ -17,10 +17,10 @@ index 050be72c815010bf3f4b72427e2052b00420e8ee..8a213205f57c8dcd2226d7194d74b1b1
} }
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 852d04096a1d2eb747183407f850cc9eafe44e1a..265858cc747ed26c98cfea2caf27a9a0f7ea5198 100644 index 3fa481c71331a19b58511392a840f47915639ce2..38d13eb230cfb33a450b8a9a1a3c6aa2efe5b053 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -2738,6 +2738,7 @@ public class PurpurWorldConfig { @@ -2734,6 +2734,7 @@ public class PurpurWorldConfig {
public int villagerMinimumDemand = 0; public int villagerMinimumDemand = 0;
public boolean villagerLobotomizeEnabled = false; public boolean villagerLobotomizeEnabled = false;
public int villagerLobotomizeCheckInterval = 100; public int villagerLobotomizeCheckInterval = 100;
@@ -28,7 +28,7 @@ index 852d04096a1d2eb747183407f850cc9eafe44e1a..265858cc747ed26c98cfea2caf27a9a0
private void villagerSettings() { private void villagerSettings() {
villagerRidable = getBoolean("mobs.villager.ridable", villagerRidable); villagerRidable = getBoolean("mobs.villager.ridable", villagerRidable);
villagerRidableInWater = getBoolean("mobs.villager.ridable-in-water", villagerRidableInWater); villagerRidableInWater = getBoolean("mobs.villager.ridable-in-water", villagerRidableInWater);
@@ -2770,6 +2771,7 @@ public class PurpurWorldConfig { @@ -2766,6 +2767,7 @@ public class PurpurWorldConfig {
} }
villagerLobotomizeEnabled = getBoolean("mobs.villager.lobotomize.enabled", villagerLobotomizeEnabled); villagerLobotomizeEnabled = getBoolean("mobs.villager.lobotomize.enabled", villagerLobotomizeEnabled);
villagerLobotomizeCheckInterval = getInt("mobs.villager.lobotomize.check-interval", villagerLobotomizeCheckInterval); villagerLobotomizeCheckInterval = getInt("mobs.villager.lobotomize.check-interval", villagerLobotomizeCheckInterval);

View File

@@ -17,10 +17,10 @@ index cd2ce5bcb8c30e4657cd0e340d80544c7e805905..c8c6fed3f93903bb5c6145930538d415
} }
} }
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 265858cc747ed26c98cfea2caf27a9a0f7ea5198..15024b91f36fc2e2ab1942bc952d8f1619c94a47 100644 index 38d13eb230cfb33a450b8a9a1a3c6aa2efe5b053..db1e6276243ee849757bed15f8308474afe56790 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -1002,8 +1002,10 @@ public class PurpurWorldConfig { @@ -998,8 +998,10 @@ public class PurpurWorldConfig {
} }
public boolean spawnerDeactivateByRedstone = false; public boolean spawnerDeactivateByRedstone = false;

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Config for mob last hurt by player time
diff --git a/src/main/java/net/minecraft/world/entity/LivingEntity.java b/src/main/java/net/minecraft/world/entity/LivingEntity.java diff --git a/src/main/java/net/minecraft/world/entity/LivingEntity.java b/src/main/java/net/minecraft/world/entity/LivingEntity.java
index 4758e9376e144e3baec2423a26f970ad03aa1565..4d13f2645ae9e76ed7b36d381ae24cd826e722b3 100644 index 11761085514d54e23fece41a408b74a2bde3effc..9e07866c6597b62eb02985770c1fcffe6fb3f601 100644
--- a/src/main/java/net/minecraft/world/entity/LivingEntity.java --- a/src/main/java/net/minecraft/world/entity/LivingEntity.java
+++ b/src/main/java/net/minecraft/world/entity/LivingEntity.java +++ b/src/main/java/net/minecraft/world/entity/LivingEntity.java
@@ -1506,13 +1506,13 @@ public abstract class LivingEntity extends Entity implements Attackable { @@ -1526,13 +1526,13 @@ public abstract class LivingEntity extends Entity implements Attackable {
if (entity1 instanceof net.minecraft.world.entity.player.Player) { if (entity1 instanceof net.minecraft.world.entity.player.Player) {
net.minecraft.world.entity.player.Player entityhuman = (net.minecraft.world.entity.player.Player) entity1; net.minecraft.world.entity.player.Player entityhuman = (net.minecraft.world.entity.player.Player) entity1;
@@ -25,7 +25,7 @@ index 4758e9376e144e3baec2423a26f970ad03aa1565..4d13f2645ae9e76ed7b36d381ae24cd8
if (entityliving2 instanceof net.minecraft.world.entity.player.Player) { if (entityliving2 instanceof net.minecraft.world.entity.player.Player) {
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java
index 7f1c7532adace841baec500598133981a6feb78a..99dd93c066d4acc177de7f03ae45e491b535f4d1 100644 index 5ca34447926510f1d4c5c5ba9eb3c7c6369a85de..4e11a5eb37998deba9eea2663ac2c7fb92de8acc 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java
@@ -453,7 +453,7 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity { @@ -453,7 +453,7 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity {
@@ -38,7 +38,7 @@ index 7f1c7532adace841baec500598133981a6feb78a..99dd93c066d4acc177de7f03ae45e491
// Paper end // Paper end
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 15024b91f36fc2e2ab1942bc952d8f1619c94a47..1ab0127d72fb6c8f7c3999768c7078dad1fced70 100644 index db1e6276243ee849757bed15f8308474afe56790..a5e9e56c86de0ae3b8053367dac777c94a990a30 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -142,6 +142,7 @@ public class PurpurWorldConfig { @@ -142,6 +142,7 @@ public class PurpurWorldConfig {

View File

@@ -64,10 +64,10 @@ index 5c5a3b169795bf8a527b316c666cbc2105c66622..020afeca950d2c7fb6c7b179d424548f
return InteractionResult.SUCCESS; return InteractionResult.SUCCESS;
} else { } else {
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 1ab0127d72fb6c8f7c3999768c7078dad1fced70..a279fdf4598af127b87bf21f8b74df15a1bd2664 100644 index a5e9e56c86de0ae3b8053367dac777c94a990a30..6ae50abd3d1bb4e5ff6f8865ca6f4303c8144b0e 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -754,9 +754,13 @@ public class PurpurWorldConfig { @@ -750,9 +750,13 @@ public class PurpurWorldConfig {
public boolean anvilAllowColors = false; public boolean anvilAllowColors = false;
public boolean anvilColorsUseMiniMessage; public boolean anvilColorsUseMiniMessage;

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Option to disable turtle egg trampling with feather falling
diff --git a/src/main/java/net/minecraft/world/level/block/TurtleEggBlock.java b/src/main/java/net/minecraft/world/level/block/TurtleEggBlock.java diff --git a/src/main/java/net/minecraft/world/level/block/TurtleEggBlock.java b/src/main/java/net/minecraft/world/level/block/TurtleEggBlock.java
index b211d7b37095b52424ead1bb0be0c81bc4322985..58facc048840d3ba0a58c92673340e6e0aa4e305 100644 index 8e975daca6a50c95d7fb620f2756b8bb2b7c7d6b..e23b920be6702ef6faf97b42fb8a87442707d6be 100644
--- a/src/main/java/net/minecraft/world/level/block/TurtleEggBlock.java --- a/src/main/java/net/minecraft/world/level/block/TurtleEggBlock.java
+++ b/src/main/java/net/minecraft/world/level/block/TurtleEggBlock.java +++ b/src/main/java/net/minecraft/world/level/block/TurtleEggBlock.java
@@ -209,7 +209,13 @@ public class TurtleEggBlock extends Block { @@ -211,7 +211,13 @@ public class TurtleEggBlock extends Block {
if (!(entity instanceof LivingEntity)) { if (!(entity instanceof LivingEntity)) {
return false; return false;
} }
@@ -24,10 +24,10 @@ index b211d7b37095b52424ead1bb0be0c81bc4322985..58facc048840d3ba0a58c92673340e6e
return world.purpurConfig.turtleEggsBypassMobGriefing || world.getGameRules().getBoolean(GameRules.RULE_MOBGRIEFING); return world.purpurConfig.turtleEggsBypassMobGriefing || world.getGameRules().getBoolean(GameRules.RULE_MOBGRIEFING);
// Purpur end // Purpur end
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index a279fdf4598af127b87bf21f8b74df15a1bd2664..64d7eb44358835c6293f02cb427785615a9ea874 100644 index 6ae50abd3d1bb4e5ff6f8865ca6f4303c8144b0e..ce4f8f9661c6c0d09fa517861aae80559859f09f 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -1030,12 +1030,14 @@ public class PurpurWorldConfig { @@ -1026,12 +1026,14 @@ public class PurpurWorldConfig {
public boolean turtleEggsBreakFromMinecarts = true; public boolean turtleEggsBreakFromMinecarts = true;
public boolean turtleEggsBypassMobGriefing = false; public boolean turtleEggsBypassMobGriefing = false;
public int turtleEggsRandomTickCrackChance = 500; public int turtleEggsRandomTickCrackChance = 500;

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Add toggle for enchant level clamping
diff --git a/src/main/java/net/minecraft/world/item/ItemStack.java b/src/main/java/net/minecraft/world/item/ItemStack.java diff --git a/src/main/java/net/minecraft/world/item/ItemStack.java b/src/main/java/net/minecraft/world/item/ItemStack.java
index 832cf93ee9d29e9eb324909ab04be8e769ce1f67..dec5c808a56e3f0eeffad8da6f81041029a8706b 100644 index dfb2852a4fa1a8b8ffe7817c3cf63d87abaf1a82..6c7f0db683101e12ae48dc3f28d5d00ac9569e35 100644
--- a/src/main/java/net/minecraft/world/item/ItemStack.java --- a/src/main/java/net/minecraft/world/item/ItemStack.java
+++ b/src/main/java/net/minecraft/world/item/ItemStack.java +++ b/src/main/java/net/minecraft/world/item/ItemStack.java
@@ -1202,7 +1202,7 @@ public final class ItemStack { @@ -1207,7 +1207,7 @@ public final class ItemStack {
ListTag nbttaglist = this.tag.getList("Enchantments", 10); ListTag nbttaglist = this.tag.getList("Enchantments", 10);

View File

@@ -6,10 +6,10 @@ Subject: [PATCH] Implement configurable search radius for villagers to spawn
diff --git a/src/main/java/net/minecraft/world/entity/npc/Villager.java b/src/main/java/net/minecraft/world/entity/npc/Villager.java diff --git a/src/main/java/net/minecraft/world/entity/npc/Villager.java b/src/main/java/net/minecraft/world/entity/npc/Villager.java
index 3eb7ac97ea11d0c47ecbc047e2e64c17baaa70f4..85c8854691070d8867a5eaf410fe7a2f75fadb9f 100644 index d70639fef24b6a8a3b504723992a050edbc16f61..99928a3a8954be0d5b1f7736c12dbbb10d4c508c 100644
--- a/src/main/java/net/minecraft/world/entity/npc/Villager.java --- a/src/main/java/net/minecraft/world/entity/npc/Villager.java
+++ b/src/main/java/net/minecraft/world/entity/npc/Villager.java +++ b/src/main/java/net/minecraft/world/entity/npc/Villager.java
@@ -1092,6 +1092,7 @@ public class Villager extends AbstractVillager implements ReputationEventHandler @@ -1099,6 +1099,7 @@ public class Villager extends AbstractVillager implements ReputationEventHandler
} }
public void spawnGolemIfNeeded(ServerLevel world, long time, int requiredCount) { public void spawnGolemIfNeeded(ServerLevel world, long time, int requiredCount) {
@@ -18,10 +18,10 @@ index 3eb7ac97ea11d0c47ecbc047e2e64c17baaa70f4..85c8854691070d8867a5eaf410fe7a2f
AABB axisalignedbb = this.getBoundingBox().inflate(10.0D, 10.0D, 10.0D); AABB axisalignedbb = this.getBoundingBox().inflate(10.0D, 10.0D, 10.0D);
List<Villager> list = world.getEntitiesOfClass(Villager.class, axisalignedbb); List<Villager> list = world.getEntitiesOfClass(Villager.class, axisalignedbb);
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 64d7eb44358835c6293f02cb427785615a9ea874..147c25389a57da3d13c513225488d4e1160a7831 100644 index ce4f8f9661c6c0d09fa517861aae80559859f09f..b964bad8d599e093ad312a9dedf1a33856ce9ec1 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -2749,6 +2749,8 @@ public class PurpurWorldConfig { @@ -2745,6 +2745,8 @@ public class PurpurWorldConfig {
public boolean villagerLobotomizeEnabled = false; public boolean villagerLobotomizeEnabled = false;
public int villagerLobotomizeCheckInterval = 100; public int villagerLobotomizeCheckInterval = 100;
public boolean villagerDisplayTradeItem = true; public boolean villagerDisplayTradeItem = true;
@@ -30,7 +30,7 @@ index 64d7eb44358835c6293f02cb427785615a9ea874..147c25389a57da3d13c513225488d4e1
private void villagerSettings() { private void villagerSettings() {
villagerRidable = getBoolean("mobs.villager.ridable", villagerRidable); villagerRidable = getBoolean("mobs.villager.ridable", villagerRidable);
villagerRidableInWater = getBoolean("mobs.villager.ridable-in-water", villagerRidableInWater); villagerRidableInWater = getBoolean("mobs.villager.ridable-in-water", villagerRidableInWater);
@@ -2782,6 +2784,8 @@ public class PurpurWorldConfig { @@ -2778,6 +2780,8 @@ public class PurpurWorldConfig {
villagerLobotomizeEnabled = getBoolean("mobs.villager.lobotomize.enabled", villagerLobotomizeEnabled); villagerLobotomizeEnabled = getBoolean("mobs.villager.lobotomize.enabled", villagerLobotomizeEnabled);
villagerLobotomizeCheckInterval = getInt("mobs.villager.lobotomize.check-interval", villagerLobotomizeCheckInterval); villagerLobotomizeCheckInterval = getInt("mobs.villager.lobotomize.check-interval", villagerLobotomizeCheckInterval);
villagerDisplayTradeItem = getBoolean("mobs.villager.display-trade-item", villagerDisplayTradeItem); villagerDisplayTradeItem = getBoolean("mobs.villager.display-trade-item", villagerDisplayTradeItem);

View File

@@ -5,7 +5,7 @@ Subject: [PATCH] Stonecutter damage
diff --git a/src/main/java/net/minecraft/world/damagesource/CombatTracker.java b/src/main/java/net/minecraft/world/damagesource/CombatTracker.java diff --git a/src/main/java/net/minecraft/world/damagesource/CombatTracker.java b/src/main/java/net/minecraft/world/damagesource/CombatTracker.java
index c6f8ae130b75fbb0ad41f9a5917e934e33fd3043..45e4717ba832edceeafdba575323c2527c350193 100644 index 9e3608650c44ef5fa724c3aea86603d7bd02429c..8c2c515f1b5f56bf1d6cf0c35d4f0fa7b593d1a0 100644
--- a/src/main/java/net/minecraft/world/damagesource/CombatTracker.java --- a/src/main/java/net/minecraft/world/damagesource/CombatTracker.java
+++ b/src/main/java/net/minecraft/world/damagesource/CombatTracker.java +++ b/src/main/java/net/minecraft/world/damagesource/CombatTracker.java
@@ -102,6 +102,8 @@ public class CombatTracker { @@ -102,6 +102,8 @@ public class CombatTracker {
@@ -90,7 +90,7 @@ index d976a6df54c1e817def2d588692abe25a03ee0fa..ba57accc272958da4714896baeadb52c
return BlockPathTypes.STICKY_HONEY; return BlockPathTypes.STICKY_HONEY;
} else if (blockState.is(Blocks.COCOA)) { } else if (blockState.is(Blocks.COCOA)) {
diff --git a/src/main/java/org/purpurmc/purpur/PurpurConfig.java b/src/main/java/org/purpurmc/purpur/PurpurConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurConfig.java b/src/main/java/org/purpurmc/purpur/PurpurConfig.java
index 33a67078ba6ecc11d2929a164354702664d6a480..15eb4403deefca5f16052a74bbd9059091ed4c3f 100644 index 4d147845402a26957c905dd600bf0657bb7bd714..e78e809cc7644d5007b149d5940f8cc164a76975 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurConfig.java
@@ -209,8 +209,10 @@ public class PurpurConfig { @@ -209,8 +209,10 @@ public class PurpurConfig {
@@ -105,10 +105,10 @@ index 33a67078ba6ecc11d2929a164354702664d6a480..15eb4403deefca5f16052a74bbd90590
public static boolean advancementOnlyBroadcastToAffectedPlayer = false; public static boolean advancementOnlyBroadcastToAffectedPlayer = false;
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 147c25389a57da3d13c513225488d4e1160a7831..fe5fe3faab9fd7977139181cc8a40dd16e06e23d 100644 index b964bad8d599e093ad312a9dedf1a33856ce9ec1..417322e7cf09eb56acf5fc398ce2319b54c4477a 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -1025,6 +1025,11 @@ public class PurpurWorldConfig { @@ -1021,6 +1021,11 @@ public class PurpurWorldConfig {
spongeAbsorbsWaterFromMud = getBoolean("blocks.sponge.absorbs-water-from-mud", spongeAbsorbsWaterFromMud); spongeAbsorbsWaterFromMud = getBoolean("blocks.sponge.absorbs-water-from-mud", spongeAbsorbsWaterFromMud);
} }

View File

@@ -18,10 +18,10 @@ index 1b766045687e4dcded5cbcc50b746c55b9a34e22..be365914856593bb3c4e1945cc990786
entity.hurt(world.damageSources().hotFloor(), 1.0F); entity.hurt(world.damageSources().hotFloor(), 1.0F);
org.bukkit.craftbukkit.event.CraftEventFactory.blockDamage = null; // CraftBukkit org.bukkit.craftbukkit.event.CraftEventFactory.blockDamage = null; // CraftBukkit
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index fe5fe3faab9fd7977139181cc8a40dd16e06e23d..6e37d135cb88443cdbb379ea2a90374bf1383ec7 100644 index 417322e7cf09eb56acf5fc398ce2319b54c4477a..93e601cad7c26024fe195ee5217c8d65c1b083e4 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -956,6 +956,13 @@ public class PurpurWorldConfig { @@ -952,6 +952,13 @@ public class PurpurWorldConfig {
pistonBlockPushLimit = getInt("blocks.piston.block-push-limit", pistonBlockPushLimit); pistonBlockPushLimit = getInt("blocks.piston.block-push-limit", pistonBlockPushLimit);
} }

View File

@@ -22,10 +22,10 @@ index 14e00c7feb1c051d56a3d27cd00dcef072dd771a..4952fb1aaaafb55baa0fddb389f966a1
} }
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 6e37d135cb88443cdbb379ea2a90374bf1383ec7..67266a22f05ffc94a375af873339a9c718ddd66c 100644 index 93e601cad7c26024fe195ee5217c8d65c1b083e4..ea082eed28b9d63514291a094ebd99b8670e7910 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -937,9 +937,11 @@ public class PurpurWorldConfig { @@ -933,9 +933,11 @@ public class PurpurWorldConfig {
public boolean mobsSpawnOnPackedIce = true; public boolean mobsSpawnOnPackedIce = true;
public boolean mobsSpawnOnBlueIce = true; public boolean mobsSpawnOnBlueIce = true;

View File

@@ -94,10 +94,10 @@ index 9b43150a00d7fac85aa69f5a2dbffd0dfdae4b86..f4a47ac2c86cc95178922cce7320ba1e
+ // Purpur end + // Purpur end
} }
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 67266a22f05ffc94a375af873339a9c718ddd66c..13413402b516f892264072f4061c509d7ed1d94c 100644 index ea082eed28b9d63514291a094ebd99b8670e7910..40f127476d96b39ac107cb1d18dd08798612c952 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -2433,6 +2433,7 @@ public class PurpurWorldConfig { @@ -2429,6 +2429,7 @@ public class PurpurWorldConfig {
public boolean skeletonTakeDamageFromWater = false; public boolean skeletonTakeDamageFromWater = false;
public boolean skeletonAlwaysDropExp = false; public boolean skeletonAlwaysDropExp = false;
public double skeletonHeadVisibilityPercent = 0.5D; public double skeletonHeadVisibilityPercent = 0.5D;
@@ -105,7 +105,7 @@ index 67266a22f05ffc94a375af873339a9c718ddd66c..13413402b516f892264072f4061c509d
private void skeletonSettings() { private void skeletonSettings() {
skeletonRidable = getBoolean("mobs.skeleton.ridable", skeletonRidable); skeletonRidable = getBoolean("mobs.skeleton.ridable", skeletonRidable);
skeletonRidableInWater = getBoolean("mobs.skeleton.ridable-in-water", skeletonRidableInWater); skeletonRidableInWater = getBoolean("mobs.skeleton.ridable-in-water", skeletonRidableInWater);
@@ -2446,6 +2447,7 @@ public class PurpurWorldConfig { @@ -2442,6 +2443,7 @@ public class PurpurWorldConfig {
skeletonTakeDamageFromWater = getBoolean("mobs.skeleton.takes-damage-from-water", skeletonTakeDamageFromWater); skeletonTakeDamageFromWater = getBoolean("mobs.skeleton.takes-damage-from-water", skeletonTakeDamageFromWater);
skeletonAlwaysDropExp = getBoolean("mobs.skeleton.always-drop-exp", skeletonAlwaysDropExp); skeletonAlwaysDropExp = getBoolean("mobs.skeleton.always-drop-exp", skeletonAlwaysDropExp);
skeletonHeadVisibilityPercent = getDouble("mobs.skeleton.head-visibility-percent", skeletonHeadVisibilityPercent); skeletonHeadVisibilityPercent = getDouble("mobs.skeleton.head-visibility-percent", skeletonHeadVisibilityPercent);

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Enchantment Table Persists Lapis
diff --git a/src/main/java/net/minecraft/world/inventory/EnchantmentMenu.java b/src/main/java/net/minecraft/world/inventory/EnchantmentMenu.java diff --git a/src/main/java/net/minecraft/world/inventory/EnchantmentMenu.java b/src/main/java/net/minecraft/world/inventory/EnchantmentMenu.java
index 93e8316f9d64625dcc4df0644a2187bcc884ef65..1711406996ec4a9cb7b1838bd2446e5cf802e043 100644 index c5c509fbb915c60dfa95aac8510684d0b9f8b0ff..d604b7ec46f08993647979ed220a84842e3fe325 100644
--- a/src/main/java/net/minecraft/world/inventory/EnchantmentMenu.java --- a/src/main/java/net/minecraft/world/inventory/EnchantmentMenu.java
+++ b/src/main/java/net/minecraft/world/inventory/EnchantmentMenu.java +++ b/src/main/java/net/minecraft/world/inventory/EnchantmentMenu.java
@@ -38,6 +38,12 @@ import org.bukkit.event.enchantment.PrepareItemEnchantEvent; @@ -40,6 +40,12 @@ import org.bukkit.event.enchantment.PrepareItemEnchantEvent;
import org.bukkit.entity.Player; import org.bukkit.entity.Player;
// CraftBukkit end // CraftBukkit end
@@ -20,8 +20,8 @@ index 93e8316f9d64625dcc4df0644a2187bcc884ef65..1711406996ec4a9cb7b1838bd2446e5c
+ +
public class EnchantmentMenu extends AbstractContainerMenu { public class EnchantmentMenu extends AbstractContainerMenu {
private final Container enchantSlots; static final ResourceLocation EMPTY_SLOT_LAPIS_LAZULI = new ResourceLocation("item/empty_slot_lapis_lazuli");
@@ -71,6 +77,22 @@ public class EnchantmentMenu extends AbstractContainerMenu { @@ -74,6 +80,22 @@ public class EnchantmentMenu extends AbstractContainerMenu {
return context.getLocation(); return context.getLocation();
} }
// CraftBukkit end // CraftBukkit end
@@ -44,7 +44,7 @@ index 93e8316f9d64625dcc4df0644a2187bcc884ef65..1711406996ec4a9cb7b1838bd2446e5c
}; };
this.random = RandomSource.create(); this.random = RandomSource.create();
this.enchantmentSeed = DataSlot.standalone(); this.enchantmentSeed = DataSlot.standalone();
@@ -96,6 +118,17 @@ public class EnchantmentMenu extends AbstractContainerMenu { @@ -99,6 +121,17 @@ public class EnchantmentMenu extends AbstractContainerMenu {
} }
}); });
@@ -62,7 +62,7 @@ index 93e8316f9d64625dcc4df0644a2187bcc884ef65..1711406996ec4a9cb7b1838bd2446e5c
int j; int j;
for (j = 0; j < 3; ++j) { for (j = 0; j < 3; ++j) {
@@ -340,6 +373,7 @@ public class EnchantmentMenu extends AbstractContainerMenu { @@ -344,6 +377,7 @@ public class EnchantmentMenu extends AbstractContainerMenu {
public void removed(net.minecraft.world.entity.player.Player player) { public void removed(net.minecraft.world.entity.player.Player player) {
super.removed(player); super.removed(player);
this.access.execute((world, blockposition) -> { this.access.execute((world, blockposition) -> {
@@ -146,10 +146,10 @@ index 65e1381bb2d10bd212463feb602c60f8fdb9ade1..b7370e64fd0d50e8725d7d5afc30af2e
+ // Purpur + // Purpur
} }
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 13413402b516f892264072f4061c509d7ed1d94c..261d451d47c00ea36748e4f610a2f1e27a4b6ab4 100644 index 40f127476d96b39ac107cb1d18dd08798612c952..9c90c8f1c6697a98049bf044ac061bb93e1a4363 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -1468,6 +1468,11 @@ public class PurpurWorldConfig { @@ -1464,6 +1464,11 @@ public class PurpurWorldConfig {
elderGuardianAlwaysDropExp = getBoolean("mobs.elder_guardian.always-drop-exp", elderGuardianAlwaysDropExp); elderGuardianAlwaysDropExp = getBoolean("mobs.elder_guardian.always-drop-exp", elderGuardianAlwaysDropExp);
} }

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Option to disable kick for out of order chat
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
index cb1851fca9290edb502662c100bb2ac6fa4d70d1..b1050654cca5ce8a834c9e913b8e804609499aa9 100644 index 70eaf9347d49924841f2cfa23932b3eadfe49c82..87e064670d336f1c3a86cdc524e2686c7ee5af72 100644
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -2510,7 +2510,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic @@ -2336,7 +2336,7 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl
do { do {
instant1 = (Instant) this.lastChatTimeStamp.get(); instant1 = (Instant) this.lastChatTimeStamp.get();
if (timestamp.isBefore(instant1)) { if (timestamp.isBefore(instant1)) {

View File

@@ -18,10 +18,10 @@ index 02d01eabb9606ae8c3b76ad9fa4bb9a525e247b1..ce51fec4a874f9466f9966684c535315
@Override @Override
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 261d451d47c00ea36748e4f610a2f1e27a4b6ab4..9f7ca8b8f79fdea1dc664639dc1f09c76610a043 100644 index 9c90c8f1c6697a98049bf044ac061bb93e1a4363..2f7a5fd20ace3f27edc79c0f4a7bb4e4a772b3f8 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -1001,6 +1001,11 @@ public class PurpurWorldConfig { @@ -997,6 +997,11 @@ public class PurpurWorldConfig {
fixSandDuping = getBoolean("blocks.sand.fix-duping", fixSandDuping); fixSandDuping = getBoolean("blocks.sand.fix-duping", fixSandDuping);
} }

View File

@@ -29,10 +29,10 @@ index 88faea00be60a519f56f975a5311df5e1eb3e6b8..cbb726ac367be81e27d3a86643baf7c4
int i = aenumdirection.length; int i = aenumdirection.length;
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 9f7ca8b8f79fdea1dc664639dc1f09c76610a043..ce7c96dd55ad88ad35fef9aa992952b8ac333d06 100644 index 2f7a5fd20ace3f27edc79c0f4a7bb4e4a772b3f8..4351793923ea16e3c3fe7ed547c1236cae0e952a 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -838,6 +838,11 @@ public class PurpurWorldConfig { @@ -834,6 +834,11 @@ public class PurpurWorldConfig {
composterBulkProcess = getBoolean("blocks.composter.sneak-to-bulk-process", composterBulkProcess); composterBulkProcess = getBoolean("blocks.composter.sneak-to-bulk-process", composterBulkProcess);
} }

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Add local difficulty api
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
index f857f490ffba2f25f7c06c5fb1a1905f0b51fbe2..a2e852adf47261b1b2eb9734cc90f4676ed58126 100644 index 7aef2714791674086246ab4b5b92c8965dbfdae0..e55438768a030cdcef433782e55f0fafc4f51db1 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
@@ -2290,6 +2290,12 @@ public class CraftWorld extends CraftRegionAccessor implements World { @@ -2284,6 +2284,12 @@ public class CraftWorld extends CraftRegionAccessor implements World {
return (this.getHandle().getDragonFight() == null) ? null : new CraftDragonBattle(this.getHandle().getDragonFight()); return (this.getHandle().getDragonFight() == null) ? null : new CraftDragonBattle(this.getHandle().getDragonFight());
} }

View File

@@ -7,10 +7,10 @@ Paper patches RNG maniplulation by using a shared (and locked) random source.
This comes with a performance gain, but technical players may prefer the ability to manipulate RNG. This comes with a performance gain, but technical players may prefer the ability to manipulate RNG.
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
index c99d273b8d686872d5699e4490769786951256e1..156c2683d72c5e83b1cefb9ebf356c6e4d31e7f4 100644 index e78d85a313f585ec9c7fe9895402591b7b10d6b9..28cac00d496cc6e37648dbe96ba4aea2b834cedd 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java --- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -616,7 +616,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { @@ -555,7 +555,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource {
this.bb = Entity.INITIAL_AABB; this.bb = Entity.INITIAL_AABB;
this.stuckSpeedMultiplier = Vec3.ZERO; this.stuckSpeedMultiplier = Vec3.ZERO;
this.nextStep = 1.0F; this.nextStep = 1.0F;
@@ -33,7 +33,7 @@ index 88c238e492b1081d1a64a3b6f05d7baa17e5d8c9..dd7f2beabf0edad4143ac2365ac04a22
} }
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index ce7c96dd55ad88ad35fef9aa992952b8ac333d06..370b5ff992fb3ff7dd88ab479b3c251d36ced42f 100644 index 4351793923ea16e3c3fe7ed547c1236cae0e952a..07b8826509d158e60ee6c3c847f7855b7469325f 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -204,9 +204,11 @@ public class PurpurWorldConfig { @@ -204,9 +204,11 @@ public class PurpurWorldConfig {

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] PaperPR #7822 Fix exact choice recipe book clicks
diff --git a/src/main/java/net/minecraft/world/entity/player/StackedContents.java b/src/main/java/net/minecraft/world/entity/player/StackedContents.java diff --git a/src/main/java/net/minecraft/world/entity/player/StackedContents.java b/src/main/java/net/minecraft/world/entity/player/StackedContents.java
index 68d272e98f9e54c9b150c75c27a9ae545be842f6..63fc6074082b579c3f88316008cbeb2a2d7f5841 100644 index 26b236a764177ac16d53f5cbaf83d3e21d015ebc..6bc60ea5249cca9f4c1d029a2b7460fe3476e05a 100644
--- a/src/main/java/net/minecraft/world/entity/player/StackedContents.java --- a/src/main/java/net/minecraft/world/entity/player/StackedContents.java
+++ b/src/main/java/net/minecraft/world/entity/player/StackedContents.java +++ b/src/main/java/net/minecraft/world/entity/player/StackedContents.java
@@ -40,8 +40,62 @@ public class StackedContents { @@ -41,8 +41,62 @@ public class StackedContents {
int j = Math.min(maxCount, stack.getCount()); int j = Math.min(maxCount, stack.getCount());
if (this.extrasMap != null && stack.hasTag() && this.extrasMap.accountStack(stack, j)) return; // Paper - if an exact ingredient, don't include it if (this.extrasMap != null && stack.hasTag() && this.extrasMap.accountStack(stack, j)) return; // Paper - if an exact ingredient, don't include it
this.put(i, j); this.put(i, j);
@@ -71,7 +71,7 @@ index 68d272e98f9e54c9b150c75c27a9ae545be842f6..63fc6074082b579c3f88316008cbeb2a
} }
public static int getStackingIndex(ItemStack stack) { public static int getStackingIndex(ItemStack stack) {
@@ -83,6 +137,12 @@ public class StackedContents { @@ -84,6 +138,12 @@ public class StackedContents {
} }
public static ItemStack fromStackingIndex(int itemId) { public static ItemStack fromStackingIndex(int itemId) {
@@ -85,10 +85,10 @@ index 68d272e98f9e54c9b150c75c27a9ae545be842f6..63fc6074082b579c3f88316008cbeb2a
} }
diff --git a/src/main/java/net/minecraft/world/item/ItemStack.java b/src/main/java/net/minecraft/world/item/ItemStack.java diff --git a/src/main/java/net/minecraft/world/item/ItemStack.java b/src/main/java/net/minecraft/world/item/ItemStack.java
index f76f912501fc647f759dbd54b2b220f5b95c1407..7e68596e28db88213e9352f798c5a4ce37cc5656 100644 index 6c7f0db683101e12ae48dc3f28d5d00ac9569e35..68035cfe391b0e39a7a5f4b8b6e3275d75686070 100644
--- a/src/main/java/net/minecraft/world/item/ItemStack.java --- a/src/main/java/net/minecraft/world/item/ItemStack.java
+++ b/src/main/java/net/minecraft/world/item/ItemStack.java +++ b/src/main/java/net/minecraft/world/item/ItemStack.java
@@ -113,6 +113,7 @@ import org.bukkit.event.world.StructureGrowEvent; @@ -114,6 +114,7 @@ import org.bukkit.event.world.StructureGrowEvent;
public final class ItemStack { public final class ItemStack {
@@ -97,10 +97,10 @@ index f76f912501fc647f759dbd54b2b220f5b95c1407..7e68596e28db88213e9352f798c5a4ce
return instance.group(BuiltInRegistries.ITEM.byNameCodec().fieldOf("id").forGetter(ItemStack::getItem), Codec.INT.fieldOf("Count").forGetter(ItemStack::getCount), CompoundTag.CODEC.optionalFieldOf("tag").forGetter((itemstack) -> { return instance.group(BuiltInRegistries.ITEM.byNameCodec().fieldOf("id").forGetter(ItemStack::getItem), Codec.INT.fieldOf("Count").forGetter(ItemStack::getCount), CompoundTag.CODEC.optionalFieldOf("tag").forGetter((itemstack) -> {
return Optional.ofNullable(itemstack.getTag()); return Optional.ofNullable(itemstack.getTag());
diff --git a/src/main/java/net/minecraft/world/item/crafting/Ingredient.java b/src/main/java/net/minecraft/world/item/crafting/Ingredient.java diff --git a/src/main/java/net/minecraft/world/item/crafting/Ingredient.java b/src/main/java/net/minecraft/world/item/crafting/Ingredient.java
index 3ca086418ad037c48775db73d2b9c410acf1e326..f47eab4c31925f51de4a6bc8be730281cb3388fc 100644 index 3532db21cee82c18f95c540d24b2071585d71c4e..ae98a5b49b5eb7b9b2846d1e41b5665c725198a2 100644
--- a/src/main/java/net/minecraft/world/item/crafting/Ingredient.java --- a/src/main/java/net/minecraft/world/item/crafting/Ingredient.java
+++ b/src/main/java/net/minecraft/world/item/crafting/Ingredient.java +++ b/src/main/java/net/minecraft/world/item/crafting/Ingredient.java
@@ -51,7 +51,11 @@ public final class Ingredient implements Predicate<ItemStack> { @@ -57,7 +57,11 @@ public final class Ingredient implements Predicate<ItemStack> {
if (this.itemStacks == null) { if (this.itemStacks == null) {
this.itemStacks = (ItemStack[]) Arrays.stream(this.values).flatMap((recipeitemstack_provider) -> { this.itemStacks = (ItemStack[]) Arrays.stream(this.values).flatMap((recipeitemstack_provider) -> {
return recipeitemstack_provider.getItems().stream(); return recipeitemstack_provider.getItems().stream();
@@ -113,7 +113,7 @@ index 3ca086418ad037c48775db73d2b9c410acf1e326..f47eab4c31925f51de4a6bc8be730281
return new ItemStack[i]; return new ItemStack[i];
}); });
} }
@@ -106,7 +110,13 @@ public final class Ingredient implements Predicate<ItemStack> { @@ -112,7 +116,13 @@ public final class Ingredient implements Predicate<ItemStack> {
for (int j = 0; j < i; ++j) { for (int j = 0; j < i; ++j) {
ItemStack itemstack = aitemstack1[j]; ItemStack itemstack = aitemstack1[j];

View File

@@ -6,10 +6,10 @@ Subject: [PATCH] Allow custom ChatDecorators
Requires NMS to utilize. I'll write an API for this once our upstreams calm down with the changes. Requires NMS to utilize. I'll write an API for this once our upstreams calm down with the changes.
diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java
index d474e2ce24d822254c1ac0c9d9468ac13f9cca86..1d6843b376d626e2db8565d15e02bf4c93be30e3 100644 index ad403421711052faf36cb6b063997cfa90712423..e7e2c8115b1f25039965f390c927b004e8b3f630 100644
--- a/src/main/java/net/minecraft/server/MinecraftServer.java --- a/src/main/java/net/minecraft/server/MinecraftServer.java
+++ b/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java
@@ -2671,6 +2671,15 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa @@ -2664,6 +2664,15 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
new com.google.common.util.concurrent.ThreadFactoryBuilder().setDaemon(true).setNameFormat("Async Chat Thread - #%d").setUncaughtExceptionHandler(new net.minecraft.DefaultUncaughtExceptionHandlerWithName(net.minecraft.server.MinecraftServer.LOGGER)).build()); // Paper new com.google.common.util.concurrent.ThreadFactoryBuilder().setDaemon(true).setNameFormat("Async Chat Thread - #%d").setUncaughtExceptionHandler(new net.minecraft.DefaultUncaughtExceptionHandlerWithName(net.minecraft.server.MinecraftServer.LOGGER)).build()); // Paper
public ChatDecorator getChatDecorator() { public ChatDecorator getChatDecorator() {

View File

@@ -21,7 +21,7 @@ index abd0217cf0bff183c8e262edc173a53403797c1a..2519ad2884b6c09b312432b933c31476
private static final ThreadLocal<List<ChunkProgressionTask>> CURRENT_TICKET_UPDATE_SCHEDULING = new ThreadLocal<>(); private static final ThreadLocal<List<ChunkProgressionTask>> CURRENT_TICKET_UPDATE_SCHEDULING = new ThreadLocal<>();
diff --git a/src/main/java/io/papermc/paper/chunk/system/scheduling/NewChunkHolder.java b/src/main/java/io/papermc/paper/chunk/system/scheduling/NewChunkHolder.java diff --git a/src/main/java/io/papermc/paper/chunk/system/scheduling/NewChunkHolder.java b/src/main/java/io/papermc/paper/chunk/system/scheduling/NewChunkHolder.java
index 51304c5cf4b0ac7646693ef97ef4a3847d3342b5..535ab99585cd4463d051334681bc80b5d20df7c0 100644 index b66a7d4aab887309579154815a0d4abf9de506b0..e6f56bc5b129699bab60db9c97c7f73b6ede2351 100644
--- a/src/main/java/io/papermc/paper/chunk/system/scheduling/NewChunkHolder.java --- a/src/main/java/io/papermc/paper/chunk/system/scheduling/NewChunkHolder.java
+++ b/src/main/java/io/papermc/paper/chunk/system/scheduling/NewChunkHolder.java +++ b/src/main/java/io/papermc/paper/chunk/system/scheduling/NewChunkHolder.java
@@ -1779,7 +1779,7 @@ public final class NewChunkHolder { @@ -1779,7 +1779,7 @@ public final class NewChunkHolder {
@@ -43,32 +43,23 @@ index 51304c5cf4b0ac7646693ef97ef4a3847d3342b5..535ab99585cd4463d051334681bc80b5
return executedUnloadTask | canSaveChunk | canSaveEntities | canSavePOI ? new SaveStat(executedUnloadTask || canSaveChunk, canSaveEntities, canSavePOI): null; return executedUnloadTask | canSaveChunk | canSaveEntities | canSavePOI ? new SaveStat(executedUnloadTask || canSaveChunk, canSaveEntities, canSavePOI): null;
} }
diff --git a/src/main/java/net/minecraft/network/protocol/PacketUtils.java b/src/main/java/net/minecraft/network/protocol/PacketUtils.java diff --git a/src/main/java/net/minecraft/network/protocol/PacketUtils.java b/src/main/java/net/minecraft/network/protocol/PacketUtils.java
index d2f0a0755317f5fa9a1ccf7db346aa77fd287d80..03852e7d21d9470a4469676367463fefb38acdc6 100644 index 9a49f5271ec1d9de17632bfffe8309cb1ba0d8b1..0be239c5c78432a6377cd7828cd49f61f8f0ac8f 100644
--- a/src/main/java/net/minecraft/network/protocol/PacketUtils.java --- a/src/main/java/net/minecraft/network/protocol/PacketUtils.java
+++ b/src/main/java/net/minecraft/network/protocol/PacketUtils.java +++ b/src/main/java/net/minecraft/network/protocol/PacketUtils.java
@@ -47,7 +47,7 @@ public class PacketUtils { @@ -49,7 +49,7 @@ public class PacketUtils {
if (MinecraftServer.getServer().hasStopped() || (listener instanceof ServerGamePacketListenerImpl && ((ServerGamePacketListenerImpl) listener).processedDisconnect)) return; // CraftBukkit, MC-142590 if (MinecraftServer.getServer().hasStopped() || (listener instanceof ServerCommonPacketListenerImpl && ((ServerCommonPacketListenerImpl) listener).processedDisconnect)) return; // CraftBukkit, MC-142590
if (listener.isAcceptingMessages()) { if (listener.shouldHandleMessage(packet)) {
co.aikar.timings.Timing timing = co.aikar.timings.MinecraftTimings.getPacketTiming(packet); // Paper - timings co.aikar.timings.Timing timing = co.aikar.timings.MinecraftTimings.getPacketTiming(packet); // Paper - timings
- try (co.aikar.timings.Timing ignored = timing.startTiming()) { // Paper - timings - try (co.aikar.timings.Timing ignored = timing.startTiming()) { // Paper - timings
+ try { // Paper - timings // Purpur + try { // Paper - timings // Purpur
packet.handle(listener); packet.handle(listener);
} catch (Exception exception) { } catch (Exception exception) {
if (listener.shouldPropagateHandlingExceptions()) { if (exception instanceof ReportedException) {
diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java
index 1d6843b376d626e2db8565d15e02bf4c93be30e3..629d870e6b501969d72e48500ea3c06c3bf3fe4d 100644 index e7e2c8115b1f25039965f390c927b004e8b3f630..d4aad1e62e2473c48c35b2e4238c4f5709b2352a 100644
--- a/src/main/java/net/minecraft/server/MinecraftServer.java --- a/src/main/java/net/minecraft/server/MinecraftServer.java
+++ b/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java
@@ -313,7 +313,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa @@ -1385,15 +1385,15 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
public volatile Thread shutdownThread; // Paper
public volatile boolean abnormalExit = false; // Paper
public boolean isIteratingOverLevels = false; // Paper
-
+
public gg.pufferfish.pufferfish.util.AsyncExecutor mobSpawnExecutor = new gg.pufferfish.pufferfish.util.AsyncExecutor("MobSpawning"); // Pufferfish - optimize mob spawning
public static <S extends MinecraftServer> S spin(Function<Thread, S> serverFactory) {
@@ -1404,15 +1404,15 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
public void onServerExit() {} public void onServerExit() {}
public void tickServer(BooleanSupplier shouldKeepTicking) { public void tickServer(BooleanSupplier shouldKeepTicking) {
@@ -87,7 +78,7 @@ index 1d6843b376d626e2db8565d15e02bf4c93be30e3..629d870e6b501969d72e48500ea3c06c
// Paper end // Paper end
new com.destroystokyo.paper.event.server.ServerTickStartEvent(this.tickCount+1).callEvent(); // Paper new com.destroystokyo.paper.event.server.ServerTickStartEvent(this.tickCount+1).callEvent(); // Paper
@@ -1447,9 +1447,9 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa @@ -1428,9 +1428,9 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
// Paper end // Paper end
io.papermc.paper.util.CachedLists.reset(); // Paper io.papermc.paper.util.CachedLists.reset(); // Paper
// Paper start - move executeAll() into full server tick timing // Paper start - move executeAll() into full server tick timing
@@ -99,19 +90,19 @@ index 1d6843b376d626e2db8565d15e02bf4c93be30e3..629d870e6b501969d72e48500ea3c06c
// Paper end // Paper end
// Paper start // Paper start
long endTime = System.nanoTime(); long endTime = System.nanoTime();
@@ -1470,7 +1470,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa @@ -1451,7 +1451,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
this.frameTimer.logFrameDuration(k - i); this.logTickTime(k - i);
this.profiler.pop(); this.profiler.pop();
org.spigotmc.WatchdogThread.tick(); // Spigot org.spigotmc.WatchdogThread.tick(); // Spigot
- co.aikar.timings.TimingsManager.FULL_SERVER_TICK.stopTiming(); // Paper - co.aikar.timings.TimingsManager.FULL_SERVER_TICK.stopTiming(); // Paper
+ //co.aikar.timings.TimingsManager.FULL_SERVER_TICK.stopTiming(); // Paper // Purpur + //co.aikar.timings.TimingsManager.FULL_SERVER_TICK.stopTiming(); // Paper // Purpur
} }
private ServerStatus buildServerStatus() { protected void logTickTime(long nanos) {}
@@ -1502,9 +1502,9 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa @@ -1488,9 +1488,9 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
} this.getPlayerList().getPlayers().forEach((entityplayer) -> {
entityplayer.connection.suspendFlushing();
public void tickChildren(BooleanSupplier shouldKeepTicking) { });
- MinecraftTimings.bukkitSchedulerTimer.startTiming(); // Spigot // Paper - MinecraftTimings.bukkitSchedulerTimer.startTiming(); // Spigot // Paper
+ //MinecraftTimings.bukkitSchedulerTimer.startTiming(); // Spigot // Paper // Purpur + //MinecraftTimings.bukkitSchedulerTimer.startTiming(); // Spigot // Paper // Purpur
this.server.getScheduler().mainThreadHeartbeat(this.tickCount); // CraftBukkit this.server.getScheduler().mainThreadHeartbeat(this.tickCount); // CraftBukkit
@@ -120,7 +111,7 @@ index 1d6843b376d626e2db8565d15e02bf4c93be30e3..629d870e6b501969d72e48500ea3c06c
// Paper start - Folia scheduler API // Paper start - Folia scheduler API
((io.papermc.paper.threadedregions.scheduler.FoliaGlobalRegionScheduler) Bukkit.getGlobalRegionScheduler()).tick(); ((io.papermc.paper.threadedregions.scheduler.FoliaGlobalRegionScheduler) Bukkit.getGlobalRegionScheduler()).tick();
getAllLevels().forEach(level -> { getAllLevels().forEach(level -> {
@@ -1521,21 +1521,21 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa @@ -1507,21 +1507,21 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
// Paper end - Folia scheduler API // Paper end - Folia scheduler API
io.papermc.paper.adventure.providers.ClickCallbackProviderImpl.CALLBACK_MANAGER.handleQueue(this.tickCount); // Paper io.papermc.paper.adventure.providers.ClickCallbackProviderImpl.CALLBACK_MANAGER.handleQueue(this.tickCount); // Paper
this.profiler.push("commandFunctions"); this.profiler.push("commandFunctions");
@@ -147,7 +138,7 @@ index 1d6843b376d626e2db8565d15e02bf4c93be30e3..629d870e6b501969d72e48500ea3c06c
// Send time updates to everyone, it will get the right time from the world the player is in. // Send time updates to everyone, it will get the right time from the world the player is in.
// Paper start - optimize time updates // Paper start - optimize time updates
for (final ServerLevel level : this.getAllLevels()) { for (final ServerLevel level : this.getAllLevels()) {
@@ -1555,7 +1555,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa @@ -1541,7 +1541,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
} }
} }
// Paper end // Paper end
@@ -156,7 +147,7 @@ index 1d6843b376d626e2db8565d15e02bf4c93be30e3..629d870e6b501969d72e48500ea3c06c
this.isIteratingOverLevels = true; // Paper this.isIteratingOverLevels = true; // Paper
Iterator iterator = this.getAllLevels().iterator(); // Paper - move down Iterator iterator = this.getAllLevels().iterator(); // Paper - move down
@@ -1580,14 +1580,14 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa @@ -1566,14 +1566,14 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
this.profiler.push("tick"); this.profiler.push("tick");
try { try {
@@ -173,7 +164,7 @@ index 1d6843b376d626e2db8565d15e02bf4c93be30e3..629d870e6b501969d72e48500ea3c06c
} catch (Throwable throwable) { } catch (Throwable throwable) {
// Spigot Start // Spigot Start
CrashReport crashreport; CrashReport crashreport;
@@ -1610,24 +1610,24 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa @@ -1596,24 +1596,24 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
this.isIteratingOverLevels = false; // Paper this.isIteratingOverLevels = false; // Paper
this.profiler.popPush("connection"); this.profiler.popPush("connection");
@@ -202,9 +193,9 @@ index 1d6843b376d626e2db8565d15e02bf4c93be30e3..629d870e6b501969d72e48500ea3c06c
- MinecraftTimings.tickablesTimer.stopTiming(); // Spigot // Paper - MinecraftTimings.tickablesTimer.stopTiming(); // Spigot // Paper
+ //MinecraftTimings.tickablesTimer.stopTiming(); // Spigot // Paper // Purpur + //MinecraftTimings.tickablesTimer.stopTiming(); // Spigot // Paper // Purpur
this.profiler.pop(); this.profiler.popPush("send chunks");
} iterator = this.playerList.getPlayers().iterator();
@@ -2814,7 +2814,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa @@ -2810,7 +2810,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
return; return;
} }
@@ -213,7 +204,7 @@ index 1d6843b376d626e2db8565d15e02bf4c93be30e3..629d870e6b501969d72e48500ea3c06c
try { try {
for (;;) { for (;;) {
boolean moreTasks = this.tickMidTickTasks(); boolean moreTasks = this.tickMidTickTasks();
@@ -2841,7 +2841,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa @@ -2837,7 +2837,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
} }
} }
} finally { } finally {
@@ -223,23 +214,23 @@ index 1d6843b376d626e2db8565d15e02bf4c93be30e3..629d870e6b501969d72e48500ea3c06c
} }
// Paper end - execute chunk tasks mid tick // Paper end - execute chunk tasks mid tick
diff --git a/src/main/java/net/minecraft/server/ServerFunctionManager.java b/src/main/java/net/minecraft/server/ServerFunctionManager.java diff --git a/src/main/java/net/minecraft/server/ServerFunctionManager.java b/src/main/java/net/minecraft/server/ServerFunctionManager.java
index 4a610b712acfe0b1b4dcf4988bc22c6a71616050..aa3f4ca3be843616d34897e41909255f512f8963 100644 index d10abd28c522612934aada8124e5bb67a9b4e9da..a6a1b57b4327f5710e9ec5ebca35a47c11751d11 100644
--- a/src/main/java/net/minecraft/server/ServerFunctionManager.java --- a/src/main/java/net/minecraft/server/ServerFunctionManager.java
+++ b/src/main/java/net/minecraft/server/ServerFunctionManager.java +++ b/src/main/java/net/minecraft/server/ServerFunctionManager.java
@@ -89,7 +89,7 @@ public class ServerFunctionManager { @@ -97,7 +97,7 @@ public class ServerFunctionManager {
} else { } else {
int i; int i;
- try (co.aikar.timings.Timing timing = function.getTiming().startTiming()) { // Paper - try (co.aikar.timings.Timing timing = function.getTiming().startTiming()) { // Paper
+ try /*(co.aikar.timings.Timing timing = function.getTiming().startTiming())*/ { // Paper // Purpur + try /*(co.aikar.timings.Timing timing = function.getTiming().startTiming())*/ { // Paper // Purpur
this.context = new ServerFunctionManager.ExecutionContext(tracer); this.context = new ServerFunctionManager.ExecutionContext(tracer);
i = this.context.runTopCommand(function, source); i = this.context.runTopCommand(customfunction1, source);
} finally { } finally {
diff --git a/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java b/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java diff --git a/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java b/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java
index 38e2c279d6a846a4d76c15e495bdf464bfcd5b96..1d67581af0a8cc417ddf5d0a9e68e83c5b845ae3 100644 index 7b1b34566c38d26ababfc5dafe254749ebc075ea..6656a3f4dd78270690479639c738fdd0ec7e588d 100644
--- a/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java --- a/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java
+++ b/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java +++ b/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java
@@ -522,7 +522,7 @@ public class DedicatedServer extends MinecraftServer implements ServerInterface @@ -519,7 +519,7 @@ public class DedicatedServer extends MinecraftServer implements ServerInterface
} }
public void handleConsoleInputs() { public void handleConsoleInputs() {
@@ -248,7 +239,7 @@ index 38e2c279d6a846a4d76c15e495bdf464bfcd5b96..1d67581af0a8cc417ddf5d0a9e68e83c
// Paper start - use proper queue // Paper start - use proper queue
ConsoleInput servercommand; ConsoleInput servercommand;
while ((servercommand = this.serverCommandQueue.poll()) != null) { while ((servercommand = this.serverCommandQueue.poll()) != null) {
@@ -539,7 +539,7 @@ public class DedicatedServer extends MinecraftServer implements ServerInterface @@ -536,7 +536,7 @@ public class DedicatedServer extends MinecraftServer implements ServerInterface
// CraftBukkit end // CraftBukkit end
} }
@@ -258,10 +249,10 @@ index 38e2c279d6a846a4d76c15e495bdf464bfcd5b96..1d67581af0a8cc417ddf5d0a9e68e83c
@Override @Override
diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java diff --git a/src/main/java/net/minecraft/server/level/ChunkMap.java b/src/main/java/net/minecraft/server/level/ChunkMap.java
index d60ae9f8d3afe3e996a66331ee510cfa5841388c..2d8dbcab5760d4b1879d17642c8e3b2658e4d7ec 100644 index dcf12bea1759d851d663896938ea101303ab63a5..3f0799cf3d9c5b9bfe3f29b1bf6cbdc9ca0fd38e 100644
--- a/src/main/java/net/minecraft/server/level/ChunkMap.java --- a/src/main/java/net/minecraft/server/level/ChunkMap.java
+++ b/src/main/java/net/minecraft/server/level/ChunkMap.java +++ b/src/main/java/net/minecraft/server/level/ChunkMap.java
@@ -642,15 +642,15 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider @@ -470,15 +470,15 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
protected void tick(BooleanSupplier shouldKeepTicking) { protected void tick(BooleanSupplier shouldKeepTicking) {
ProfilerFiller gameprofilerfiller = this.level.getProfiler(); ProfilerFiller gameprofilerfiller = this.level.getProfiler();
@@ -281,36 +272,7 @@ index d60ae9f8d3afe3e996a66331ee510cfa5841388c..2d8dbcab5760d4b1879d17642c8e3b26
} }
gameprofilerfiller.pop(); gameprofilerfiller.pop();
@@ -1272,24 +1272,24 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider @@ -1092,7 +1092,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
// Paper start - optimised tracker
private final void processTrackQueue() {
- this.level.timings.tracker1.startTiming();
+ //this.level.timings.tracker1.startTiming(); // Purpur
try {
for (TrackedEntity tracker : this.entityMap.values()) {
// update tracker entry
tracker.updatePlayers(tracker.entity.getPlayersInTrackRange());
}
} finally {
- this.level.timings.tracker1.stopTiming();
+ //this.level.timings.tracker1.stopTiming(); // Purpur
}
- this.level.timings.tracker2.startTiming();
+ //this.level.timings.tracker2.startTiming(); // Purpur
try {
for (TrackedEntity tracker : this.entityMap.values()) {
tracker.serverEntity.sendChanges();
}
} finally {
- this.level.timings.tracker2.stopTiming();
+ //this.level.timings.tracker2.stopTiming(); Purpur
}
}
// Paper end - optimised tracker
@@ -1304,7 +1304,7 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
List<ServerPlayer> list = Lists.newArrayList(); List<ServerPlayer> list = Lists.newArrayList();
List<ServerPlayer> list1 = this.level.players(); List<ServerPlayer> list1 = this.level.players();
ObjectIterator objectiterator = this.entityMap.values().iterator(); ObjectIterator objectiterator = this.entityMap.values().iterator();
@@ -319,7 +281,7 @@ index d60ae9f8d3afe3e996a66331ee510cfa5841388c..2d8dbcab5760d4b1879d17642c8e3b26
ChunkMap.TrackedEntity playerchunkmap_entitytracker; ChunkMap.TrackedEntity playerchunkmap_entitytracker;
@@ -1329,17 +1329,17 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider @@ -1117,17 +1117,17 @@ public class ChunkMap extends ChunkStorage implements ChunkHolder.PlayerProvider
playerchunkmap_entitytracker.serverEntity.sendChanges(); playerchunkmap_entitytracker.serverEntity.sendChanges();
} }
} }
@@ -341,10 +303,10 @@ index d60ae9f8d3afe3e996a66331ee510cfa5841388c..2d8dbcab5760d4b1879d17642c8e3b26
} }
diff --git a/src/main/java/net/minecraft/server/level/ServerChunkCache.java b/src/main/java/net/minecraft/server/level/ServerChunkCache.java diff --git a/src/main/java/net/minecraft/server/level/ServerChunkCache.java b/src/main/java/net/minecraft/server/level/ServerChunkCache.java
index fe1a9c646b09d11e7fa2186afbeb70b680ad2b57..14613af193b178133fd688f26a766b36fa969590 100644 index 2ab16e10323982e193e647246bd116e31f17bad2..ead4d70df7f33ff984d288d14d774a4156abb4fd 100644
--- a/src/main/java/net/minecraft/server/level/ServerChunkCache.java --- a/src/main/java/net/minecraft/server/level/ServerChunkCache.java
+++ b/src/main/java/net/minecraft/server/level/ServerChunkCache.java +++ b/src/main/java/net/minecraft/server/level/ServerChunkCache.java
@@ -299,10 +299,10 @@ public class ServerChunkCache extends ChunkSource { @@ -295,10 +295,10 @@ public class ServerChunkCache extends ChunkSource {
io.papermc.paper.chunk.system.scheduling.ChunkTaskScheduler.pushChunkWait(this.level, x1, z1); // Paper - rewrite chunk system io.papermc.paper.chunk.system.scheduling.ChunkTaskScheduler.pushChunkWait(this.level, x1, z1); // Paper - rewrite chunk system
// Paper end // Paper end
com.destroystokyo.paper.io.SyncLoadFinder.logSyncLoad(this.level, x1, z1); // Paper - sync load info com.destroystokyo.paper.io.SyncLoadFinder.logSyncLoad(this.level, x1, z1); // Paper - sync load info
@@ -357,7 +319,7 @@ index fe1a9c646b09d11e7fa2186afbeb70b680ad2b57..14613af193b178133fd688f26a766b36
} // Paper } // Paper
ichunkaccess = (ChunkAccess) ((Either) completablefuture.join()).map((ichunkaccess1) -> { ichunkaccess = (ChunkAccess) ((Either) completablefuture.join()).map((ichunkaccess1) -> {
return ichunkaccess1; return ichunkaccess1;
@@ -451,17 +451,17 @@ public class ServerChunkCache extends ChunkSource { @@ -447,17 +447,17 @@ public class ServerChunkCache extends ChunkSource {
public void save(boolean flush) { public void save(boolean flush) {
this.runDistanceManagerUpdates(); this.runDistanceManagerUpdates();
@@ -379,7 +341,7 @@ index fe1a9c646b09d11e7fa2186afbeb70b680ad2b57..14613af193b178133fd688f26a766b36
} }
// Paper end // Paper end
@@ -491,22 +491,22 @@ public class ServerChunkCache extends ChunkSource { @@ -487,22 +487,22 @@ public class ServerChunkCache extends ChunkSource {
@Override @Override
public void tick(BooleanSupplier shouldKeepTicking, boolean tickChunks) { public void tick(BooleanSupplier shouldKeepTicking, boolean tickChunks) {
this.level.getProfiler().push("purge"); this.level.getProfiler().push("purge");
@@ -408,7 +370,7 @@ index fe1a9c646b09d11e7fa2186afbeb70b680ad2b57..14613af193b178133fd688f26a766b36
this.level.getProfiler().pop(); this.level.getProfiler().pop();
this.clearCache(); this.clearCache();
} }
@@ -561,7 +561,7 @@ public class ServerChunkCache extends ChunkSource { @@ -525,7 +525,7 @@ public class ServerChunkCache extends ChunkSource {
boolean flag1 = level.ticksPerSpawnCategory.getLong(org.bukkit.entity.SpawnCategory.ANIMAL) != 0L && worlddata.getGameTime() % level.ticksPerSpawnCategory.getLong(org.bukkit.entity.SpawnCategory.ANIMAL) == 0L; // CraftBukkit boolean flag1 = level.ticksPerSpawnCategory.getLong(org.bukkit.entity.SpawnCategory.ANIMAL) != 0L && worlddata.getGameTime() % level.ticksPerSpawnCategory.getLong(org.bukkit.entity.SpawnCategory.ANIMAL) == 0L; // CraftBukkit
gameprofilerfiller.push("naturalSpawnCount"); gameprofilerfiller.push("naturalSpawnCount");
@@ -417,25 +379,26 @@ index fe1a9c646b09d11e7fa2186afbeb70b680ad2b57..14613af193b178133fd688f26a766b36
int l = this.distanceManager.getNaturalSpawnChunkCount(); int l = this.distanceManager.getNaturalSpawnChunkCount();
// Paper start - per player mob spawning // Paper start - per player mob spawning
NaturalSpawner.SpawnState spawnercreature_d; // moved down NaturalSpawner.SpawnState spawnercreature_d; // moved down
@@ -592,12 +592,12 @@ public class ServerChunkCache extends ChunkSource { @@ -549,13 +549,13 @@ public class ServerChunkCache extends ChunkSource {
// Pufferfish end spawnercreature_d = NaturalSpawner.createState(l, this.level.getAllEntities(), this::getFullChunk, this.chunkMap.playerMobDistanceMap == null ? new LocalMobCapCalculator(this.chunkMap) : null, false);
} }
// Paper end // Paper end
- this.level.timings.countNaturalMobs.stopTiming(); // Paper - timings - this.level.timings.countNaturalMobs.stopTiming(); // Paper - timings
+ //this.level.timings.countNaturalMobs.stopTiming(); // Paper - timings // Purpur + //this.level.timings.countNaturalMobs.stopTiming(); // Paper - timings // Purpur
//this.lastSpawnState = spawnercreature_d; // Pufferfish - this is managed asynchronously this.lastSpawnState = spawnercreature_d;
gameprofilerfiller.popPush("filteringLoadedChunks"); gameprofilerfiller.popPush("filteringLoadedChunks");
// Paper - moved down List<ServerChunkCache.ChunkAndHolder> list = Lists.newArrayListWithCapacity(l);
Iterator iterator = this.chunkMap.getChunks().iterator();
- this.level.timings.chunkTicks.startTiming(); // Paper - this.level.timings.chunkTicks.startTiming(); // Paper
+ //this.level.timings.chunkTicks.startTiming(); // Paper // Purpur + //this.level.timings.chunkTicks.startTiming(); // Paper // Purpur
// Paper - moved down while (iterator.hasNext()) {
ChunkHolder playerchunk = (ChunkHolder) iterator.next();
@@ -652,17 +652,17 @@ public class ServerChunkCache extends ChunkSource { @@ -599,19 +599,19 @@ public class ServerChunkCache extends ChunkSource {
}
} }
} }
// Paper end - optimise chunk tick iteration
- this.level.timings.chunkTicks.stopTiming(); // Paper - this.level.timings.chunkTicks.stopTiming(); // Paper
+ //this.level.timings.chunkTicks.stopTiming(); // Paper // Purpur + //this.level.timings.chunkTicks.stopTiming(); // Paper // Purpur
gameprofilerfiller.popPush("customSpawners"); gameprofilerfiller.popPush("customSpawners");
@@ -446,28 +409,22 @@ index fe1a9c646b09d11e7fa2186afbeb70b680ad2b57..14613af193b178133fd688f26a766b36
- } // Paper - timings - } // Paper - timings
+ //} // Paper - timings // Purpur + //} // Paper - timings // Purpur
} }
gameprofilerfiller.pop();
// Paper start - use set of chunks requiring updates, rather than iterating every single one loaded
gameprofilerfiller.popPush("broadcast"); gameprofilerfiller.popPush("broadcast");
- this.level.timings.broadcastChunkUpdates.startTiming(); // Paper - timing list.forEach((chunkproviderserver_a1) -> {
+ //this.level.timings.broadcastChunkUpdates.startTiming(); // Paper - timing // Purpur - this.level.timings.broadcastChunkUpdates.startTiming(); // Paper - timing
if (!this.chunkMap.needsChangeBroadcasting.isEmpty()) { + //this.level.timings.broadcastChunkUpdates.startTiming(); // Paper - timing // Purpur
ReferenceOpenHashSet<ChunkHolder> copy = this.chunkMap.needsChangeBroadcasting.clone(); chunkproviderserver_a1.holder.broadcastChanges(chunkproviderserver_a1.chunk);
this.chunkMap.needsChangeBroadcasting.clear(); - this.level.timings.broadcastChunkUpdates.stopTiming(); // Paper - timing
@@ -674,7 +674,7 @@ public class ServerChunkCache extends ChunkSource { + //this.level.timings.broadcastChunkUpdates.stopTiming(); // Paper - timing // Purpur
} });
} gameprofilerfiller.pop();
}
- this.level.timings.broadcastChunkUpdates.stopTiming(); // Paper - timing
+ //this.level.timings.broadcastChunkUpdates.stopTiming(); // Paper - timing // Purpur
gameprofilerfiller.pop(); gameprofilerfiller.pop();
// Paper end - use set of chunks requiring updates, rather than iterating every single one loaded
// Paper start - controlled flush for entity tracker packets
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
index 122defeec159165c5fef295ec1dd2da4a6ada622..5b7507db055d7be59b369f66e659e128c9c7e00b 100644 index 7ded6820b9b0b493a72e158d7a92d5062d2948ef..4cc1f2fa4453e2ba160bfd42717bd7c8c68541fe 100644
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java --- a/src/main/java/net/minecraft/server/level/ServerLevel.java
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java +++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
@@ -828,7 +828,7 @@ public class ServerLevel extends Level implements WorldGenLevel { @@ -736,7 +736,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
this.updateSkyBrightness(); this.updateSkyBrightness();
this.tickTime(); this.tickTime();
gameprofilerfiller.popPush("tickPending"); gameprofilerfiller.popPush("tickPending");
@@ -476,7 +433,7 @@ index 122defeec159165c5fef295ec1dd2da4a6ada622..5b7507db055d7be59b369f66e659e128
if (!this.isDebug()) { if (!this.isDebug()) {
j = this.getGameTime(); j = this.getGameTime();
gameprofilerfiller.push("blockTicks"); gameprofilerfiller.push("blockTicks");
@@ -837,20 +837,20 @@ public class ServerLevel extends Level implements WorldGenLevel { @@ -745,20 +745,20 @@ public class ServerLevel extends Level implements WorldGenLevel {
this.fluidTicks.tick(j, 65536, this::tickFluid); this.fluidTicks.tick(j, 65536, this::tickFluid);
gameprofilerfiller.pop(); gameprofilerfiller.pop();
} }
@@ -504,7 +461,7 @@ index 122defeec159165c5fef295ec1dd2da4a6ada622..5b7507db055d7be59b369f66e659e128
this.handlingTick = false; this.handlingTick = false;
gameprofilerfiller.pop(); gameprofilerfiller.pop();
boolean flag = true || !this.players.isEmpty() || !this.getForcedChunks().isEmpty(); // CraftBukkit - this prevents entity cleanup, other issues on servers with no players boolean flag = true || !this.players.isEmpty() || !this.getForcedChunks().isEmpty(); // CraftBukkit - this prevents entity cleanup, other issues on servers with no players
@@ -861,7 +861,7 @@ public class ServerLevel extends Level implements WorldGenLevel { @@ -769,7 +769,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
if (flag || this.emptyTime++ < 300) { if (flag || this.emptyTime++ < 300) {
gameprofilerfiller.push("entities"); gameprofilerfiller.push("entities");
@@ -513,16 +470,16 @@ index 122defeec159165c5fef295ec1dd2da4a6ada622..5b7507db055d7be59b369f66e659e128
if (this.dragonFight != null) { if (this.dragonFight != null) {
gameprofilerfiller.push("dragonFight"); gameprofilerfiller.push("dragonFight");
this.dragonFight.tick(); this.dragonFight.tick();
@@ -869,7 +869,7 @@ public class ServerLevel extends Level implements WorldGenLevel { @@ -777,7 +777,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
} }
org.spigotmc.ActivationRange.activateEntities(this); // Spigot org.spigotmc.ActivationRange.activateEntities(this); // Spigot
- timings.entityTick.startTiming(); // Spigot - timings.entityTick.startTiming(); // Spigot
+ //timings.entityTick.startTiming(); // Spigot // Purpur + //timings.entityTick.startTiming(); // Spigot // Purpur
this.entityTickList.forEach((entity) -> { this.entityTickList.forEach((entity) -> {
entity.activatedPriorityReset = false; // Pufferfish - DAB
if (!entity.isRemoved()) { if (!entity.isRemoved()) {
@@ -910,8 +910,8 @@ public class ServerLevel extends Level implements WorldGenLevel { if (false && this.shouldDiscardEntity(entity)) { // CraftBukkit - We prevent spawning in general, so this butchering is not needed
@@ -804,8 +804,8 @@ public class ServerLevel extends Level implements WorldGenLevel {
} }
} }
}); });
@@ -533,25 +490,25 @@ index 122defeec159165c5fef295ec1dd2da4a6ada622..5b7507db055d7be59b369f66e659e128
gameprofilerfiller.pop(); gameprofilerfiller.pop();
this.tickBlockEntities(); this.tickBlockEntities();
} }
@@ -1093,7 +1093,7 @@ public class ServerLevel extends Level implements WorldGenLevel { @@ -946,7 +946,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
// Paper start - optimise random block ticking // Paper start - optimise random block ticking
gameprofilerfiller.popPush("randomTick"); gameprofilerfiller.popPush("tickBlocks");
- timings.chunkTicksBlocks.startTiming(); // Paper - timings.chunkTicksBlocks.startTiming(); // Paper
+ //timings.chunkTicksBlocks.startTiming(); // Paper // Purpur + //timings.chunkTicksBlocks.startTiming(); // Paper // Purpur
if (randomTickSpeed > 0) { if (randomTickSpeed > 0) {
LevelChunkSection[] sections = chunk.getSections(); LevelChunkSection[] sections = chunk.getSections();
int minSection = io.papermc.paper.util.WorldUtil.getMinSection(this); final int minSection = io.papermc.paper.util.WorldUtil.getMinSection(this);
@@ -1127,7 +1127,7 @@ public class ServerLevel extends Level implements WorldGenLevel { @@ -979,7 +979,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
}
} }
// Paper end - optimise random block ticking // Paper end - optimise random block ticking
- timings.chunkTicksBlocks.stopTiming(); // Paper - timings.chunkTicksBlocks.stopTiming(); // Paper
+ //timings.chunkTicksBlocks.stopTiming(); // Paper // Purpur + //timings.chunkTicksBlocks.stopTiming(); // Paper // Purpur
gameprofilerfiller.pop(); gameprofilerfiller.pop();
} }
@@ -1420,8 +1420,8 @@ public class ServerLevel extends Level implements WorldGenLevel { @@ -1317,8 +1317,8 @@ public class ServerLevel extends Level implements WorldGenLevel {
// Spigot end // Spigot end
// Paper start- timings // Paper start- timings
final boolean isActive = org.spigotmc.ActivationRange.checkIfActive(entity); final boolean isActive = org.spigotmc.ActivationRange.checkIfActive(entity);
@@ -562,7 +519,7 @@ index 122defeec159165c5fef295ec1dd2da4a6ada622..5b7507db055d7be59b369f66e659e128
// Paper end - timings // Paper end - timings
entity.setOldPosAndRot(); entity.setOldPosAndRot();
ProfilerFiller gameprofilerfiller = this.getProfiler(); ProfilerFiller gameprofilerfiller = this.getProfiler();
@@ -1437,7 +1437,7 @@ public class ServerLevel extends Level implements WorldGenLevel { @@ -1334,7 +1334,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
entity.postTick(); // CraftBukkit entity.postTick(); // CraftBukkit
} else { entity.inactiveTick(); } // Paper - EAR 2 } else { entity.inactiveTick(); } // Paper - EAR 2
this.getProfiler().pop(); this.getProfiler().pop();
@@ -571,7 +528,7 @@ index 122defeec159165c5fef295ec1dd2da4a6ada622..5b7507db055d7be59b369f66e659e128
Iterator iterator = entity.getPassengers().iterator(); Iterator iterator = entity.getPassengers().iterator();
while (iterator.hasNext()) { while (iterator.hasNext()) {
@@ -1460,8 +1460,8 @@ public class ServerLevel extends Level implements WorldGenLevel { @@ -1357,8 +1357,8 @@ public class ServerLevel extends Level implements WorldGenLevel {
if (passenger instanceof Player || this.entityTickList.contains(passenger)) { if (passenger instanceof Player || this.entityTickList.contains(passenger)) {
// Paper - EAR 2 // Paper - EAR 2
final boolean isActive = org.spigotmc.ActivationRange.checkIfActive(passenger); final boolean isActive = org.spigotmc.ActivationRange.checkIfActive(passenger);
@@ -582,7 +539,7 @@ index 122defeec159165c5fef295ec1dd2da4a6ada622..5b7507db055d7be59b369f66e659e128
// Paper end // Paper end
passenger.setOldPosAndRot(); passenger.setOldPosAndRot();
++passenger.tickCount; ++passenger.tickCount;
@@ -1491,7 +1491,7 @@ public class ServerLevel extends Level implements WorldGenLevel { @@ -1388,7 +1388,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
this.tickPassenger(passenger, entity2); this.tickPassenger(passenger, entity2);
} }
@@ -591,7 +548,7 @@ index 122defeec159165c5fef295ec1dd2da4a6ada622..5b7507db055d7be59b369f66e659e128
} }
} else { } else {
passenger.stopRiding(); passenger.stopRiding();
@@ -1511,14 +1511,14 @@ public class ServerLevel extends Level implements WorldGenLevel { @@ -1408,14 +1408,14 @@ public class ServerLevel extends Level implements WorldGenLevel {
org.bukkit.Bukkit.getPluginManager().callEvent(new org.bukkit.event.world.WorldSaveEvent(getWorld())); org.bukkit.Bukkit.getPluginManager().callEvent(new org.bukkit.event.world.WorldSaveEvent(getWorld()));
} }
@@ -609,7 +566,7 @@ index 122defeec159165c5fef295ec1dd2da4a6ada622..5b7507db055d7be59b369f66e659e128
// Copied from save() // Copied from save()
// CraftBukkit start - moved from MinecraftServer.saveChunks // CraftBukkit start - moved from MinecraftServer.saveChunks
@@ -1530,7 +1530,7 @@ public class ServerLevel extends Level implements WorldGenLevel { @@ -1427,7 +1427,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
this.convertable.saveDataTag(this.server.registryAccess(), this.serverLevelData, this.server.getPlayerList().getSingleplayerData()); this.convertable.saveDataTag(this.server.registryAccess(), this.serverLevelData, this.server.getPlayerList().getSingleplayerData());
} }
// CraftBukkit end // CraftBukkit end
@@ -618,7 +575,7 @@ index 122defeec159165c5fef295ec1dd2da4a6ada622..5b7507db055d7be59b369f66e659e128
} }
// Paper end // Paper end
@@ -1544,7 +1544,7 @@ public class ServerLevel extends Level implements WorldGenLevel { @@ -1441,7 +1441,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
if (!savingDisabled) { if (!savingDisabled) {
org.bukkit.Bukkit.getPluginManager().callEvent(new org.bukkit.event.world.WorldSaveEvent(getWorld())); // CraftBukkit org.bukkit.Bukkit.getPluginManager().callEvent(new org.bukkit.event.world.WorldSaveEvent(getWorld())); // CraftBukkit
@@ -627,7 +584,7 @@ index 122defeec159165c5fef295ec1dd2da4a6ada622..5b7507db055d7be59b369f66e659e128
if (progressListener != null) { if (progressListener != null) {
progressListener.progressStartNoAbort(Component.translatable("menu.savingLevel")); progressListener.progressStartNoAbort(Component.translatable("menu.savingLevel"));
} }
@@ -1554,11 +1554,11 @@ public class ServerLevel extends Level implements WorldGenLevel { @@ -1451,11 +1451,11 @@ public class ServerLevel extends Level implements WorldGenLevel {
progressListener.progressStage(Component.translatable("menu.savingChunks")); progressListener.progressStage(Component.translatable("menu.savingChunks"));
} }
@@ -643,10 +600,10 @@ index 122defeec159165c5fef295ec1dd2da4a6ada622..5b7507db055d7be59b369f66e659e128
} else if (close) { chunkproviderserver.close(false); } // Paper - rewrite chunk system } else if (close) { chunkproviderserver.close(false); } // Paper - rewrite chunk system
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
index c2d8d653c7aea674e2efbf60d172da5d2c69758f..dfc84223a083890cd78b77029e1f85eb23f66229 100644 index 87e064670d336f1c3a86cdc524e2686c7ee5af72..9fa25455dd264ea0b58d5e1825fd88475021dea9 100644
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -2620,7 +2620,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic @@ -2446,7 +2446,7 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl
public void handleCommand(String s) { // Paper - private -> public public void handleCommand(String s) { // Paper - private -> public
org.spigotmc.AsyncCatcher.catchOp("Command Dispatched Async: " + s); // Paper - Add async catcher org.spigotmc.AsyncCatcher.catchOp("Command Dispatched Async: " + s); // Paper - Add async catcher
@@ -655,7 +612,7 @@ index c2d8d653c7aea674e2efbf60d172da5d2c69758f..dfc84223a083890cd78b77029e1f85eb
if ( org.spigotmc.SpigotConfig.logCommands ) // Spigot if ( org.spigotmc.SpigotConfig.logCommands ) // Spigot
this.LOGGER.info(this.player.getScoreboardName() + " issued server command: " + s); this.LOGGER.info(this.player.getScoreboardName() + " issued server command: " + s);
@@ -2630,7 +2630,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic @@ -2456,7 +2456,7 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl
this.cserver.getPluginManager().callEvent(event); this.cserver.getPluginManager().callEvent(event);
if (event.isCancelled()) { if (event.isCancelled()) {
@@ -664,7 +621,7 @@ index c2d8d653c7aea674e2efbf60d172da5d2c69758f..dfc84223a083890cd78b77029e1f85eb
return; return;
} }
@@ -2643,7 +2643,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic @@ -2469,7 +2469,7 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl
java.util.logging.Logger.getLogger(ServerGamePacketListenerImpl.class.getName()).log(java.util.logging.Level.SEVERE, null, ex); java.util.logging.Logger.getLogger(ServerGamePacketListenerImpl.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
return; return;
} finally { } finally {
@@ -674,10 +631,10 @@ index c2d8d653c7aea674e2efbf60d172da5d2c69758f..dfc84223a083890cd78b77029e1f85eb
} }
// CraftBukkit end // CraftBukkit end
diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java
index 43fdebcd107a7ca08b93de1d649b4d5e6acf5e81..824f31b68b38f2f8642fb9d59a123cfdaffbb7b2 100644 index ad4f678de4aeeb7bb3d624f44dacc2c1d5200b1e..9942ab57f883f79719dff20f666912face27d5c4 100644
--- a/src/main/java/net/minecraft/server/players/PlayerList.java --- a/src/main/java/net/minecraft/server/players/PlayerList.java
+++ b/src/main/java/net/minecraft/server/players/PlayerList.java +++ b/src/main/java/net/minecraft/server/players/PlayerList.java
@@ -1257,7 +1257,7 @@ public abstract class PlayerList { @@ -1249,7 +1249,7 @@ public abstract class PlayerList {
public void saveAll(int interval) { public void saveAll(int interval) {
io.papermc.paper.util.MCUtil.ensureMain("Save Players" , () -> { // Paper - Ensure main io.papermc.paper.util.MCUtil.ensureMain("Save Players" , () -> { // Paper - Ensure main
@@ -686,7 +643,7 @@ index 43fdebcd107a7ca08b93de1d649b4d5e6acf5e81..824f31b68b38f2f8642fb9d59a123cfd
int numSaved = 0; int numSaved = 0;
long now = MinecraftServer.currentTick; long now = MinecraftServer.currentTick;
for (int i = 0; i < this.players.size(); ++i) { for (int i = 0; i < this.players.size(); ++i) {
@@ -1268,7 +1268,7 @@ public abstract class PlayerList { @@ -1260,7 +1260,7 @@ public abstract class PlayerList {
} }
// Paper end // Paper end
} }
@@ -745,10 +702,10 @@ index fcdb9bde8e1605e30dde3e580491522d4b62cdc0..7094701d213c73ba47ace806962244c1
} }
diff --git a/src/main/java/net/minecraft/world/level/Level.java b/src/main/java/net/minecraft/world/level/Level.java diff --git a/src/main/java/net/minecraft/world/level/Level.java b/src/main/java/net/minecraft/world/level/Level.java
index 2832776269971f3e3b689f8d16b2058d815cf5ba..233980edc80fa0f15756f6d16b76b1f84bd79920 100644 index 282ec5085a8076790d2a24e7979b36c06a9bcba0..f9db7dde74ce1277a792497d078ed272e8b23d10 100644
--- a/src/main/java/net/minecraft/world/level/Level.java --- a/src/main/java/net/minecraft/world/level/Level.java
+++ b/src/main/java/net/minecraft/world/level/Level.java +++ b/src/main/java/net/minecraft/world/level/Level.java
@@ -1015,15 +1015,15 @@ public abstract class Level implements LevelAccessor, AutoCloseable { @@ -1299,15 +1299,15 @@ public abstract class Level implements LevelAccessor, AutoCloseable {
ProfilerFiller gameprofilerfiller = this.getProfiler(); ProfilerFiller gameprofilerfiller = this.getProfiler();
gameprofilerfiller.push("blockEntities"); gameprofilerfiller.push("blockEntities");
@@ -767,7 +724,7 @@ index 2832776269971f3e3b689f8d16b2058d815cf5ba..233980edc80fa0f15756f6d16b76b1f8
// Spigot start // Spigot start
// Iterator iterator = this.blockEntityTickers.iterator(); // Iterator iterator = this.blockEntityTickers.iterator();
int tilesThisCycle = 0; int tilesThisCycle = 0;
@@ -1056,7 +1056,7 @@ public abstract class Level implements LevelAccessor, AutoCloseable { @@ -1340,7 +1340,7 @@ public abstract class Level implements LevelAccessor, AutoCloseable {
} }
this.blockEntityTickers.removeAll(toRemove); this.blockEntityTickers.removeAll(toRemove);
@@ -777,7 +734,7 @@ index 2832776269971f3e3b689f8d16b2058d815cf5ba..233980edc80fa0f15756f6d16b76b1f8
co.aikar.timings.TimingHistory.tileEntityTicks += this.blockEntityTickers.size(); // Paper co.aikar.timings.TimingHistory.tileEntityTicks += this.blockEntityTickers.size(); // Paper
gameprofilerfiller.pop(); gameprofilerfiller.pop();
diff --git a/src/main/java/net/minecraft/world/level/NaturalSpawner.java b/src/main/java/net/minecraft/world/level/NaturalSpawner.java diff --git a/src/main/java/net/minecraft/world/level/NaturalSpawner.java b/src/main/java/net/minecraft/world/level/NaturalSpawner.java
index 49de1fca183b2c6a0a5399025abfc0e47f314315..482dfb2bbf8b85ba98bf164c5cf3edcdf927eb98 100644 index 64656c384863a6430e933e506d965ee628f08669..93af6e1a041a514e9b7198e0e510fa88b043439d 100644
--- a/src/main/java/net/minecraft/world/level/NaturalSpawner.java --- a/src/main/java/net/minecraft/world/level/NaturalSpawner.java
+++ b/src/main/java/net/minecraft/world/level/NaturalSpawner.java +++ b/src/main/java/net/minecraft/world/level/NaturalSpawner.java
@@ -133,7 +133,7 @@ public final class NaturalSpawner { @@ -133,7 +133,7 @@ public final class NaturalSpawner {
@@ -799,10 +756,10 @@ index 49de1fca183b2c6a0a5399025abfc0e47f314315..482dfb2bbf8b85ba98bf164c5cf3edcd
} }
diff --git a/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java b/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java diff --git a/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java b/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
index dbb0593a6feb60216379bde6720ca16f3ca827ae..4dab159024cf91cd297dcb31833f9d57e2132326 100644 index 7fccb874ca2de82cc652a440bd250d0d1295397d..b27e2e187f9edebdf53cfad3d410154c0751ac86 100644
--- a/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java --- a/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
+++ b/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java +++ b/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
@@ -895,7 +895,7 @@ public class LevelChunk extends ChunkAccess { @@ -789,7 +789,7 @@ public class LevelChunk extends ChunkAccess {
this.chunkHolder.getEntityChunk().callEntitiesLoadEvent(); // Paper - rewrite chunk system this.chunkHolder.getEntityChunk().callEntitiesLoadEvent(); // Paper - rewrite chunk system
if (this.needsDecoration) { if (this.needsDecoration) {
@@ -811,7 +768,7 @@ index dbb0593a6feb60216379bde6720ca16f3ca827ae..4dab159024cf91cd297dcb31833f9d57
this.needsDecoration = false; this.needsDecoration = false;
java.util.Random random = new java.util.Random(); java.util.Random random = new java.util.Random();
random.setSeed(this.level.getSeed()); random.setSeed(this.level.getSeed());
@@ -915,7 +915,7 @@ public class LevelChunk extends ChunkAccess { @@ -809,7 +809,7 @@ public class LevelChunk extends ChunkAccess {
} }
} }
server.getPluginManager().callEvent(new org.bukkit.event.world.ChunkPopulateEvent(bukkitChunk)); server.getPluginManager().callEvent(new org.bukkit.event.world.ChunkPopulateEvent(bukkitChunk));
@@ -820,7 +777,7 @@ index dbb0593a6feb60216379bde6720ca16f3ca827ae..4dab159024cf91cd297dcb31833f9d57
} }
} }
} }
@@ -1273,7 +1273,7 @@ public class LevelChunk extends ChunkAccess { @@ -1167,7 +1167,7 @@ public class LevelChunk extends ChunkAccess {
ProfilerFiller gameprofilerfiller = LevelChunk.this.level.getProfiler(); ProfilerFiller gameprofilerfiller = LevelChunk.this.level.getProfiler();
gameprofilerfiller.push(this::getType); gameprofilerfiller.push(this::getType);
@@ -829,7 +786,7 @@ index dbb0593a6feb60216379bde6720ca16f3ca827ae..4dab159024cf91cd297dcb31833f9d57
BlockState iblockdata = LevelChunk.this.getBlockState(blockposition); BlockState iblockdata = LevelChunk.this.getBlockState(blockposition);
if (this.blockEntity.getType().isValid(iblockdata)) { if (this.blockEntity.getType().isValid(iblockdata)) {
@@ -1295,7 +1295,7 @@ public class LevelChunk extends ChunkAccess { @@ -1189,7 +1189,7 @@ public class LevelChunk extends ChunkAccess {
// Paper end // Paper end
// Spigot start // Spigot start
} finally { } finally {
@@ -894,7 +851,7 @@ index 3f45bab0e9f7b3697e6d9d1092a1e6e579f7066f..4f1cf281c4bf68c37982d390da8779de
long getCreatedAt() { long getCreatedAt() {
diff --git a/src/main/java/org/bukkit/craftbukkit/scoreboard/CraftScoreboardManager.java b/src/main/java/org/bukkit/craftbukkit/scoreboard/CraftScoreboardManager.java diff --git a/src/main/java/org/bukkit/craftbukkit/scoreboard/CraftScoreboardManager.java b/src/main/java/org/bukkit/craftbukkit/scoreboard/CraftScoreboardManager.java
index 500f2eb0df5a07637cd278c263e95592b0037eb6..895431584c476067790f1f131699d49eac3f4b8f 100644 index 628951be16da8f19f0e1a974a0b4efa86e873b99..af1717fe7be06e4828febc0d5737f086b9c08e08 100644
--- a/src/main/java/org/bukkit/craftbukkit/scoreboard/CraftScoreboardManager.java --- a/src/main/java/org/bukkit/craftbukkit/scoreboard/CraftScoreboardManager.java
+++ b/src/main/java/org/bukkit/craftbukkit/scoreboard/CraftScoreboardManager.java +++ b/src/main/java/org/bukkit/craftbukkit/scoreboard/CraftScoreboardManager.java
@@ -115,7 +115,7 @@ public final class CraftScoreboardManager implements ScoreboardManager { @@ -115,7 +115,7 @@ public final class CraftScoreboardManager implements ScoreboardManager {
@@ -916,10 +873,10 @@ index 500f2eb0df5a07637cd278c263e95592b0037eb6..895431584c476067790f1f131699d49e
// Paper end - add timings for scoreboard search // Paper end - add timings for scoreboard search
} }
diff --git a/src/main/java/org/spigotmc/ActivationRange.java b/src/main/java/org/spigotmc/ActivationRange.java diff --git a/src/main/java/org/spigotmc/ActivationRange.java b/src/main/java/org/spigotmc/ActivationRange.java
index 79d027e517ce08443d86b877a55df24cc20d102b..43d9e7287cf0e498ccbff9b865bb813e7fb567c0 100644 index bc98504b9eacd41994c234e6385f37c5d681383b..f2e7e3501ca9d1664039468b5e7dece47986fd29 100644
--- a/src/main/java/org/spigotmc/ActivationRange.java --- a/src/main/java/org/spigotmc/ActivationRange.java
+++ b/src/main/java/org/spigotmc/ActivationRange.java +++ b/src/main/java/org/spigotmc/ActivationRange.java
@@ -170,7 +170,7 @@ public class ActivationRange @@ -166,7 +166,7 @@ public class ActivationRange
*/ */
public static void activateEntities(Level world) public static void activateEntities(Level world)
{ {
@@ -928,7 +885,7 @@ index 79d027e517ce08443d86b877a55df24cc20d102b..43d9e7287cf0e498ccbff9b865bb813e
final int miscActivationRange = world.spigotConfig.miscActivationRange; final int miscActivationRange = world.spigotConfig.miscActivationRange;
final int raiderActivationRange = world.spigotConfig.raiderActivationRange; final int raiderActivationRange = world.spigotConfig.raiderActivationRange;
final int animalActivationRange = world.spigotConfig.animalActivationRange; final int animalActivationRange = world.spigotConfig.animalActivationRange;
@@ -245,7 +245,7 @@ public class ActivationRange @@ -227,7 +227,7 @@ public class ActivationRange
} }
// Paper end // Paper end
} }

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Add more logger output for invalid movement kicks
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
index e22f403c54922f05d6d5704ec648dce02097bbb0..9b488a98fdf06515ff267040dd6d654004665207 100644 index 9fa25455dd264ea0b58d5e1825fd88475021dea9..0d79a045ae1f28f07f1b052ba014bbf372217dba 100644
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -867,6 +867,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic @@ -736,6 +736,7 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl
if (packet.getId() == this.awaitingTeleport) { if (packet.getId() == this.awaitingTeleport) {
if (this.awaitingPositionFromClient == null) { if (this.awaitingPositionFromClient == null) {
this.disconnect(Component.translatable("multiplayer.disconnect.invalid_player_movement"), org.bukkit.event.player.PlayerKickEvent.Cause.INVALID_PLAYER_MOVEMENT); // Paper - kick event cause this.disconnect(Component.translatable("multiplayer.disconnect.invalid_player_movement"), org.bukkit.event.player.PlayerKickEvent.Cause.INVALID_PLAYER_MOVEMENT); // Paper - kick event cause
@@ -16,7 +16,7 @@ index e22f403c54922f05d6d5704ec648dce02097bbb0..9b488a98fdf06515ff267040dd6d6540
return; return;
} }
@@ -1455,8 +1456,16 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic @@ -1323,8 +1324,16 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl
@Override @Override
public void handleMovePlayer(ServerboundMovePlayerPacket packet) { public void handleMovePlayer(ServerboundMovePlayerPacket packet) {
PacketUtils.ensureRunningOnSameThread(packet, this, this.player.serverLevel()); PacketUtils.ensureRunningOnSameThread(packet, this, this.player.serverLevel());

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Debug Marker API
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
index ab31661318beb96bc18b270cc614adcf0ea86d08..9bb5c8a2480dbb86c022d9a83b892d28cf232e8d 100644 index cb912efba182aff9e8f080aa473f78115eae8a47..8632e9cab6563b9ea0a01c2e5248ad658129d5ce 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
@@ -1546,6 +1546,42 @@ public final class CraftServer implements Server { @@ -1543,6 +1543,42 @@ public final class CraftServer implements Server {
public void removeFuel(org.bukkit.Material material) { public void removeFuel(org.bukkit.Material material) {
net.minecraft.world.level.block.entity.AbstractFurnaceBlockEntity.removeFuel(net.minecraft.world.item.ItemStack.fromBukkitCopy(new ItemStack(material))); net.minecraft.world.level.block.entity.AbstractFurnaceBlockEntity.removeFuel(net.minecraft.world.item.ItemStack.fromBukkitCopy(new ItemStack(material)));
} }
@@ -52,10 +52,10 @@ index ab31661318beb96bc18b270cc614adcf0ea86d08..9bb5c8a2480dbb86c022d9a83b892d28
@Override @Override
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
index a2e852adf47261b1b2eb9734cc90f4676ed58126..1392e483c363e25d1f16465d876cb7d7c70afa68 100644 index e55438768a030cdcef433782e55f0fafc4f51db1..2b87e25c1b6627d4ccfb11f4c20c1796c897867f 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java --- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
@@ -2294,6 +2294,42 @@ public class CraftWorld extends CraftRegionAccessor implements World { @@ -2288,6 +2288,42 @@ public class CraftWorld extends CraftRegionAccessor implements World {
public float getLocalDifficultyAt(Location location) { public float getLocalDifficultyAt(Location location) {
return getHandle().getCurrentDifficultyAt(io.papermc.paper.util.MCUtil.toBlockPosition(location)).getEffectiveDifficulty(); return getHandle().getCurrentDifficultyAt(io.papermc.paper.util.MCUtil.toBlockPosition(location)).getEffectiveDifficulty();
} }
@@ -99,12 +99,12 @@ index a2e852adf47261b1b2eb9734cc90f4676ed58126..1392e483c363e25d1f16465d876cb7d7
@Override @Override
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
index 9c093c406711047a450624e2d137677b1cd4d4b7..c5729a6b326846c5f01bbb413177e244f32a48f1 100644 index 19f6bad1b81c5a5c249631b43e1f6c159dc994e0..5c23c28955ef0fc3168cf98cd625681bd896ea5f 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
@@ -3334,5 +3334,48 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -3335,5 +3335,48 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
public void setSpawnInvulnerableTicks(int spawnInvulnerableTime) { public void resetIdleTimer() {
getHandle().spawnInvulnerableTime = spawnInvulnerableTime; getHandle().resetLastActionTime();
} }
+ +
+ @Override + @Override

View File

@@ -5,20 +5,21 @@ Subject: [PATCH] mob spawning option to ignore creative players
diff --git a/src/main/java/net/minecraft/world/level/NaturalSpawner.java b/src/main/java/net/minecraft/world/level/NaturalSpawner.java diff --git a/src/main/java/net/minecraft/world/level/NaturalSpawner.java b/src/main/java/net/minecraft/world/level/NaturalSpawner.java
index ad89aac8d6b1ac1095806930afd4fe196084525b..1f9994f4b0b736f64a8676d9431469527c6484df 100644 index ec95678e5fb3f36a35cd0e03c65184a8ee4c8609..a32ac7796c8cba94b02d854d47395cc1a513f770 100644
--- a/src/main/java/net/minecraft/world/level/NaturalSpawner.java --- a/src/main/java/net/minecraft/world/level/NaturalSpawner.java
+++ b/src/main/java/net/minecraft/world/level/NaturalSpawner.java +++ b/src/main/java/net/minecraft/world/level/NaturalSpawner.java
@@ -260,7 +260,7 @@ public final class NaturalSpawner { @@ -260,7 +260,8 @@ public final class NaturalSpawner {
blockposition_mutableblockposition.set(l, i, i1); blockposition_mutableblockposition.set(l, i, i1);
double d0 = (double) l + 0.5D; double d0 = (double) l + 0.5D;
double d1 = (double) i1 + 0.5D; double d1 = (double) i1 + 0.5D;
- Player entityhuman = (chunk instanceof LevelChunk) ? ((LevelChunk)chunk).findNearestPlayer(d0, i, d1, 576.0D, net.minecraft.world.entity.EntitySelector.NO_SPECTATORS) : world.getNearestPlayer(d0, (double) i, d1, -1.0D, false); // Paper - use chunk's player cache to optimize search in range - Player entityhuman = world.getNearestPlayer(d0, (double) i, d1, -1.0D, false);
+ Player entityhuman = (chunk instanceof LevelChunk) ? ((LevelChunk)chunk).findNearestPlayer(d0, i, d1, 576.0D, world.purpurConfig.mobSpawningIgnoreCreativePlayers ? net.minecraft.world.entity.EntitySelector.NO_CREATIVE_OR_SPECTATOR : net.minecraft.world.entity.EntitySelector.NO_SPECTATORS) : world.getNearestPlayer(d0, (double) i, d1, -1.0D, world.purpurConfig.mobSpawningIgnoreCreativePlayers); // Paper - use chunk's player cache to optimize search in range // Purpur + Player entityhuman = world.getNearestPlayer(d0, (double) i, d1, -1.0D, world.purpurConfig.mobSpawningIgnoreCreativePlayers); // Purpur - diff on change
+ //Player entityhuman = (chunk instanceof LevelChunk) ? ((LevelChunk)chunk).findNearestPlayer(d0, i, d1, 576.0D, world.purpurConfig.mobSpawningIgnoreCreativePlayers ? net.minecraft.world.entity.EntitySelector.NO_CREATIVE_OR_SPECTATOR : net.minecraft.world.entity.EntitySelector.NO_SPECTATORS) : world.getNearestPlayer(d0, (double) i, d1, -1.0D, world.purpurConfig.mobSpawningIgnoreCreativePlayers); // Paper - use chunk's player cache to optimize search in range // Purpur // Purpur - TODO: Paper
if (entityhuman != null) { if (entityhuman != null) {
double d2 = entityhuman.distanceToSqr(d0, (double) i, d1); double d2 = entityhuman.distanceToSqr(d0, (double) i, d1);
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 370b5ff992fb3ff7dd88ab479b3c251d36ced42f..8519259a086dfcceb793e5e1177e06248c97bc2e 100644 index 07b8826509d158e60ee6c3c847f7855b7469325f..71d2da21e1dcf5991f9161b3fcad66247a5a4991 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -377,6 +377,7 @@ public class PurpurWorldConfig { @@ -377,6 +377,7 @@ public class PurpurWorldConfig {

View File

@@ -5,7 +5,7 @@ Subject: [PATCH] Add skeleton bow accuracy option
diff --git a/src/main/java/net/minecraft/world/entity/monster/AbstractSkeleton.java b/src/main/java/net/minecraft/world/entity/monster/AbstractSkeleton.java diff --git a/src/main/java/net/minecraft/world/entity/monster/AbstractSkeleton.java b/src/main/java/net/minecraft/world/entity/monster/AbstractSkeleton.java
index 41376b705748e14c1c4174e07732ce09ad8e581f..dd84433a988712da9d799cbda2487a902315fb92 100644 index f3e1fa62d9f067c0fe8aacb88bf30b01ee0562c1..28eb98d383d6846a25c29f8cd8ff211c360a56dc 100644
--- a/src/main/java/net/minecraft/world/entity/monster/AbstractSkeleton.java --- a/src/main/java/net/minecraft/world/entity/monster/AbstractSkeleton.java
+++ b/src/main/java/net/minecraft/world/entity/monster/AbstractSkeleton.java +++ b/src/main/java/net/minecraft/world/entity/monster/AbstractSkeleton.java
@@ -182,7 +182,7 @@ public abstract class AbstractSkeleton extends Monster implements RangedAttackMo @@ -182,7 +182,7 @@ public abstract class AbstractSkeleton extends Monster implements RangedAttackMo
@@ -18,10 +18,10 @@ index 41376b705748e14c1c4174e07732ce09ad8e581f..dd84433a988712da9d799cbda2487a90
org.bukkit.event.entity.EntityShootBowEvent event = org.bukkit.craftbukkit.event.CraftEventFactory.callEntityShootBowEvent(this, this.getMainHandItem(), entityarrow.getPickupItem(), entityarrow, net.minecraft.world.InteractionHand.MAIN_HAND, 0.8F, true); // Paper org.bukkit.event.entity.EntityShootBowEvent event = org.bukkit.craftbukkit.event.CraftEventFactory.callEntityShootBowEvent(this, this.getMainHandItem(), entityarrow.getPickupItem(), entityarrow, net.minecraft.world.InteractionHand.MAIN_HAND, 0.8F, true); // Paper
if (event.isCancelled()) { if (event.isCancelled()) {
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 8519259a086dfcceb793e5e1177e06248c97bc2e..5f4b6d211e1a310ca2efcc94686e2757cff973ec 100644 index 71d2da21e1dcf5991f9161b3fcad66247a5a4991..86340e782bbc125ec672eea855de29f90ac127de 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -2453,6 +2453,8 @@ public class PurpurWorldConfig { @@ -2449,6 +2449,8 @@ public class PurpurWorldConfig {
public boolean skeletonAlwaysDropExp = false; public boolean skeletonAlwaysDropExp = false;
public double skeletonHeadVisibilityPercent = 0.5D; public double skeletonHeadVisibilityPercent = 0.5D;
public int skeletonFeedWitherRoses = 0; public int skeletonFeedWitherRoses = 0;
@@ -30,7 +30,7 @@ index 8519259a086dfcceb793e5e1177e06248c97bc2e..5f4b6d211e1a310ca2efcc94686e2757
private void skeletonSettings() { private void skeletonSettings() {
skeletonRidable = getBoolean("mobs.skeleton.ridable", skeletonRidable); skeletonRidable = getBoolean("mobs.skeleton.ridable", skeletonRidable);
skeletonRidableInWater = getBoolean("mobs.skeleton.ridable-in-water", skeletonRidableInWater); skeletonRidableInWater = getBoolean("mobs.skeleton.ridable-in-water", skeletonRidableInWater);
@@ -2467,6 +2469,18 @@ public class PurpurWorldConfig { @@ -2463,6 +2465,18 @@ public class PurpurWorldConfig {
skeletonAlwaysDropExp = getBoolean("mobs.skeleton.always-drop-exp", skeletonAlwaysDropExp); skeletonAlwaysDropExp = getBoolean("mobs.skeleton.always-drop-exp", skeletonAlwaysDropExp);
skeletonHeadVisibilityPercent = getDouble("mobs.skeleton.head-visibility-percent", skeletonHeadVisibilityPercent); skeletonHeadVisibilityPercent = getDouble("mobs.skeleton.head-visibility-percent", skeletonHeadVisibilityPercent);
skeletonFeedWitherRoses = getInt("mobs.skeleton.feed-wither-roses", skeletonFeedWitherRoses); skeletonFeedWitherRoses = getInt("mobs.skeleton.feed-wither-roses", skeletonFeedWitherRoses);

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Allay respect item NBT
diff --git a/src/main/java/net/minecraft/world/entity/animal/allay/Allay.java b/src/main/java/net/minecraft/world/entity/animal/allay/Allay.java diff --git a/src/main/java/net/minecraft/world/entity/animal/allay/Allay.java b/src/main/java/net/minecraft/world/entity/animal/allay/Allay.java
index d50bf1b980231a1045c1c9df622a9a50fc2ed893..7166f4a39fd615e10d7b1f53c57363832a41f365 100644 index f9af021350df28f286028099d857f034bc03913b..b3e92d3fb6fbadfc6df236754123bc12ad9bc7e7 100644
--- a/src/main/java/net/minecraft/world/entity/animal/allay/Allay.java --- a/src/main/java/net/minecraft/world/entity/animal/allay/Allay.java
+++ b/src/main/java/net/minecraft/world/entity/animal/allay/Allay.java +++ b/src/main/java/net/minecraft/world/entity/animal/allay/Allay.java
@@ -407,9 +407,31 @@ public class Allay extends PathfinderMob implements InventoryCarrier, VibrationS @@ -405,9 +405,31 @@ public class Allay extends PathfinderMob implements InventoryCarrier, VibrationS
@Override @Override
public boolean wantsToPickUp(ItemStack stack) { public boolean wantsToPickUp(ItemStack stack) {
@@ -44,10 +44,10 @@ index d50bf1b980231a1045c1c9df622a9a50fc2ed893..7166f4a39fd615e10d7b1f53c5736383
private boolean allayConsidersItemEqual(ItemStack stack, ItemStack stack2) { private boolean allayConsidersItemEqual(ItemStack stack, ItemStack stack2) {
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 5f4b6d211e1a310ca2efcc94686e2757cff973ec..a4c5c469fed51b46727783ddefa293e53b9c66ca 100644 index 86340e782bbc125ec672eea855de29f90ac127de..1a8a1a9bca5c2f92b87fb1a21bdff194718caa8e 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -1087,10 +1087,13 @@ public class PurpurWorldConfig { @@ -1083,10 +1083,13 @@ public class PurpurWorldConfig {
public boolean allayRidable = false; public boolean allayRidable = false;
public boolean allayRidableInWater = true; public boolean allayRidableInWater = true;
public boolean allayControllable = true; public boolean allayControllable = true;

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Add death screen API
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
index beae58414b27d2a33bb6507ae8ab2104fde2cc0e..668d825a2469706e4de11629a0b41877de700ca6 100644 index 5c23c28955ef0fc3168cf98cd625681bd896ea5f..c9c8e66fd044a7c75994eaf38ff14f94f9c5e3ae 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
@@ -3377,5 +3377,11 @@ public class CraftPlayer extends CraftHumanEntity implements Player { @@ -3378,5 +3378,11 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
if (this.getHandle().connection == null) return; if (this.getHandle().connection == null) return;
this.getHandle().connection.send(new net.minecraft.network.protocol.game.ClientboundCustomPayloadPacket(ClientboundCustomPayloadPacket.DEBUG_GAME_TEST_CLEAR, new FriendlyByteBuf(io.netty.buffer.Unpooled.buffer()))); this.getHandle().connection.send(new net.minecraft.network.protocol.game.ClientboundCustomPayloadPacket(ClientboundCustomPayloadPacket.DEBUG_GAME_TEST_CLEAR, new FriendlyByteBuf(io.netty.buffer.Unpooled.buffer())));
} }

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Implement ram and rambar commands
diff --git a/src/main/java/net/minecraft/commands/Commands.java b/src/main/java/net/minecraft/commands/Commands.java diff --git a/src/main/java/net/minecraft/commands/Commands.java b/src/main/java/net/minecraft/commands/Commands.java
index 52b06c34d9d3ffb8844556e7b0eaed5a7f03da0c..5c0085589b08f199c75ceeab8d0cf25e970a0533 100644 index 9caab6541a224dc8f729a7d720eccda7bd83ed53..2fd376789bb24b14101e289733631a9a4b68fa1c 100644
--- a/src/main/java/net/minecraft/commands/Commands.java --- a/src/main/java/net/minecraft/commands/Commands.java
+++ b/src/main/java/net/minecraft/commands/Commands.java +++ b/src/main/java/net/minecraft/commands/Commands.java
@@ -230,6 +230,8 @@ public class Commands { @@ -236,6 +236,8 @@ public class Commands {
org.purpurmc.purpur.command.UptimeCommand.register(this.dispatcher); // Purpur org.purpurmc.purpur.command.UptimeCommand.register(this.dispatcher); // Purpur
org.purpurmc.purpur.command.TPSBarCommand.register(this.dispatcher); // Purpur org.purpurmc.purpur.command.TPSBarCommand.register(this.dispatcher); // Purpur
org.purpurmc.purpur.command.CompassCommand.register(this.dispatcher); // Purpur org.purpurmc.purpur.command.CompassCommand.register(this.dispatcher); // Purpur
@@ -18,17 +18,17 @@ index 52b06c34d9d3ffb8844556e7b0eaed5a7f03da0c..5c0085589b08f199c75ceeab8d0cf25e
if (environment.includeIntegrated) { if (environment.includeIntegrated) {
diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java diff --git a/src/main/java/net/minecraft/server/level/ServerPlayer.java b/src/main/java/net/minecraft/server/level/ServerPlayer.java
index 2f013c3365d065325d645d43f7c5137f942b06df..0249eeb3937cf48cea13846a7e39b248947e21a4 100644 index 3c44249e782d0e98689a58c719030dea2f007644..1b8325dfa185cf35bcb02e5e2485a78ef6f8c014 100644
--- a/src/main/java/net/minecraft/server/level/ServerPlayer.java --- a/src/main/java/net/minecraft/server/level/ServerPlayer.java
+++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java +++ b/src/main/java/net/minecraft/server/level/ServerPlayer.java
@@ -280,6 +280,7 @@ public class ServerPlayer extends Player { @@ -277,6 +277,7 @@ public class ServerPlayer extends Player {
public org.bukkit.event.player.PlayerQuitEvent.QuitReason quitReason = null; // Paper - there are a lot of changes to do if we change all methods leading to the event
public boolean purpurClient = false; // Purpur public boolean purpurClient = false; // Purpur
public boolean acceptingResourcePack = false; // Purpur
+ private boolean ramBar = false; // Purpur
private boolean tpsBar = false; // Purpur private boolean tpsBar = false; // Purpur
private boolean compassBar = false; // Purpur private boolean compassBar = false; // Purpur
+ private boolean ramBar = false; // Purpur
// Paper start - replace player chunk loader
private final java.util.concurrent.atomic.AtomicReference<io.papermc.paper.chunk.system.RegionizedPlayerChunkLoader.ViewDistances> viewDistances = new java.util.concurrent.atomic.AtomicReference<>(new io.papermc.paper.chunk.system.RegionizedPlayerChunkLoader.ViewDistances(-1, -1, -1));
@@ -562,6 +563,7 @@ public class ServerPlayer extends Player { @@ -562,6 +563,7 @@ public class ServerPlayer extends Player {
} }
} }
@@ -45,10 +45,11 @@ index 2f013c3365d065325d645d43f7c5137f942b06df..0249eeb3937cf48cea13846a7e39b248
nbt.putBoolean("Purpur.TPSBar", this.tpsBar); // Purpur nbt.putBoolean("Purpur.TPSBar", this.tpsBar); // Purpur
nbt.putBoolean("Purpur.CompassBar", this.compassBar); // Purpur nbt.putBoolean("Purpur.CompassBar", this.compassBar); // Purpur
} }
@@ -2816,6 +2819,14 @@ public class ServerPlayer extends Player { @@ -2804,5 +2807,13 @@ public class ServerPlayer extends Player {
} public void compassBar(boolean compassBar) {
this.compassBar = compassBar;
} }
+
+ public boolean ramBar() { + public boolean ramBar() {
+ return this.ramBar; + return this.ramBar;
+ } + }
@@ -56,10 +57,8 @@ index 2f013c3365d065325d645d43f7c5137f942b06df..0249eeb3937cf48cea13846a7e39b248
+ public void ramBar(boolean ramBar) { + public void ramBar(boolean ramBar) {
+ this.ramBar = ramBar; + this.ramBar = ramBar;
+ } + }
+ // Purpur end
public boolean tpsBar() { }
return this.tpsBar;
}
diff --git a/src/main/java/org/purpurmc/purpur/PurpurConfig.java b/src/main/java/org/purpurmc/purpur/PurpurConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurConfig.java b/src/main/java/org/purpurmc/purpur/PurpurConfig.java
index ed9b2f0b55229848894d9d6b401d050cb031b893..568bb53e91dda4804cd328a81ba12ce735c52603 100644 index ed9b2f0b55229848894d9d6b401d050cb031b893..568bb53e91dda4804cd328a81ba12ce735c52603 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurConfig.java

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Add item packet serialize event
diff --git a/src/main/java/net/minecraft/network/FriendlyByteBuf.java b/src/main/java/net/minecraft/network/FriendlyByteBuf.java diff --git a/src/main/java/net/minecraft/network/FriendlyByteBuf.java b/src/main/java/net/minecraft/network/FriendlyByteBuf.java
index 9938bb90bef84cf784f9a1ceb02a1a45aa8b48a1..1f4b64a5f812376c499c98cb4be62469bd0b7dbe 100644 index 2e395962b555bef0ce1a98e1d768e7738f011535..40f51062624161892c780ddae05e22859e2cd021 100644
--- a/src/main/java/net/minecraft/network/FriendlyByteBuf.java --- a/src/main/java/net/minecraft/network/FriendlyByteBuf.java
+++ b/src/main/java/net/minecraft/network/FriendlyByteBuf.java +++ b/src/main/java/net/minecraft/network/FriendlyByteBuf.java
@@ -98,6 +98,8 @@ public class FriendlyByteBuf extends ByteBuf { @@ -94,6 +94,8 @@ public class FriendlyByteBuf extends ByteBuf {
private static final int MAX_PUBLIC_KEY_LENGTH = 512; private static final int MAX_PUBLIC_KEY_LENGTH = 512;
private static final Gson GSON = new Gson(); private static final Gson GSON = new Gson();
@@ -17,7 +17,7 @@ index 9938bb90bef84cf784f9a1ceb02a1a45aa8b48a1..1f4b64a5f812376c499c98cb4be62469
public FriendlyByteBuf(ByteBuf parent) { public FriendlyByteBuf(ByteBuf parent) {
this.source = parent; this.source = parent;
} }
@@ -679,6 +681,17 @@ public class FriendlyByteBuf extends ByteBuf { @@ -632,6 +634,17 @@ public class FriendlyByteBuf extends ByteBuf {
this.writeBoolean(false); this.writeBoolean(false);
} else { } else {
this.writeBoolean(true); this.writeBoolean(true);
@@ -36,10 +36,10 @@ index 9938bb90bef84cf784f9a1ceb02a1a45aa8b48a1..1f4b64a5f812376c499c98cb4be62469
this.writeId(BuiltInRegistries.ITEM, item); this.writeId(BuiltInRegistries.ITEM, item);
diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java
index 9903d461f775701b2e01899b344c58609edd426a..e6ddf69ade7ae51640569150f7db10d1afa63691 100644 index 94b9a2f72dbdf85a95a9b99c45a66e7044f69f2a..d20aea388a568657f233d9e8b34b208d0d2ab01e 100644
--- a/src/main/java/net/minecraft/server/MinecraftServer.java --- a/src/main/java/net/minecraft/server/MinecraftServer.java
+++ b/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java
@@ -1558,6 +1558,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa @@ -1544,6 +1544,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
//MinecraftTimings.timeUpdateTimer.stopTiming(); // Spigot // Paper // Purpur //MinecraftTimings.timeUpdateTimer.stopTiming(); // Spigot // Paper // Purpur
this.isIteratingOverLevels = true; // Paper this.isIteratingOverLevels = true; // Paper
@@ -48,10 +48,10 @@ index 9903d461f775701b2e01899b344c58609edd426a..e6ddf69ade7ae51640569150f7db10d1
while (iterator.hasNext()) { while (iterator.hasNext()) {
ServerLevel worldserver = (ServerLevel) iterator.next(); ServerLevel worldserver = (ServerLevel) iterator.next();
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
index b82292ac5f90bc83b1c641f9b666398f478a19d3..255b422078880b46dfa6f5140f6c92fef057d09e 100644 index 0d79a045ae1f28f07f1b052ba014bbf372217dba..ee9845804d2ad59bdde78e778c28690746877541 100644
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -3524,6 +3524,12 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic @@ -3361,6 +3361,12 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl
} }
} }
} }

View File

@@ -5,7 +5,7 @@ Subject: [PATCH] Add an option to fix MC-3304 (projectile looting)
diff --git a/src/main/java/net/minecraft/world/entity/projectile/AbstractArrow.java b/src/main/java/net/minecraft/world/entity/projectile/AbstractArrow.java diff --git a/src/main/java/net/minecraft/world/entity/projectile/AbstractArrow.java b/src/main/java/net/minecraft/world/entity/projectile/AbstractArrow.java
index e8773aa2e796ca4e3b9b7cf85c40906d16eb241d..6b070ad6aa1b62a66fb85d54042af9d64cdcea7f 100644 index 9710d1cd31d263b29c80923c56134b1f8f6702b0..4063aed1a3f0bfd7351c1ec2e9684e4991cb5285 100644
--- a/src/main/java/net/minecraft/world/entity/projectile/AbstractArrow.java --- a/src/main/java/net/minecraft/world/entity/projectile/AbstractArrow.java
+++ b/src/main/java/net/minecraft/world/entity/projectile/AbstractArrow.java +++ b/src/main/java/net/minecraft/world/entity/projectile/AbstractArrow.java
@@ -72,6 +72,7 @@ public abstract class AbstractArrow extends Projectile { @@ -72,6 +72,7 @@ public abstract class AbstractArrow extends Projectile {
@@ -86,10 +86,10 @@ index 6d1573161f0d8c7999f84925ba7bbf536ee9583a..c32cbe6065ecb6810f352b8a3598c21e
// Paper start // Paper start
com.destroystokyo.paper.event.player.PlayerLaunchProjectileEvent event = new com.destroystokyo.paper.event.player.PlayerLaunchProjectileEvent((org.bukkit.entity.Player) entityhuman.getBukkitEntity(), org.bukkit.craftbukkit.inventory.CraftItemStack.asCraftMirror(stack), (org.bukkit.entity.Projectile) entitythrowntrident.getBukkitEntity()); com.destroystokyo.paper.event.player.PlayerLaunchProjectileEvent event = new com.destroystokyo.paper.event.player.PlayerLaunchProjectileEvent((org.bukkit.entity.Player) entityhuman.getBukkitEntity(), org.bukkit.craftbukkit.inventory.CraftItemStack.asCraftMirror(stack), (org.bukkit.entity.Projectile) entitythrowntrident.getBukkitEntity());
diff --git a/src/main/java/net/minecraft/world/level/storage/loot/functions/LootingEnchantFunction.java b/src/main/java/net/minecraft/world/level/storage/loot/functions/LootingEnchantFunction.java diff --git a/src/main/java/net/minecraft/world/level/storage/loot/functions/LootingEnchantFunction.java b/src/main/java/net/minecraft/world/level/storage/loot/functions/LootingEnchantFunction.java
index 31918fa2eb38e42a5ea5366e559f25ea9d7d59ae..15d8e9261a89da30529ac347462c520920ca4e7d 100644 index 3fb1e558c3510243c94981211f9a0e5e0ef1895b..e5177e5ffcac360f935f2139db4554c6586b551e 100644
--- a/src/main/java/net/minecraft/world/level/storage/loot/functions/LootingEnchantFunction.java --- a/src/main/java/net/minecraft/world/level/storage/loot/functions/LootingEnchantFunction.java
+++ b/src/main/java/net/minecraft/world/level/storage/loot/functions/LootingEnchantFunction.java +++ b/src/main/java/net/minecraft/world/level/storage/loot/functions/LootingEnchantFunction.java
@@ -49,6 +49,13 @@ public class LootingEnchantFunction extends LootItemConditionalFunction { @@ -57,6 +57,13 @@ public class LootingEnchantFunction extends LootItemConditionalFunction {
if (entity instanceof LivingEntity) { if (entity instanceof LivingEntity) {
int i = EnchantmentHelper.getMobLooting((LivingEntity) entity); int i = EnchantmentHelper.getMobLooting((LivingEntity) entity);

View File

@@ -5,7 +5,7 @@ Subject: [PATCH] Configurable block blast resistance
diff --git a/src/main/java/net/minecraft/world/level/block/state/BlockBehaviour.java b/src/main/java/net/minecraft/world/level/block/state/BlockBehaviour.java diff --git a/src/main/java/net/minecraft/world/level/block/state/BlockBehaviour.java b/src/main/java/net/minecraft/world/level/block/state/BlockBehaviour.java
index 5ac102afde62c08f36886b466010ccfedabfa05e..942ce713afe27ec75d849877a88721ef6334fafa 100644 index 443bed339884f78ecda8abdbcdc9b57ea9768cc9..e46a097dc134672720bc753ec0da0a9102737d2c 100644
--- a/src/main/java/net/minecraft/world/level/block/state/BlockBehaviour.java --- a/src/main/java/net/minecraft/world/level/block/state/BlockBehaviour.java
+++ b/src/main/java/net/minecraft/world/level/block/state/BlockBehaviour.java +++ b/src/main/java/net/minecraft/world/level/block/state/BlockBehaviour.java
@@ -81,7 +81,7 @@ public abstract class BlockBehaviour implements FeatureElement { @@ -81,7 +81,7 @@ public abstract class BlockBehaviour implements FeatureElement {

View File

@@ -18,7 +18,7 @@ index e8405a57fb88e63b63baaf00645c417633bdc0f2..2b66ddafaaca17f64d1e7502dfa4d757
@Override @Override
diff --git a/src/main/java/net/minecraft/world/level/block/Block.java b/src/main/java/net/minecraft/world/level/block/Block.java diff --git a/src/main/java/net/minecraft/world/level/block/Block.java b/src/main/java/net/minecraft/world/level/block/Block.java
index 69c78ee2d012344505063c9b297c9c550bde80c4..dc718efe054aaf36961514287c9cc48e2d28bc4c 100644 index cee9e07a250ed61570cf9787236308f91724f02f..65504432a13df45e895cf6ca885627014444563a 100644
--- a/src/main/java/net/minecraft/world/level/block/Block.java --- a/src/main/java/net/minecraft/world/level/block/Block.java
+++ b/src/main/java/net/minecraft/world/level/block/Block.java +++ b/src/main/java/net/minecraft/world/level/block/Block.java
@@ -94,6 +94,10 @@ public class Block extends BlockBehaviour implements ItemLike { @@ -94,6 +94,10 @@ public class Block extends BlockBehaviour implements ItemLike {

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Language API
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
index 9bb5c8a2480dbb86c022d9a83b892d28cf232e8d..b21bc96232d0fd52e5dae7fa1c413714f8ddd7ee 100644 index 8632e9cab6563b9ea0a01c2e5248ad658129d5ce..aea87307b318ed34e60835ba1d9420e9a0fd4d8e 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
@@ -397,6 +397,20 @@ public final class CraftServer implements Server { @@ -399,6 +399,20 @@ public final class CraftServer implements Server {
this.dataPackManager = new CraftDataPackManager(this.getServer().getPackRepository()); this.dataPackManager = new CraftDataPackManager(this.getServer().getPackRepository());
Bukkit.setServer(this); Bukkit.setServer(this);

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Milk Keeps Beneficial Effects
diff --git a/src/main/java/net/minecraft/world/entity/LivingEntity.java b/src/main/java/net/minecraft/world/entity/LivingEntity.java diff --git a/src/main/java/net/minecraft/world/entity/LivingEntity.java b/src/main/java/net/minecraft/world/entity/LivingEntity.java
index 9012b5b918bca409166db9eb29c201a793886dbb..0b08cf7b26731ffd6f3909342f4e3a92fe0c813e 100644 index 7bace36fb2c447cc2c7d07777a910c5867bbfe99..4604e63cec3c25a1257892d4c1ea9db098815b93 100644
--- a/src/main/java/net/minecraft/world/entity/LivingEntity.java --- a/src/main/java/net/minecraft/world/entity/LivingEntity.java
+++ b/src/main/java/net/minecraft/world/entity/LivingEntity.java +++ b/src/main/java/net/minecraft/world/entity/LivingEntity.java
@@ -1124,6 +1124,7 @@ public abstract class LivingEntity extends Entity implements Attackable { @@ -1125,6 +1125,7 @@ public abstract class LivingEntity extends Entity implements Attackable {
for (flag = false; iterator.hasNext(); flag = true) { for (flag = false; iterator.hasNext(); flag = true) {
// CraftBukkit start // CraftBukkit start
MobEffectInstance effect = (MobEffectInstance) iterator.next(); MobEffectInstance effect = (MobEffectInstance) iterator.next();
@@ -17,10 +17,10 @@ index 9012b5b918bca409166db9eb29c201a793886dbb..0b08cf7b26731ffd6f3909342f4e3a92
if (event.isCancelled()) { if (event.isCancelled()) {
continue; continue;
diff --git a/src/main/java/net/minecraft/world/entity/npc/WanderingTrader.java b/src/main/java/net/minecraft/world/entity/npc/WanderingTrader.java diff --git a/src/main/java/net/minecraft/world/entity/npc/WanderingTrader.java b/src/main/java/net/minecraft/world/entity/npc/WanderingTrader.java
index 970b1f6eaeeddf9928ba61239248ecd2234eda9a..0e5fae26bf89749e446050c92dc7c23d788f5edb 100644 index 6986fcbe67e55c4942d13b2af39bd6293bf993a9..d8a4b1aaa180fc0c837bc0d8efab781a578898a5 100644
--- a/src/main/java/net/minecraft/world/entity/npc/WanderingTrader.java --- a/src/main/java/net/minecraft/world/entity/npc/WanderingTrader.java
+++ b/src/main/java/net/minecraft/world/entity/npc/WanderingTrader.java +++ b/src/main/java/net/minecraft/world/entity/npc/WanderingTrader.java
@@ -110,7 +110,7 @@ public class WanderingTrader extends net.minecraft.world.entity.npc.AbstractVill @@ -114,7 +114,7 @@ public class WanderingTrader extends net.minecraft.world.entity.npc.AbstractVill
return this.canDrinkPotion && this.level().isNight() && !entityvillagertrader.isInvisible(); // Paper - Add more WanderingTrader API return this.canDrinkPotion && this.level().isNight() && !entityvillagertrader.isInvisible(); // Paper - Add more WanderingTrader API
})); }));
this.goalSelector.addGoal(0, new UseItemGoal<>(this, new ItemStack(Items.MILK_BUCKET), SoundEvents.WANDERING_TRADER_REAPPEARED, (entityvillagertrader) -> { this.goalSelector.addGoal(0, new UseItemGoal<>(this, new ItemStack(Items.MILK_BUCKET), SoundEvents.WANDERING_TRADER_REAPPEARED, (entityvillagertrader) -> {
@@ -30,7 +30,7 @@ index 970b1f6eaeeddf9928ba61239248ecd2234eda9a..0e5fae26bf89749e446050c92dc7c23d
this.goalSelector.addGoal(1, new TradeWithPlayerGoal(this)); this.goalSelector.addGoal(1, new TradeWithPlayerGoal(this));
this.goalSelector.addGoal(1, new AvoidEntityGoal<>(this, Zombie.class, 8.0F, 0.5D, 0.5D)); this.goalSelector.addGoal(1, new AvoidEntityGoal<>(this, Zombie.class, 8.0F, 0.5D, 0.5D));
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index a4c5c469fed51b46727783ddefa293e53b9c66ca..ad8f733ded15d6db3adabccd35bd035f87b2777c 100644 index 1a8a1a9bca5c2f92b87fb1a21bdff194718caa8e..1bec2760e6ae3022dbcef1bb40d7749cf3b0609e 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -128,6 +128,7 @@ public class PurpurWorldConfig { @@ -128,6 +128,7 @@ public class PurpurWorldConfig {

View File

@@ -24,10 +24,10 @@ index e241ae250f4f04a17ef2c583d00b065a4ca56a4c..7b99c3446b50939241d3e220d93e0564
} }
} }
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index ad8f733ded15d6db3adabccd35bd035f87b2777c..0e7666ddae8e0dc76047fb2f0661a8e63bf2cef2 100644 index 1bec2760e6ae3022dbcef1bb40d7749cf3b0609e..c04befc0e4d97497087bc8961daefe814e199a84 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -1361,6 +1361,7 @@ public class PurpurWorldConfig { @@ -1357,6 +1357,7 @@ public class PurpurWorldConfig {
public boolean creeperHealthRadius = false; public boolean creeperHealthRadius = false;
public boolean creeperAlwaysDropExp = false; public boolean creeperAlwaysDropExp = false;
public double creeperHeadVisibilityPercent = 0.5D; public double creeperHeadVisibilityPercent = 0.5D;
@@ -35,7 +35,7 @@ index ad8f733ded15d6db3adabccd35bd035f87b2777c..0e7666ddae8e0dc76047fb2f0661a8e6
private void creeperSettings() { private void creeperSettings() {
creeperRidable = getBoolean("mobs.creeper.ridable", creeperRidable); creeperRidable = getBoolean("mobs.creeper.ridable", creeperRidable);
creeperRidableInWater = getBoolean("mobs.creeper.ridable-in-water", creeperRidableInWater); creeperRidableInWater = getBoolean("mobs.creeper.ridable-in-water", creeperRidableInWater);
@@ -1379,6 +1380,7 @@ public class PurpurWorldConfig { @@ -1375,6 +1376,7 @@ public class PurpurWorldConfig {
creeperHealthRadius = getBoolean("mobs.creeper.health-impacts-explosion", creeperHealthRadius); creeperHealthRadius = getBoolean("mobs.creeper.health-impacts-explosion", creeperHealthRadius);
creeperAlwaysDropExp = getBoolean("mobs.creeper.always-drop-exp", creeperAlwaysDropExp); creeperAlwaysDropExp = getBoolean("mobs.creeper.always-drop-exp", creeperAlwaysDropExp);
creeperHeadVisibilityPercent = getDouble("mobs.creeper.head-visibility-percent", creeperHeadVisibilityPercent); creeperHeadVisibilityPercent = getDouble("mobs.creeper.head-visibility-percent", creeperHeadVisibilityPercent);

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Fire Immunity API
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
index e634f9b7998979e00e4de4899214863e32f1a776..606b29a752176288234ce0082a9b58b79007e4e1 100644 index 6e0331818ef68fa355e3c27dc3e362b82d1c6e3a..5fa044b03f0a08d1e17b9002255e2e6438fa79c8 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java --- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -418,6 +418,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { @@ -417,6 +417,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource {
public boolean freezeLocked = false; // Paper - Freeze Tick Lock API public boolean freezeLocked = false; // Paper - Freeze Tick Lock API
public boolean collidingWithWorldBorder; // Paper public boolean collidingWithWorldBorder; // Paper
public boolean fixedPose = false; // Paper public boolean fixedPose = false; // Paper
@@ -16,7 +16,7 @@ index e634f9b7998979e00e4de4899214863e32f1a776..606b29a752176288234ce0082a9b58b7
public void setOrigin(@javax.annotation.Nonnull Location location) { public void setOrigin(@javax.annotation.Nonnull Location location) {
this.origin = location.toVector(); this.origin = location.toVector();
@@ -1822,7 +1823,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { @@ -1767,7 +1768,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource {
} }
public boolean fireImmune() { public boolean fireImmune() {
@@ -25,7 +25,7 @@ index e634f9b7998979e00e4de4899214863e32f1a776..606b29a752176288234ce0082a9b58b7
} }
public boolean causeFallDamage(float fallDistance, float damageMultiplier, DamageSource damageSource) { public boolean causeFallDamage(float fallDistance, float damageMultiplier, DamageSource damageSource) {
@@ -2492,6 +2493,11 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { @@ -2441,6 +2442,11 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource {
nbt.putBoolean("Paper.FreezeLock", true); nbt.putBoolean("Paper.FreezeLock", true);
} }
// Paper end // Paper end
@@ -37,7 +37,7 @@ index e634f9b7998979e00e4de4899214863e32f1a776..606b29a752176288234ce0082a9b58b7
return nbt; return nbt;
} catch (Throwable throwable) { } catch (Throwable throwable) {
CrashReport crashreport = CrashReport.forThrowable(throwable, "Saving entity NBT"); CrashReport crashreport = CrashReport.forThrowable(throwable, "Saving entity NBT");
@@ -2660,6 +2666,11 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { @@ -2609,6 +2615,11 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource {
freezeLocked = nbt.getBoolean("Paper.FreezeLock"); freezeLocked = nbt.getBoolean("Paper.FreezeLock");
} }
// Paper end // Paper end
@@ -50,11 +50,11 @@ index e634f9b7998979e00e4de4899214863e32f1a776..606b29a752176288234ce0082a9b58b7
} catch (Throwable throwable) { } catch (Throwable throwable) {
CrashReport crashreport = CrashReport.forThrowable(throwable, "Loading entity NBT"); CrashReport crashreport = CrashReport.forThrowable(throwable, "Loading entity NBT");
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java
index feeca8d318fa0b7b22e728baa3bf3269d42bf0a6..8973c8a3bad120e55269bf1b7b810284ad0fe14c 100644 index 431e3cedde33b33202be1d44bf066323997f21f8..236d753266943d8c64e1329336d28c50109d0886 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java
@@ -224,6 +224,16 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity { @@ -223,6 +223,16 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity {
this.entityType = (type != null) ? type : EntityType.UNKNOWN; this.entityType = CraftEntityType.minecraftToBukkit(entity.getType());
} }
+ @Override + @Override

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Add option to teleport to spawn on nether ceiling damage
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
index 606b29a752176288234ce0082a9b58b79007e4e1..cf0d8da4c4b5f4aa4e4ef15897ca252a2b52ec8d 100644 index 5fa044b03f0a08d1e17b9002255e2e6438fa79c8..84643f0dd71530a5f18557f299d7725a8f53666e 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java --- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java +++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -939,6 +939,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource { @@ -872,6 +872,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource {
&& this.level.paperConfig().environment.netherCeilingVoidDamageHeight.test(v -> this.getY() >= v) && this.level.paperConfig().environment.netherCeilingVoidDamageHeight.test(v -> this.getY() >= v)
&& (!(this instanceof Player player) || !player.getAbilities().invulnerable))) { && (!(this instanceof Player player) || !player.getAbilities().invulnerable))) {
// Paper end // Paper end
@@ -17,10 +17,10 @@ index 606b29a752176288234ce0082a9b58b79007e4e1..cf0d8da4c4b5f4aa4e4ef15897ca252a
} }
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 0e7666ddae8e0dc76047fb2f0661a8e63bf2cef2..059865f4aed093b0a6ee27243305462a31458ef0 100644 index c04befc0e4d97497087bc8961daefe814e199a84..443871290764e6863509acd0847f8c4c8f8566b6 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -419,6 +419,7 @@ public class PurpurWorldConfig { @@ -417,6 +417,7 @@ public class PurpurWorldConfig {
public String playerDeathExpDropEquation = "expLevel * 7"; public String playerDeathExpDropEquation = "expLevel * 7";
public int playerDeathExpDropMax = 100; public int playerDeathExpDropMax = 100;
public boolean teleportIfOutsideBorder = false; public boolean teleportIfOutsideBorder = false;
@@ -28,7 +28,7 @@ index 0e7666ddae8e0dc76047fb2f0661a8e63bf2cef2..059865f4aed093b0a6ee27243305462a
public boolean totemOfUndyingWorksInInventory = false; public boolean totemOfUndyingWorksInInventory = false;
public boolean playerFixStuckPortal = false; public boolean playerFixStuckPortal = false;
public boolean creativeOnePunch = false; public boolean creativeOnePunch = false;
@@ -450,6 +451,7 @@ public class PurpurWorldConfig { @@ -446,6 +447,7 @@ public class PurpurWorldConfig {
playerDeathExpDropEquation = getString("gameplay-mechanics.player.exp-dropped-on-death.equation", playerDeathExpDropEquation); playerDeathExpDropEquation = getString("gameplay-mechanics.player.exp-dropped-on-death.equation", playerDeathExpDropEquation);
playerDeathExpDropMax = getInt("gameplay-mechanics.player.exp-dropped-on-death.maximum", playerDeathExpDropMax); playerDeathExpDropMax = getInt("gameplay-mechanics.player.exp-dropped-on-death.maximum", playerDeathExpDropMax);
teleportIfOutsideBorder = getBoolean("gameplay-mechanics.player.teleport-if-outside-border", teleportIfOutsideBorder); teleportIfOutsideBorder = getBoolean("gameplay-mechanics.player.teleport-if-outside-border", teleportIfOutsideBorder);

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Added got ram event
diff --git a/src/main/java/net/minecraft/world/entity/animal/goat/Goat.java b/src/main/java/net/minecraft/world/entity/animal/goat/Goat.java diff --git a/src/main/java/net/minecraft/world/entity/animal/goat/Goat.java b/src/main/java/net/minecraft/world/entity/animal/goat/Goat.java
index 31cfc2c8c5188a266c9e9993e5cf322e000df397..b04af8b72357b455597d80592c8b8b0c9da744cd 100644 index 976834b381a629b026e42ac0dcb3a8885d24b113..7e36739ce44656f859bf63d0a07f10c8090d0839 100644
--- a/src/main/java/net/minecraft/world/entity/animal/goat/Goat.java --- a/src/main/java/net/minecraft/world/entity/animal/goat/Goat.java
+++ b/src/main/java/net/minecraft/world/entity/animal/goat/Goat.java +++ b/src/main/java/net/minecraft/world/entity/animal/goat/Goat.java
@@ -423,6 +423,7 @@ public class Goat extends Animal { @@ -428,6 +428,7 @@ public class Goat extends Animal {
// Paper start - Goat ram API // Paper start - Goat ram API
public void ram(net.minecraft.world.entity.LivingEntity entity) { public void ram(net.minecraft.world.entity.LivingEntity entity) {

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Log skipped entity's position
diff --git a/src/main/java/net/minecraft/world/entity/EntityType.java b/src/main/java/net/minecraft/world/entity/EntityType.java diff --git a/src/main/java/net/minecraft/world/entity/EntityType.java b/src/main/java/net/minecraft/world/entity/EntityType.java
index e413aa4650297ce2109beb6319f52fb476e291fe..a8ffa403ac48041e17aa4ce057be0539e5468fd4 100644 index 55fced3e70c7bc49306af00dcc1d92ffb83a799b..a9f69e4f880711c21ef28bd079960ef8f12da25c 100644
--- a/src/main/java/net/minecraft/world/entity/EntityType.java --- a/src/main/java/net/minecraft/world/entity/EntityType.java
+++ b/src/main/java/net/minecraft/world/entity/EntityType.java +++ b/src/main/java/net/minecraft/world/entity/EntityType.java
@@ -612,6 +612,12 @@ public class EntityType<T extends Entity> implements FeatureElement, EntityTypeT @@ -611,6 +611,12 @@ public class EntityType<T extends Entity> implements FeatureElement, EntityTypeT
entity.load(nbt); entity.load(nbt);
}, () -> { }, () -> {
EntityType.LOGGER.warn("Skipping Entity with id {}", nbt.getString("id")); EntityType.LOGGER.warn("Skipping Entity with id {}", nbt.getString("id"));

View File

@@ -17,10 +17,10 @@ index 564d17bc460e2a04947ff9676fbf4c8b1569659c..440add62fcfa62d483409e1aecfc9159
// Purpur start // Purpur start
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 059865f4aed093b0a6ee27243305462a31458ef0..fa0b64f60e0e90147dd924272547695af56790a3 100644 index 443871290764e6863509acd0847f8c4c8f8566b6..829f3a7542460ef71bd934ff3dea0321168a9fac 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -881,6 +881,7 @@ public class PurpurWorldConfig { @@ -877,6 +877,7 @@ public class PurpurWorldConfig {
public double basedEndCrystalExplosionPower = 6.0D; public double basedEndCrystalExplosionPower = 6.0D;
public boolean basedEndCrystalExplosionFire = false; public boolean basedEndCrystalExplosionFire = false;
public net.minecraft.world.level.Level.ExplosionInteraction basedEndCrystalExplosionEffect = net.minecraft.world.level.Level.ExplosionInteraction.BLOCK; public net.minecraft.world.level.Level.ExplosionInteraction basedEndCrystalExplosionEffect = net.minecraft.world.level.Level.ExplosionInteraction.BLOCK;
@@ -28,7 +28,7 @@ index 059865f4aed093b0a6ee27243305462a31458ef0..fa0b64f60e0e90147dd924272547695a
private void endCrystalSettings() { private void endCrystalSettings() {
if (PurpurConfig.version < 31) { if (PurpurConfig.version < 31) {
if ("DESTROY".equals(getString("blocks.end-crystal.baseless.explosion-effect", baselessEndCrystalExplosionEffect.name()))) { if ("DESTROY".equals(getString("blocks.end-crystal.baseless.explosion-effect", baselessEndCrystalExplosionEffect.name()))) {
@@ -908,6 +909,7 @@ public class PurpurWorldConfig { @@ -904,6 +905,7 @@ public class PurpurWorldConfig {
log(Level.SEVERE, "Unknown value for `blocks.end-crystal.base.explosion-effect`! Using default of `BLOCK`"); log(Level.SEVERE, "Unknown value for `blocks.end-crystal.base.explosion-effect`! Using default of `BLOCK`");
basedEndCrystalExplosionEffect = net.minecraft.world.level.Level.ExplosionInteraction.BLOCK; basedEndCrystalExplosionEffect = net.minecraft.world.level.Level.ExplosionInteraction.BLOCK;
} }

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Option to allow beacon effects when covered by tinted glass
diff --git a/src/main/java/net/minecraft/world/level/block/entity/BeaconBlockEntity.java b/src/main/java/net/minecraft/world/level/block/entity/BeaconBlockEntity.java diff --git a/src/main/java/net/minecraft/world/level/block/entity/BeaconBlockEntity.java b/src/main/java/net/minecraft/world/level/block/entity/BeaconBlockEntity.java
index 12578b377b6e939971fb2dcba08637df60643e37..2e6220c5a6c871401ce9734adfab710dcf86ad44 100644 index a5f9747be5503dd24abd98f11cfa8229448ca3bf..99ef8d7e3ee0ee9777d12ad825e728c38d886114 100644
--- a/src/main/java/net/minecraft/world/level/block/entity/BeaconBlockEntity.java --- a/src/main/java/net/minecraft/world/level/block/entity/BeaconBlockEntity.java
+++ b/src/main/java/net/minecraft/world/level/block/entity/BeaconBlockEntity.java +++ b/src/main/java/net/minecraft/world/level/block/entity/BeaconBlockEntity.java
@@ -165,6 +165,7 @@ public class BeaconBlockEntity extends BlockEntity implements MenuProvider, Name @@ -174,6 +174,7 @@ public class BeaconBlockEntity extends BlockEntity implements MenuProvider, Name
int j = pos.getY(); int j = pos.getY();
int k = pos.getZ(); int k = pos.getZ();
BlockPos blockposition1; BlockPos blockposition1;
@@ -16,7 +16,7 @@ index 12578b377b6e939971fb2dcba08637df60643e37..2e6220c5a6c871401ce9734adfab710d
if (blockEntity.lastCheckY < j) { if (blockEntity.lastCheckY < j) {
blockposition1 = pos; blockposition1 = pos;
@@ -198,6 +199,9 @@ public class BeaconBlockEntity extends BlockEntity implements MenuProvider, Name @@ -207,6 +208,9 @@ public class BeaconBlockEntity extends BlockEntity implements MenuProvider, Name
} }
} }
} else { } else {
@@ -26,7 +26,7 @@ index 12578b377b6e939971fb2dcba08637df60643e37..2e6220c5a6c871401ce9734adfab710d
if (tileentitybeacon_beaconcolortracker == null || iblockdata1.getLightBlock(world, blockposition1) >= 15 && !iblockdata1.is(Blocks.BEDROCK)) { if (tileentitybeacon_beaconcolortracker == null || iblockdata1.getLightBlock(world, blockposition1) >= 15 && !iblockdata1.is(Blocks.BEDROCK)) {
blockEntity.checkingBeamSections.clear(); blockEntity.checkingBeamSections.clear();
blockEntity.lastCheckY = l; blockEntity.lastCheckY = l;
@@ -217,7 +221,7 @@ public class BeaconBlockEntity extends BlockEntity implements MenuProvider, Name @@ -226,7 +230,7 @@ public class BeaconBlockEntity extends BlockEntity implements MenuProvider, Name
blockEntity.levels = BeaconBlockEntity.updateBase(world, i, j, k); blockEntity.levels = BeaconBlockEntity.updateBase(world, i, j, k);
} }
@@ -36,10 +36,10 @@ index 12578b377b6e939971fb2dcba08637df60643e37..2e6220c5a6c871401ce9734adfab710d
BeaconBlockEntity.playSound(world, pos, SoundEvents.BEACON_AMBIENT); BeaconBlockEntity.playSound(world, pos, SoundEvents.BEACON_AMBIENT);
} }
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index fa0b64f60e0e90147dd924272547695af56790a3..785e4f56c82beb993fc980b9039f184eec98a409 100644 index 829f3a7542460ef71bd934ff3dea0321168a9fac..78e8043f85f65e81db0d4192fbe93df952849490 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -780,11 +780,13 @@ public class PurpurWorldConfig { @@ -776,11 +776,13 @@ public class PurpurWorldConfig {
public int beaconLevelTwo = 30; public int beaconLevelTwo = 30;
public int beaconLevelThree = 40; public int beaconLevelThree = 40;
public int beaconLevelFour = 50; public int beaconLevelFour = 50;

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Config to remove explosion radius clamp
diff --git a/src/main/java/net/minecraft/world/entity/boss/enderdragon/EnderDragon.java b/src/main/java/net/minecraft/world/entity/boss/enderdragon/EnderDragon.java diff --git a/src/main/java/net/minecraft/world/entity/boss/enderdragon/EnderDragon.java b/src/main/java/net/minecraft/world/entity/boss/enderdragon/EnderDragon.java
index a907930813b0a3176354b4b307576d9ff3b0c5ca..ec595b74a6376adb65840035cdaa7502c9a3fe50 100644 index 82d81fd2edff9df0bb4ff116d9274887a316d0a8..823f0e36119079eb827767c08391f18d75b66610 100644
--- a/src/main/java/net/minecraft/world/entity/boss/enderdragon/EnderDragon.java --- a/src/main/java/net/minecraft/world/entity/boss/enderdragon/EnderDragon.java
+++ b/src/main/java/net/minecraft/world/entity/boss/enderdragon/EnderDragon.java +++ b/src/main/java/net/minecraft/world/entity/boss/enderdragon/EnderDragon.java
@@ -109,6 +109,7 @@ public class EnderDragon extends Mob implements Enemy { @@ -111,6 +111,7 @@ public class EnderDragon extends Mob implements Enemy {
public EnderDragon(EntityType<? extends EnderDragon> entitytypes, Level world) { public EnderDragon(EntityType<? extends EnderDragon> entitytypes, Level world) {
super(EntityType.ENDER_DRAGON, world); super(EntityType.ENDER_DRAGON, world);
@@ -17,10 +17,10 @@ index a907930813b0a3176354b4b307576d9ff3b0c5ca..ec595b74a6376adb65840035cdaa7502
this.growlTime = 100; this.growlTime = 100;
this.nodes = new Node[24]; this.nodes = new Node[24];
diff --git a/src/main/java/net/minecraft/world/level/Explosion.java b/src/main/java/net/minecraft/world/level/Explosion.java diff --git a/src/main/java/net/minecraft/world/level/Explosion.java b/src/main/java/net/minecraft/world/level/Explosion.java
index e35ebb5b923c2f63e37e5dae006bc4a030e49bb7..dcc3b333f3647631e2fb695d0854036d3bc009be 100644 index b26cea981a876fd42c9ab91923d507b3c11a0425..b6c8f19a7d919fc56deb3518a28d725e9afbc82b 100644
--- a/src/main/java/net/minecraft/world/level/Explosion.java --- a/src/main/java/net/minecraft/world/level/Explosion.java
+++ b/src/main/java/net/minecraft/world/level/Explosion.java +++ b/src/main/java/net/minecraft/world/level/Explosion.java
@@ -86,7 +86,7 @@ public class Explosion { @@ -87,7 +87,7 @@ public class Explosion {
this.hitPlayers = Maps.newHashMap(); this.hitPlayers = Maps.newHashMap();
this.level = world; this.level = world;
this.source = entity; this.source = entity;
@@ -29,7 +29,7 @@ index e35ebb5b923c2f63e37e5dae006bc4a030e49bb7..dcc3b333f3647631e2fb695d0854036d
this.x = x; this.x = x;
this.y = y; this.y = y;
this.z = z; this.z = z;
@@ -137,7 +137,7 @@ public class Explosion { @@ -403,7 +403,7 @@ public class Explosion {
public void explode() { public void explode() {
// CraftBukkit start // CraftBukkit start
@@ -39,7 +39,7 @@ index e35ebb5b923c2f63e37e5dae006bc4a030e49bb7..dcc3b333f3647631e2fb695d0854036d
} }
// CraftBukkit end // CraftBukkit end
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 785e4f56c82beb993fc980b9039f184eec98a409..2bafe37662ee22dc9f24cf3d5dd198416b495ee7 100644 index 78e8043f85f65e81db0d4192fbe93df952849490..ba7fa9386b494c38e44717529f20c9341e26d9c2 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -213,6 +213,11 @@ public class PurpurWorldConfig { @@ -213,6 +213,11 @@ public class PurpurWorldConfig {

View File

@@ -137,10 +137,10 @@ index c3f500580d257e1397f2eb7c47b063a6fe6bb405..0d5c6bdfd4aeda472804b493315bf21a
+ // Purpur end + // Purpur end
} }
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 2bafe37662ee22dc9f24cf3d5dd198416b495ee7..9365469584fd647dbc52176efb8c282c21dd28d6 100644 index ba7fa9386b494c38e44717529f20c9341e26d9c2..2870a23c01ab5bdb45e355b2f1fd277395ef4771 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -834,8 +834,20 @@ public class PurpurWorldConfig { @@ -830,8 +830,20 @@ public class PurpurWorldConfig {
} }
public boolean cactusBreaksFromSolidNeighbors = true; public boolean cactusBreaksFromSolidNeighbors = true;

View File

@@ -5,10 +5,10 @@ Subject: [PATCH] Add PreExplodeEvents
diff --git a/src/main/java/net/minecraft/world/level/Explosion.java b/src/main/java/net/minecraft/world/level/Explosion.java diff --git a/src/main/java/net/minecraft/world/level/Explosion.java b/src/main/java/net/minecraft/world/level/Explosion.java
index dcc3b333f3647631e2fb695d0854036d3bc009be..4932374ab9a3d8582fb0ef024d817ad896dd23c4 100644 index b6c8f19a7d919fc56deb3518a28d725e9afbc82b..ef9b1687dd2dfda5398523140aecc678b4690642 100644
--- a/src/main/java/net/minecraft/world/level/Explosion.java --- a/src/main/java/net/minecraft/world/level/Explosion.java
+++ b/src/main/java/net/minecraft/world/level/Explosion.java +++ b/src/main/java/net/minecraft/world/level/Explosion.java
@@ -141,6 +141,23 @@ public class Explosion { @@ -407,6 +407,23 @@ public class Explosion {
return; return;
} }
// CraftBukkit end // CraftBukkit end

View File

@@ -27,7 +27,7 @@ index b2233635b6acc35ea3668c36c56e57f15420ac62..724bf857bf1b89cb0947b8a82e0ce09a
public int getValue() { public int getValue() {
return this.value; return this.value;
diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java diff --git a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
index 9365469584fd647dbc52176efb8c282c21dd28d6..76216ce3a481b7430bd5a3d60bb41798216fa692 100644 index 2870a23c01ab5bdb45e355b2f1fd277395ef4771..e7a794ce230c481e39436506facdb77726f96199 100644
--- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java --- a/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
+++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java +++ b/src/main/java/org/purpurmc/purpur/PurpurWorldConfig.java
@@ -119,6 +119,7 @@ public class PurpurWorldConfig { @@ -119,6 +119,7 @@ public class PurpurWorldConfig {

View File

@@ -96,7 +96,7 @@ index 0000000000000000000000000000000000000000..15a226e3854d731f7724025ea3459c8a
+ } + }
+} +}
diff --git a/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java b/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java diff --git a/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java b/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java
index 41db72915baa4c02b11a701dfdde09b66ba72476..12124d6fbc0406bb62bd95a0f7bab68afa43377c 100644 index 6656a3f4dd78270690479639c738fdd0ec7e588d..6e9061dd6d5fd35d74d02c25a5985ffc5bc8e5ac 100644
--- a/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java --- a/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java
+++ b/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java +++ b/src/main/java/net/minecraft/server/dedicated/DedicatedServer.java
@@ -99,6 +99,7 @@ public class DedicatedServer extends MinecraftServer implements ServerInterface @@ -99,6 +99,7 @@ public class DedicatedServer extends MinecraftServer implements ServerInterface

Some files were not shown because too many files have changed in this diff Show More