Skip to content

Commit

Permalink
Fix #276 and #277
Browse files Browse the repository at this point in the history
  • Loading branch information
s-yh-china committed Jul 25, 2024
1 parent 36813ac commit 7d09a3a
Show file tree
Hide file tree
Showing 101 changed files with 40 additions and 41 deletions.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ index 244a19ecd0234fa1d7a6ecfea20751595688605d..7a1f7714616913cbb9d2dfc017567895
String s = (String) Optional.ofNullable((String) optionset.valueOf("world")).orElse(dedicatedserversettings.getProperties().levelName);
LevelStorageSource convertable = LevelStorageSource.createDefault(file.toPath());
diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java
index cb9aae6ff466c07781963ca818ff7421e6bc3964..7f6a25a186ca6ccd30964cf84b2c634bfb030ec9 100644
index a0e4e96addc467c6816ebb42263d5ddd1e2e8ff3..f4a4e5ccd904964de8b813642977cdaa052d6989 100644
--- a/src/main/java/net/minecraft/server/MinecraftServer.java
+++ b/src/main/java/net/minecraft/server/MinecraftServer.java
@@ -265,7 +265,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Subject: [PATCH] Use vanilla random config


diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
index decc1d6be70eb501ebf75dd5907fabfbc2584928..993efcba5c43e2ba6d8fd2eb61215ed67c9c6a6b 100644
index 2563e077ceaf6c21e20f00c59341abcca39c91eb..0f084a9906bd8b20f7b10e47647bfb1b6f7ef710 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -559,7 +559,7 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess
Expand Down Expand Up @@ -44,7 +44,7 @@ index 42f4e544fe7fbc342f15eacb5e38d40849e3c419..0bd9ee3d0b546564a069f4aaf7a33e35
}

diff --git a/src/main/java/net/minecraft/world/entity/item/ItemEntity.java b/src/main/java/net/minecraft/world/entity/item/ItemEntity.java
index 9f86b2c5af580f27f7216b4184acb72b54fee550..d5ea322202b6f9cdc193d4cf2f43c547009e20ff 100644
index a2b9e996fa606d91b153979eefae8974f7ffdf4e..9b8991e562e83c0e3a29f868fa19690e4aa2d453 100644
--- a/src/main/java/net/minecraft/world/entity/item/ItemEntity.java
+++ b/src/main/java/net/minecraft/world/entity/item/ItemEntity.java
@@ -79,7 +79,13 @@ public class ItemEntity extends Entity implements TraceableEntity {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Subject: [PATCH] Disable distance check for UseItemOnPacket


diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
index 7796e191747be545e744564a2b0b65790f69114d..bef88d547aefa9c5b701aa91ffc58114309a7db7 100644
index 7cab641e609cabdb56dc6a9d1efe2e20c1e0f5d2..c87dc4d99e7ea8395145946c9c5cc5e73113cb23 100644
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -1860,7 +1860,7 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Subject: [PATCH] Syncmatica Protocol
This patch is Powered by Syncmatica(https://github.com/End-Tech/syncmatica)

diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
index bef88d547aefa9c5b701aa91ffc58114309a7db7..51a1be78de7a794d13b64db6958977e2e9d20553 100644
index c87dc4d99e7ea8395145946c9c5cc5e73113cb23..32d8d22f5e08f6ebdd06b5057fe1b0451acdf1f2 100644
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -314,6 +314,7 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Subject: [PATCH] Spawn ignore lc


diff --git a/src/main/java/net/minecraft/world/level/NaturalSpawner.java b/src/main/java/net/minecraft/world/level/NaturalSpawner.java
index f0713e797b7ddfd39ebf96712983244f0abcf543..5184df047c329323dfd1ebbf122963b4add098c3 100644
index c5b26fdb173a59280e790a5d5a687e0c0114bb74..7cb97b7623b603aa5469c92f5a6816673c994540 100644
--- a/src/main/java/net/minecraft/world/level/NaturalSpawner.java
+++ b/src/main/java/net/minecraft/world/level/NaturalSpawner.java
@@ -199,6 +199,19 @@ public final class NaturalSpawner {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ index d9c36827706776e143fccd72b53c12a9ac455475..59c023076a7a64049ba478aa049f1910

SectionPos sectionposition = player.getLastSectionPos();
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
index 51a1be78de7a794d13b64db6958977e2e9d20553..31ad4e4aaf321ab3c3909145e36a67744d906c65 100644
index 32d8d22f5e08f6ebdd06b5057fe1b0451acdf1f2..6556fc94295d66eec90492c051053bf24cc8ebd4 100644
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -559,7 +559,7 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl
Expand All @@ -40,7 +40,7 @@ index 51a1be78de7a794d13b64db6958977e2e9d20553..31ad4e4aaf321ab3c3909145e36a6774
!worldserver.areChunksLoadedForMove(entity.getBoundingBox().expandTowards(new Vec3(toX, toY, toZ).subtract(entity.position())))
)) {
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
index 993efcba5c43e2ba6d8fd2eb61215ed67c9c6a6b..3ea0530917fbd347691427cd44344b4659fc6e09 100644
index 0f084a9906bd8b20f7b10e47647bfb1b6f7ef710..d6b90cc6e94d3e81a336cf15910a0c89e69fa96b 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -1136,7 +1136,13 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -218,7 +218,7 @@ index 0846e11c82295ccf93683f877962ec7804dad677..b747b3858befe48996ea707cf126f6f8

for (int j = 0; j < i; ++j) {
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
index 5f779bce04ee8c687550c1386f73550c12da1892..d43f8be8132d825bc84daaa56cc624654e3f04a8 100644
index b79d34a8cfbe562e53960062d8dd9e9e5156a9ed..1b33ac2eaa4d938f8e930fb2bfcc7169f10f851f 100644
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
@@ -181,6 +181,7 @@ import org.bukkit.event.server.MapInitializeEvent;
Expand All @@ -230,7 +230,7 @@ index 5f779bce04ee8c687550c1386f73550c12da1892..d43f8be8132d825bc84daaa56cc62465
public class ServerLevel extends Level implements WorldGenLevel, ca.spottedleaf.moonrise.patches.chunk_system.level.ChunkSystemServerLevel, ca.spottedleaf.moonrise.patches.chunk_system.level.ChunkSystemLevelReader { // 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
index 31ad4e4aaf321ab3c3909145e36a67744d906c65..7ba4f9926a8945651e55aeca99e3badaf258546e 100644
index 6556fc94295d66eec90492c051053bf24cc8ebd4..ec131f0041f9a2167f06a5fc85c2fd01f6062531 100644
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -249,6 +249,7 @@ import org.bukkit.inventory.EquipmentSlot;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Subject: [PATCH] Optimize sun burn tick
This patch is Powered by Gale(https://github.com/GaleMC/Gale)

diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
index d32b658a659c8a139060ac96289ca7497f085d52..8067263c419febe749d15e51511c769d97f325ba 100644
index d6b90cc6e94d3e81a336cf15910a0c89e69fa96b..34610ab46a46a654742132ee35d3ec180d97d2ab 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -2078,8 +2078,22 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Subject: [PATCH] Check frozen ticks before landing block
This patch is Powered by Gale(https://github.com/GaleMC/Gale)

diff --git a/src/main/java/net/minecraft/world/entity/LivingEntity.java b/src/main/java/net/minecraft/world/entity/LivingEntity.java
index 2c385a89db50d85ff65df7b20dcfefdc21856cca..f45c1d6ec163566b7877cf4ec6809b3bb603bb30 100644
index a160a6b3a8634d142436ba4098da219cf4d825a8..fc6bbe34b6ff4912d34f86196c6d55d7116dcedb 100644
--- a/src/main/java/net/minecraft/world/entity/LivingEntity.java
+++ b/src/main/java/net/minecraft/world/entity/LivingEntity.java
@@ -564,11 +564,11 @@ public abstract class LivingEntity extends Entity implements Attackable {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Subject: [PATCH] Skip entity move if movement is zero
This patch is Powered by Gale(https://github.com/GaleMC/Gale)

diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
index 8067263c419febe749d15e51511c769d97f325ba..024ec708fb1dd85f270b1864176e7d70414a225b 100644
index 34610ab46a46a654742132ee35d3ec180d97d2ab..85afcaaa2fee449139e68cdc346738403edc0fdd 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -324,6 +324,7 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Subject: [PATCH] Skip negligible planar movement multiplication
This patch is Powered by Gale(https://github.com/GaleMC/Gale)

diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
index ad919f7c613549a25656109fc66251dcf9f7989b..056f56fd321aa2f23b633f7c59672e2ef4c32a9e 100644
index 85afcaaa2fee449139e68cdc346738403edc0fdd..582d7221b8af8d96909cf240913168fc09c966c4 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -1285,9 +1285,16 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess
Expand Down
19 changes: 19 additions & 0 deletions patches/server/0092-Bow-infinity-fix.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: violetc <[email protected]>
Date: Mon, 24 Jul 2023 15:54:18 +0800
Subject: [PATCH] Bow infinity fix


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 0ee227c0f7d54ed7c686a830873fab6c0cdd2ab5..e381b2d0e64b8d9834b573223f6370afc7c00b11 100644
--- a/src/main/java/net/minecraft/world/entity/player/Player.java
+++ b/src/main/java/net/minecraft/world/entity/player/Player.java
@@ -2342,7 +2342,7 @@ public abstract class Player extends LivingEntity {
}
}

- return this.abilities.instabuild ? new ItemStack(Items.ARROW) : ItemStack.EMPTY;
+ return this.abilities.instabuild || (org.leavesmc.leaves.LeavesConfig.bowInfinityFix && net.minecraft.world.item.enchantment.EnchantmentHelper.processAmmoUse((ServerLevel) this.level(), stack, new ItemStack(Items.ARROW), 1) <= 0) ? new ItemStack(Items.ARROW) : ItemStack.EMPTY;
}
}
}
20 changes: 0 additions & 20 deletions patches/server/0093-Bow-infinity-fix.patch

This file was deleted.

File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Subject: [PATCH] Disable moved wrongly threshold


diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
index 7ba4f9926a8945651e55aeca99e3badaf258546e..b65ef0e04836b85b31e3681b4b25f94c84f9692b 100644
index ec131f0041f9a2167f06a5fc85c2fd01f6062531..3c32c735bf7ed2bcfbd48140543b33ace48bc3c8 100644
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
@@ -569,7 +569,7 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Subject: [PATCH] Make Item tick vanilla


diff --git a/src/main/java/net/minecraft/world/entity/item/ItemEntity.java b/src/main/java/net/minecraft/world/entity/item/ItemEntity.java
index d5ea322202b6f9cdc193d4cf2f43c547009e20ff..26cdc6d7e8026c5290681b87b6b54bb3b7731f1c 100644
index 9b8991e562e83c0e3a29f868fa19690e4aa2d453..75001a1161a5c6dabd84c688424deadb87d3da67 100644
--- a/src/main/java/net/minecraft/world/entity/item/ItemEntity.java
+++ b/src/main/java/net/minecraft/world/entity/item/ItemEntity.java
@@ -252,6 +252,9 @@ public class ItemEntity extends Entity implements TraceableEntity {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Subject: [PATCH] Crafter 1 gt delay


diff --git a/src/main/java/net/minecraft/world/level/block/CrafterBlock.java b/src/main/java/net/minecraft/world/level/block/CrafterBlock.java
index 6c24b25a7c8ce6e34aceb5702f1a0a6732ebca44..d9caca74221e7173096671caae83ba171f4732df 100644
index 391a6af36d4c27a04000b31583297a25b89125d3..b94c5ba94f1e08bc173d8e35cffb67ba736aee18 100644
--- a/src/main/java/net/minecraft/world/level/block/CrafterBlock.java
+++ b/src/main/java/net/minecraft/world/level/block/CrafterBlock.java
@@ -80,7 +80,7 @@ public class CrafterBlock extends BaseEntityBlock {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Subject: [PATCH] Linear region file format
This patch is Powered by LinearPurpur(https://github.com/StupidCraft/LinearPurpur)

diff --git a/build.gradle.kts b/build.gradle.kts
index a04666cc380118c03b6b23df140323659e38c065..0ce1157599acfe8181839955ae76697b4ac6474d 100644
index c06861f287088c04363f45d6e91d29a8596cf8d4..51af52ca06c237fa80df8df8fce86147b6390a08 100644
--- a/build.gradle.kts
+++ b/build.gradle.kts
@@ -30,6 +30,10 @@ dependencies {
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@ Subject: [PATCH] Fix falling block's block location


diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
index 056f56fd321aa2f23b633f7c59672e2ef4c32a9e..73afd4ac34b5e7e26d8acdf59ad60cae2762df57 100644
index 582d7221b8af8d96909cf240913168fc09c966c4..ef01ecfb6f13e2991bf71b447b833c01f3c89abd 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -4838,6 +4838,14 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess
@@ -4751,6 +4751,14 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess
int j = Mth.floor(y);
int k = Mth.floor(z);

Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Subject: [PATCH] Configurable MC-67


diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
index 73afd4ac34b5e7e26d8acdf59ad60cae2762df57..4113a4e5252bbff1047f1119e9fef94f00fa0693 100644
index ef01ecfb6f13e2991bf71b447b833c01f3c89abd..c16a4f9f4dfc05786f1baab0318a65245f920a72 100644
--- a/src/main/java/net/minecraft/world/entity/Entity.java
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
@@ -3914,7 +3914,7 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess
Expand Down
File renamed without changes.

0 comments on commit 7d09a3a

Please sign in to comment.