Compare commits
27 Commits
release-71
...
release-92
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
74c593fa04 | ||
|
|
c6c048c34f | ||
|
|
017f695244 | ||
|
|
ecbebeb403 | ||
|
|
5bf8a8124e | ||
|
|
3e35bff9a0 | ||
|
|
cb7a348e89 | ||
|
|
eea08a3ecd | ||
|
|
b49ad3f336 | ||
|
|
3ba3fe9814 | ||
|
|
2adeb25bff | ||
|
|
c93e0ff16a | ||
|
|
5c5d10ae4e | ||
|
|
057b293ed5 | ||
|
|
9c54aed53d | ||
|
|
a637a72412 | ||
|
|
8f116cc067 | ||
|
|
8b317976a9 | ||
|
|
986a3f4598 | ||
|
|
5671b24941 | ||
|
|
59b163d8fa | ||
|
|
67c03ea3ec | ||
|
|
d8856b5127 | ||
|
|
a76facf92e | ||
|
|
34162ce62e | ||
|
|
eea18dca7c | ||
|
|
f427c79af9 |
@@ -1,2 +1,2 @@
|
||||
purpurCommit = 423c2af60ca5e9d18ac0bd955d0313efc693d2a3
|
||||
pufferfishCommit = a3c0a4d2f177d80283d03de52617732a7b493665
|
||||
purpurCommit = 07b13f287c8c63e5b2f23c32c52e5d8012ff2eb7
|
||||
pufferfishCommit = 0020a8bd30741675ac348af30cc50d19d3566cff
|
||||
|
||||
39
README.md
39
README.md
@@ -1,17 +1,15 @@
|
||||
<div align="center">
|
||||
|
||||

|
||||

|
||||
|
||||
### A Server Platform for Minecraft: Java Edition based on [Paper](https://github.com/PaperMC/Paper)
|
||||
|
||||
[](README.md)
|
||||
[](https://discord.gg/MmfC52K8A8)
|
||||
[](https://github.com/PlazmaMC/Plazma/actions/workflows/build.yml?query=branch:ver/1.20.1)
|
||||
[](https://github.com/PlazmaMC/AlwaysUpToDate/actions/workflows/plazma.yml)
|
||||
|
||||
[](LICENSE)
|
||||
[](https://discord.gg/MmfC52K8A8)
|
||||
[](https://github.com/PlazmaMC/Plazma/releases/latest-1.20.1)
|
||||
|
||||
[](LICENSE)
|
||||
[](https://github.com/PlazmaMC/Plazma/releases/tag/latest-1.20.1)
|
||||
[](https://github.com/PlazmaMC/Plazma/stargazers)
|
||||
[](https://github.com/PPlazmaMC/Plazma/network/members)
|
||||
@@ -19,30 +17,15 @@
|
||||
|
||||
</div>
|
||||
|
||||
## ⚠️ Warning
|
||||
- Plazma may cause **<u>unexpected problems</u>**, so **don't use** it in production server!
|
||||
[main]: https://github.com/PlazmaMC/Plazma
|
||||
|
||||
## 💬 About Plazma...
|
||||
- **Plazma** is created from the merger of **[Andromeda](https://github.com/TeamEarendel/Andromeda)** and **[Fusion](https://github.com/RuinedTechnologyUnify/Fusion)**
|
||||
- Compatible and effective patches from other bukkits and mods
|
||||
- We're always trying to keep it compatible and performance high.
|
||||
|
||||
## ⚙️ Features
|
||||
- **Based on [Paper](https://github.com/PaperMC/Paper)** - Most plugins of Bukkit, Craft Bukkit, Spigot, and Paper are available
|
||||
- **Including [Pufferfish](https://github.com/pufferfish-gg/Pufferfish) and [Purpur](https://github.com/PurpurMC/Purpur)** - Provides multiple optimizations and customizations
|
||||
### This is the branch for Plazma 1.20.1. If you want to know more about Plazma, please check the [main branch][main].
|
||||
이곳은 플라즈마의 1.20.1용 브랜치 입니다. 플라즈마에 대해 자세히 알고 싶다면 [main 브랜치][main]를 확인해주세요.
|
||||
|
||||
## ⬇️ Downloads
|
||||
- You can download the file from [Releases](https://github.com/PlazmaMC/Plazma/releases)
|
||||
- Direct latest download: [Click here](https://github.com/PlazmaMC/Plazma/releases/download/latest-1.20.1/plazma-paperclip-1.20.1-R0.1-SNAPSHOT-reobf.jar)
|
||||
- NOTE: If you don't know about Mojmap or Bundler, download `plazma-paperclip-*-reobf.jar`
|
||||
### If you don't know about Mojmap or Bundler, download **Reobf Paperclip**
|
||||
Mojmap 또는 Bundler에 대해 잘 알지 못한다면, **Reobf Paperclip**을 사용하세요
|
||||
|
||||
## ⚖️ License
|
||||
- This project and all patches are licensed under the [MIT license](LICENSE.md) unless otherwise noted in the patch headers.
|
||||
|
||||
## 🌀 Sponsorship - Minecraft Development Dictionary (KOREAN)
|
||||
[](https://discord.gg/AZwXTA9Pgx)
|
||||
- 한글로 번역&정리된 Minecraft와 서드파티 버킷들의 소식들을 빠르게 만나볼 수 있습니다.
|
||||
- Skript와 Plugin등 서버 개발과 관련된 질문에 대한 답변을 받으실 수 있습니다.
|
||||
|
||||
## 📈 bStats
|
||||
[](https://bstats.org/plugin/server-implementation/Plazma/18047)
|
||||
| **Reobf Paperclip (Default)** | Mojmap Paperclip | Reobf Bundler | Mojmap Bundler |
|
||||
| :---: | :---: | :---: | :---: |
|
||||
| [Download](https://github.com/PlazmaMC/Plazma/releases/download/latest-1.20.1/plazma-paperclip-1.20.1-R0.1-SNAPSHOT-reobf.jar) | [Download](https://github.com/PlazmaMC/Plazma/releases/download/latest-1.20.1/plazma-paperclip-1.20.1-R0.1-SNAPSHOT-mojmap.jar) | [Download](https://github.com/PlazmaMC/Plazma/releases/download/latest-1.20.1/plazma-bundler-1.20.1-R0.1-SNAPSHOT-reobf.jar) | [Download](https://github.com/PlazmaMC/Plazma/releases/download/latest-1.20.1/plazma-bundler-1.20.1-R0.1-SNAPSHOT-mojmap.jar) |
|
||||
|
||||
@@ -18,7 +18,7 @@ repositories {
|
||||
}
|
||||
|
||||
dependencies {
|
||||
remapper("net.fabricmc:tiny-remapper:0.8.6:fat")
|
||||
remapper("net.fabricmc:tiny-remapper:0.8.9:fat")
|
||||
decompiler("net.minecraftforge:forgeflower:2.0.627.2")
|
||||
paperclip("io.papermc:paperclip:3.0.3")
|
||||
}
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
group = org.plazmamc.plazma
|
||||
version = 1.20.1-R0.1-SNAPSHOT
|
||||
|
||||
paperCommit = b4e3b3d1dd447bac4cbf478595c1ec320bc6dd4b
|
||||
paperCommit = 29d1c7b60244bb002d29a5dcfc9c995019f550ab
|
||||
|
||||
org.gradle.caching = true
|
||||
org.gradle.parallel = true
|
||||
|
||||
2
gradle/wrapper/gradle-wrapper.properties
vendored
2
gradle/wrapper/gradle-wrapper.properties
vendored
@@ -1,6 +1,6 @@
|
||||
distributionBase=GRADLE_USER_HOME
|
||||
distributionPath=wrapper/dists
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.1.1-bin.zip
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.3-bin.zip
|
||||
networkTimeout=10000
|
||||
zipStoreBase=GRADLE_USER_HOME
|
||||
zipStorePath=wrapper/dists
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Kevin Raneri <kevin.raneri@gmail.com>
|
||||
Date: Tue, 9 Nov 2021 14:01:56 -0500
|
||||
From: AlphaKR93 <dev@alpha93.kr>
|
||||
Date: Fri, 15 Sep 2023 16:37:43 +0000
|
||||
Subject: [PATCH] Pufferfish API Changes
|
||||
|
||||
Original: Kevin Raneri <kevin.raneri@gmail.com>
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: BillyGalbreath <Blake.Galbreath@Gmail.com>
|
||||
Date: Tue, 4 Jan 2022 23:05:41 -0600
|
||||
From: AlphaKR93 <dev@alpha93.kr>
|
||||
Date: Fri, 15 Sep 2023 16:39:50 +0000
|
||||
Subject: [PATCH] Purpur API Changes
|
||||
|
||||
Original: PurpurMC
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Kevin Raneri <kevin.raneri@gmail.com>
|
||||
Date: Wed, 3 Feb 2021 23:02:38 -0600
|
||||
From: AlphaKR93 <dev@alpha93.kr>
|
||||
Date: Fri, 15 Sep 2023 16:37:43 +0000
|
||||
Subject: [PATCH] Pufferfish Server Changes
|
||||
|
||||
Original: Kevin Raneri <kevin.raneri@gmail.com>
|
||||
@@ -16,6 +16,9 @@ but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
diff --git a/build.gradle.kts b/build.gradle.kts
|
||||
index fb98936bb8a5488db75d676c5bcb4060597fbbf8..f6cd7b910ce41a254e71bf0fcfe93c38abbb1445 100644
|
||||
--- a/build.gradle.kts
|
||||
@@ -613,10 +616,10 @@ index 0000000000000000000000000000000000000000..020368da69b9a492155f6de6297f7473
|
||||
+}
|
||||
diff --git a/src/main/java/gg/pufferfish/pufferfish/PufferfishConfig.java b/src/main/java/gg/pufferfish/pufferfish/PufferfishConfig.java
|
||||
new file mode 100644
|
||||
index 0000000000000000000000000000000000000000..3d4bb28fe686a9ad2e4c0f75f21e6289c2ea5cf9
|
||||
index 0000000000000000000000000000000000000000..95d1a8a5b349f7849c040026bfa3469d03d92bfd
|
||||
--- /dev/null
|
||||
+++ b/src/main/java/gg/pufferfish/pufferfish/PufferfishConfig.java
|
||||
@@ -0,0 +1,296 @@
|
||||
@@ -0,0 +1,295 @@
|
||||
+package gg.pufferfish.pufferfish;
|
||||
+
|
||||
+import gg.pufferfish.pufferfish.simd.SIMDDetection;
|
||||
@@ -901,7 +904,6 @@ index 0000000000000000000000000000000000000000..3d4bb28fe686a9ad2e4c0f75f21e6289
|
||||
+ "the ender dragon whenever a player places an end crystal.");
|
||||
+ }
|
||||
+
|
||||
+
|
||||
+ public static boolean disableMethodProfiler;
|
||||
+ public static boolean disableOutOfOrderChat;
|
||||
+ public static boolean suppressNullIdDisconnections;
|
||||
@@ -2132,7 +2134,7 @@ index 9afc81ccb237c3655d64cdbe8a0db9a4d7791043..aa5cec6d56d7a8e80861aa4c9b4a74ca
|
||||
private String descriptionId;
|
||||
@Nullable
|
||||
diff --git a/src/main/java/net/minecraft/world/entity/LivingEntity.java b/src/main/java/net/minecraft/world/entity/LivingEntity.java
|
||||
index e11d7283662834047b2ff81a2fd25a4263792deb..e9a31314424d9db911cd9806741222397c3072d7 100644
|
||||
index 78c98f38bc263664ea4cd344670243a7d372885c..d265a32bd273beed0e65e224e1c5f9c0bca7b3fb 100644
|
||||
--- a/src/main/java/net/minecraft/world/entity/LivingEntity.java
|
||||
+++ b/src/main/java/net/minecraft/world/entity/LivingEntity.java
|
||||
@@ -142,7 +142,6 @@ import org.bukkit.event.entity.EntityTeleportEvent;
|
||||
@@ -2148,11 +2150,11 @@ index e11d7283662834047b2ff81a2fd25a4263792deb..e9a31314424d9db911cd980674122239
|
||||
|
||||
if (!this.level().isClientSide) {
|
||||
- if (this.isInWall()) {
|
||||
+ if ((!gg.pufferfish.pufferfish.PufferfishConfig.enableSuffocationOptimization || (tickCount % 10 == 0 && couldPossiblyBeHurt(1.0F))) && this.isInWall()) { // Pufferfish - optimize suffocation
|
||||
+ if (shouldCheckForSuffocation() && this.isInWall()) { // Pufferfish - optimize suffocation
|
||||
this.hurt(this.damageSources().inWall(), 1.0F);
|
||||
} else if (flag && !this.level().getWorldBorder().isWithinBounds(this.getBoundingBox())) {
|
||||
double d0 = this.level().getWorldBorder().getDistanceToBorder(this) + this.level().getWorldBorder().getDamageSafeZone();
|
||||
@@ -1369,6 +1368,15 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
@@ -1369,6 +1368,19 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
return this.getHealth() <= 0.0F;
|
||||
}
|
||||
|
||||
@@ -2163,12 +2165,16 @@ index e11d7283662834047b2ff81a2fd25a4263792deb..e9a31314424d9db911cd980674122239
|
||||
+ }
|
||||
+ return true;
|
||||
+ }
|
||||
+
|
||||
+ public boolean shouldCheckForSuffocation() {
|
||||
+ return !gg.pufferfish.pufferfish.PufferfishConfig.enableSuffocationOptimization || (tickCount % 10 == 0 && couldPossiblyBeHurt(1.0F));
|
||||
+ }
|
||||
+ // Pufferfish end
|
||||
+
|
||||
@Override
|
||||
public boolean hurt(DamageSource source, float amount) {
|
||||
if (this.isInvulnerableTo(source)) {
|
||||
@@ -1965,6 +1973,20 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
@@ -1965,6 +1977,20 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
return this.lastClimbablePos;
|
||||
}
|
||||
|
||||
@@ -2189,18 +2195,6 @@ index e11d7283662834047b2ff81a2fd25a4263792deb..e9a31314424d9db911cd980674122239
|
||||
public boolean onClimbable() {
|
||||
if (this.isSpectator()) {
|
||||
return false;
|
||||
@@ -3651,7 +3673,10 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
Vec3 vec3d1 = new Vec3(entity.getX(), entity.getEyeY(), entity.getZ());
|
||||
|
||||
// Paper - diff on change - used in CraftLivingEntity#hasLineOfSight(Location) and CraftWorld#lineOfSightExists
|
||||
- return vec3d1.distanceToSqr(vec3d) > 128D * 128D ? false : this.level().clip(new ClipContext(vec3d, vec3d1, ClipContext.Block.COLLIDER, ClipContext.Fluid.NONE, this)).getType() == HitResult.Type.MISS;
|
||||
+ // Pufferfish start
|
||||
+ //return vec3d1.distanceToSqr(vec3d) > 128D * 128D ? false : this.level().clip(new ClipContext(vec3d, vec3d1, ClipContext.Block.COLLIDER, ClipContext.Fluid.NONE, this)).getType() == HitResult.Type.MISS;
|
||||
+ return vec3d1.distanceToSqr(vec3d) > 128D * 128D ? false : this.level().rayTraceDirect(vec3d, vec3d1, net.minecraft.world.phys.shapes.CollisionContext.of(this)) == net.minecraft.world.phys.BlockHitResult.Type.MISS;
|
||||
+ // Pufferfish end
|
||||
}
|
||||
}
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/world/entity/Mob.java b/src/main/java/net/minecraft/world/entity/Mob.java
|
||||
index e2a25c29ec74147b3e66aa0b3deb85a8f6ee53a5..f6eb032897c6d5d16ab5c8c287e49e189c24571c 100644
|
||||
--- a/src/main/java/net/minecraft/world/entity/Mob.java
|
||||
@@ -2275,18 +2269,6 @@ index dd1102d5291ef6f18e82400a6d8a0a376cc071e9..e283eb57c25f7de222f9d09dca851169
|
||||
}
|
||||
|
||||
@Nullable
|
||||
diff --git a/src/main/java/net/minecraft/world/entity/ai/behavior/AcquirePoi.java b/src/main/java/net/minecraft/world/entity/ai/behavior/AcquirePoi.java
|
||||
index d4c91e0a0c64fcb7f1145de3f30134cb1f1f8ee6..fe502445a77afe7e3807afae48d7bf03f370e290 100644
|
||||
--- a/src/main/java/net/minecraft/world/entity/ai/behavior/AcquirePoi.java
|
||||
+++ b/src/main/java/net/minecraft/world/entity/ai/behavior/AcquirePoi.java
|
||||
@@ -47,6 +47,7 @@ public class AcquirePoi {
|
||||
return false;
|
||||
} else {
|
||||
mutableLong.setValue(time + 20L + (long)world.getRandom().nextInt(20));
|
||||
+ if (entity.getNavigation().isStuck()) mutableLong.add(200); // Pufferfish - wait an additional 10s to check again if they're stuck
|
||||
PoiManager poiManager = world.getPoiManager();
|
||||
long2ObjectMap.long2ObjectEntrySet().removeIf((entry) -> {
|
||||
return !entry.getValue().isStillValid(time);
|
||||
diff --git a/src/main/java/net/minecraft/world/entity/ai/behavior/VillagerPanicTrigger.java b/src/main/java/net/minecraft/world/entity/ai/behavior/VillagerPanicTrigger.java
|
||||
index 646d9a121d908a2fc3e4e302484dd5cd1bfc6804..e546ecdccde352502e26a8668eaaafe048d6e282 100644
|
||||
--- a/src/main/java/net/minecraft/world/entity/ai/behavior/VillagerPanicTrigger.java
|
||||
@@ -2468,27 +2450,24 @@ index 247aca0b612f5079a0596350e8311c385df8ab1c..7f21d1d400c8a5615ed1a787dcb06803
|
||||
this.getBrain().tick((ServerLevel) this.level(), this);
|
||||
this.level().getProfiler().pop();
|
||||
this.level().getProfiler().push("goatActivityUpdate");
|
||||
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 52196431a6538872755344859a0454a0e50c3b6e..80fc7918cb294b0d88a293bd6a920441cb55c3ad 100644
|
||||
--- a/src/main/java/net/minecraft/world/entity/item/ItemEntity.java
|
||||
+++ b/src/main/java/net/minecraft/world/entity/item/ItemEntity.java
|
||||
@@ -270,10 +270,16 @@ public class ItemEntity extends Entity implements TraceableEntity {
|
||||
if (entityitem.isMergable()) {
|
||||
// Paper Start - Fix items merging through walls
|
||||
if (this.level().paperConfig().fixes.fixItemsMergingThroughWalls) {
|
||||
+ // Pufferfish start - skip the allocations
|
||||
+ /*
|
||||
net.minecraft.world.level.ClipContext rayTrace = new net.minecraft.world.level.ClipContext(this.position(), entityitem.position(),
|
||||
net.minecraft.world.level.ClipContext.Block.COLLIDER, net.minecraft.world.level.ClipContext.Fluid.NONE, this);
|
||||
net.minecraft.world.phys.BlockHitResult rayTraceResult = this.level().clip(rayTrace);
|
||||
if (rayTraceResult.getType() == net.minecraft.world.phys.HitResult.Type.BLOCK) continue;
|
||||
+ */
|
||||
+ if (level().rayTraceDirect(this.position(), entityitem.position(), net.minecraft.world.phys.shapes.CollisionContext.of(this)) ==
|
||||
+ net.minecraft.world.phys.HitResult.Type.BLOCK) continue;
|
||||
+ // Pufferfish end
|
||||
}
|
||||
// Paper End
|
||||
this.tryToMerge(entityitem);
|
||||
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 1e07febcf7a3dfb281728cc5e3e4f15dd776d7e0..c65ab566c6241dd6a44bd11a449ef0c4b2f6dc65 100644
|
||||
--- a/src/main/java/net/minecraft/world/entity/boss/wither/WitherBoss.java
|
||||
+++ b/src/main/java/net/minecraft/world/entity/boss/wither/WitherBoss.java
|
||||
@@ -150,6 +150,13 @@ public class WitherBoss extends Monster implements PowerableMob, RangedAttackMob
|
||||
this.bossEvent.setName(this.getDisplayName());
|
||||
}
|
||||
|
||||
+ // Pufferfish start - optimize suffocation
|
||||
+ @Override
|
||||
+ public boolean shouldCheckForSuffocation() {
|
||||
+ return true;
|
||||
+ }
|
||||
+ // Pufferfish end
|
||||
+
|
||||
@Override
|
||||
protected SoundEvent getAmbientSound() {
|
||||
return SoundEvents.WITHER_AMBIENT;
|
||||
diff --git a/src/main/java/net/minecraft/world/entity/monster/EnderMan.java b/src/main/java/net/minecraft/world/entity/monster/EnderMan.java
|
||||
index b62457313a1e30aad0c5313d608667b5d3811455..410f10ad93935d1c078447a4596023f367a8e9b7 100644
|
||||
--- a/src/main/java/net/minecraft/world/entity/monster/EnderMan.java
|
||||
@@ -2777,29 +2756,8 @@ index 2e60bdc44c33d434bfd9ca5bf8f75de799c6768c..565318c2afaa1661ed9963453a6354df
|
||||
StackedContents autorecipestackmanager = new StackedContents();
|
||||
autorecipestackmanager.initialize(this); // Paper - better exact choice recipes
|
||||
int i = 0;
|
||||
diff --git a/src/main/java/net/minecraft/world/level/BlockGetter.java b/src/main/java/net/minecraft/world/level/BlockGetter.java
|
||||
index 0e8746759752b692668886370181aa5db1fd0bb0..58e5ce2afabf480f5dfd9adf43f8fc12666861c6 100644
|
||||
--- a/src/main/java/net/minecraft/world/level/BlockGetter.java
|
||||
+++ b/src/main/java/net/minecraft/world/level/BlockGetter.java
|
||||
@@ -68,6 +68,16 @@ public interface BlockGetter extends LevelHeightAccessor {
|
||||
});
|
||||
}
|
||||
|
||||
+ // Pufferfish start - broken down variant of below rayTraceBlock, used by World#rayTraceDirect
|
||||
+ default net.minecraft.world.phys.BlockHitResult.Type rayTraceBlockDirect(Vec3 vec3d, Vec3 vec3d1, BlockPos blockposition, BlockState iblockdata, net.minecraft.world.phys.shapes.CollisionContext voxelshapecoll) {
|
||||
+ if (iblockdata.isAir()) return null; // Tuinity - optimise air cases
|
||||
+ VoxelShape voxelshape = ClipContext.Block.COLLIDER.get(iblockdata, this, blockposition, voxelshapecoll);
|
||||
+ net.minecraft.world.phys.BlockHitResult movingobjectpositionblock = this.clipWithInteractionOverride(vec3d, vec3d1, blockposition, voxelshape, iblockdata);
|
||||
+
|
||||
+ return movingobjectpositionblock == null ? null : movingobjectpositionblock.getType();
|
||||
+ }
|
||||
+ // Pufferfish end
|
||||
+
|
||||
// CraftBukkit start - moved block handling into separate method for use by Block#rayTrace
|
||||
default BlockHitResult clip(ClipContext raytrace1, BlockPos blockposition) {
|
||||
// Paper start - Prevent raytrace from loading chunks
|
||||
diff --git a/src/main/java/net/minecraft/world/level/Level.java b/src/main/java/net/minecraft/world/level/Level.java
|
||||
index f39ab10c5b0b8d86b579a5b683491204c51db70b..d8d4a1ca2eb062af8b2de4ab44503983587cdd77 100644
|
||||
index 773bfdd3ed457a352b5329f280c0d10297d579ba..5c83d703211725ddc36602bb480545288d6a06d9 100644
|
||||
--- a/src/main/java/net/minecraft/world/level/Level.java
|
||||
+++ b/src/main/java/net/minecraft/world/level/Level.java
|
||||
@@ -273,6 +273,17 @@ public abstract class Level implements LevelAccessor, AutoCloseable {
|
||||
@@ -2834,99 +2792,7 @@ index f39ab10c5b0b8d86b579a5b683491204c51db70b..d8d4a1ca2eb062af8b2de4ab44503983
|
||||
this.dimension = resourcekey;
|
||||
this.isClientSide = flag;
|
||||
if (dimensionmanager.coordinateScale() != 1.0D) {
|
||||
@@ -412,6 +430,91 @@ public abstract class Level implements LevelAccessor, AutoCloseable {
|
||||
return null;
|
||||
}
|
||||
|
||||
+ // Pufferfish start - broken down method of raytracing for EntityLiving#hasLineOfSight, replaces IBlockAccess#rayTrace(RayTrace)
|
||||
+ public net.minecraft.world.phys.BlockHitResult.Type rayTraceDirect(net.minecraft.world.phys.Vec3 vec3d, net.minecraft.world.phys.Vec3 vec3d1, net.minecraft.world.phys.shapes.CollisionContext voxelshapecoll) {
|
||||
+ // most of this code comes from IBlockAccess#a(RayTrace, BiFunction, Function), but removes the needless functions
|
||||
+ if (vec3d.equals(vec3d1)) {
|
||||
+ return net.minecraft.world.phys.BlockHitResult.Type.MISS;
|
||||
+ }
|
||||
+
|
||||
+ double endX = Mth.lerp(-1.0E-7D, vec3d1.x, vec3d.x);
|
||||
+ double endY = Mth.lerp(-1.0E-7D, vec3d1.y, vec3d.y);
|
||||
+ double endZ = Mth.lerp(-1.0E-7D, vec3d1.z, vec3d.z);
|
||||
+
|
||||
+ double startX = Mth.lerp(-1.0E-7D, vec3d.x, vec3d1.x);
|
||||
+ double startY = Mth.lerp(-1.0E-7D, vec3d.y, vec3d1.y);
|
||||
+ double startZ = Mth.lerp(-1.0E-7D, vec3d.z, vec3d1.z);
|
||||
+
|
||||
+ int currentX = Mth.floor(startX);
|
||||
+ int currentY = Mth.floor(startY);
|
||||
+ int currentZ = Mth.floor(startZ);
|
||||
+
|
||||
+ BlockPos.MutableBlockPos currentBlock = new BlockPos.MutableBlockPos(currentX, currentY, currentZ);
|
||||
+
|
||||
+ LevelChunk chunk = this.getChunkIfLoaded(currentBlock);
|
||||
+ if (chunk == null) {
|
||||
+ return net.minecraft.world.phys.BlockHitResult.Type.MISS;
|
||||
+ }
|
||||
+
|
||||
+ net.minecraft.world.phys.BlockHitResult.Type initialCheck = this.rayTraceBlockDirect(vec3d, vec3d1, currentBlock, chunk.getBlockState(currentBlock), voxelshapecoll);
|
||||
+
|
||||
+ if (initialCheck != null) {
|
||||
+ return initialCheck;
|
||||
+ }
|
||||
+
|
||||
+ double diffX = endX - startX;
|
||||
+ double diffY = endY - startY;
|
||||
+ double diffZ = endZ - startZ;
|
||||
+
|
||||
+ int xDirection = Mth.sign(diffX);
|
||||
+ int yDirection = Mth.sign(diffY);
|
||||
+ int zDirection = Mth.sign(diffZ);
|
||||
+
|
||||
+ double normalizedX = xDirection == 0 ? Double.MAX_VALUE : (double) xDirection / diffX;
|
||||
+ double normalizedY = yDirection == 0 ? Double.MAX_VALUE : (double) yDirection / diffY;
|
||||
+ double normalizedZ = zDirection == 0 ? Double.MAX_VALUE : (double) zDirection / diffZ;
|
||||
+
|
||||
+ double normalizedXDirection = normalizedX * (xDirection > 0 ? 1.0D - Mth.frac(startX) : Mth.frac(startX));
|
||||
+ double normalizedYDirection = normalizedY * (yDirection > 0 ? 1.0D - Mth.frac(startY) : Mth.frac(startY));
|
||||
+ double normalizedZDirection = normalizedZ * (zDirection > 0 ? 1.0D - Mth.frac(startZ) : Mth.frac(startZ));
|
||||
+
|
||||
+ net.minecraft.world.phys.BlockHitResult.Type result;
|
||||
+
|
||||
+ do {
|
||||
+ if (normalizedXDirection > 1.0D && normalizedYDirection > 1.0D && normalizedZDirection > 1.0D) {
|
||||
+ return net.minecraft.world.phys.BlockHitResult.Type.MISS;
|
||||
+ }
|
||||
+
|
||||
+ if (normalizedXDirection < normalizedYDirection) {
|
||||
+ if (normalizedXDirection < normalizedZDirection) {
|
||||
+ currentX += xDirection;
|
||||
+ normalizedXDirection += normalizedX;
|
||||
+ } else {
|
||||
+ currentZ += zDirection;
|
||||
+ normalizedZDirection += normalizedZ;
|
||||
+ }
|
||||
+ } else if (normalizedYDirection < normalizedZDirection) {
|
||||
+ currentY += yDirection;
|
||||
+ normalizedYDirection += normalizedY;
|
||||
+ } else {
|
||||
+ currentZ += zDirection;
|
||||
+ normalizedZDirection += normalizedZ;
|
||||
+ }
|
||||
+
|
||||
+ currentBlock.set(currentX, currentY, currentZ);
|
||||
+ if (chunk.getPos().x != currentBlock.getX() >> 4 || chunk.getPos().z != currentBlock.getZ() >> 4) {
|
||||
+ chunk = this.getChunkIfLoaded(currentBlock);
|
||||
+ if (chunk == null) {
|
||||
+ return net.minecraft.world.phys.BlockHitResult.Type.MISS;
|
||||
+ }
|
||||
+ }
|
||||
+ result = this.rayTraceBlockDirect(vec3d, vec3d1, currentBlock, chunk.getBlockState(currentBlock), voxelshapecoll);
|
||||
+ } while (result == null);
|
||||
+
|
||||
+ return result;
|
||||
+ }
|
||||
+ // Pufferfish end
|
||||
+
|
||||
public boolean isInWorldBounds(BlockPos pos) {
|
||||
return pos.isInsideBuildHeightAndWorldBoundsHorizontal(this); // Paper - use better/optimized check
|
||||
}
|
||||
@@ -919,13 +1022,13 @@ public abstract class Level implements LevelAccessor, AutoCloseable {
|
||||
@@ -1003,13 +1021,13 @@ public abstract class Level implements LevelAccessor, AutoCloseable {
|
||||
try {
|
||||
tickConsumer.accept(entity);
|
||||
MinecraftServer.getServer().executeMidTickTasks(); // Paper - execute chunk tasks mid tick
|
||||
@@ -2942,7 +2808,7 @@ index f39ab10c5b0b8d86b579a5b683491204c51db70b..d8d4a1ca2eb062af8b2de4ab44503983
|
||||
// Paper end
|
||||
}
|
||||
}
|
||||
@@ -1380,6 +1483,7 @@ public abstract class Level implements LevelAccessor, AutoCloseable {
|
||||
@@ -1464,6 +1482,7 @@ public abstract class Level implements LevelAccessor, AutoCloseable {
|
||||
}
|
||||
|
||||
public ProfilerFiller getProfiler() {
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: BillyGalbreath <blake.galbreath@gmail.com>
|
||||
Date: Sun, 12 Jun 2022 09:18:57 -0500
|
||||
From: AlphaKR93 <dev@alpha93.kr>
|
||||
Date: Fri, 15 Sep 2023 16:39:49 +0000
|
||||
Subject: [PATCH] Purpur Server Changes
|
||||
|
||||
Original: PurpurMC
|
||||
@@ -342,7 +342,7 @@ index fa56cd09102a89692b42f1d14257990508c5c720..f9251183df72ddc56662fd3f02acf216
|
||||
setListData(vector);
|
||||
}
|
||||
diff --git a/src/main/java/gg/pufferfish/pufferfish/PufferfishConfig.java b/src/main/java/gg/pufferfish/pufferfish/PufferfishConfig.java
|
||||
index 3d4bb28fe686a9ad2e4c0f75f21e6289c2ea5cf9..bff1b41501c040487583a5a279fc7800fc6aedca 100644
|
||||
index 95d1a8a5b349f7849c040026bfa3469d03d92bfd..3e36958365bc136516bafbaad0c168f7956406f1 100644
|
||||
--- a/src/main/java/gg/pufferfish/pufferfish/PufferfishConfig.java
|
||||
+++ b/src/main/java/gg/pufferfish/pufferfish/PufferfishConfig.java
|
||||
@@ -28,6 +28,7 @@ public class PufferfishConfig {
|
||||
@@ -955,7 +955,7 @@ index 9b0049dfeaec9b688bf276f2ac2b18943b5696b2..d7563904232353cbf3b9255cedfb7592
|
||||
return true;
|
||||
}
|
||||
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 52cb6476604c98465f81ff9e8d8344d7536a8868..13144ea01bc27db95a13b267d39529b012a4c9c4 100644
|
||||
--- a/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<?>> {
|
||||
@@ -4794,7 +4794,7 @@ index 759713f7c646aaf1a918c87a2834a1d405385dad..43cdda0cb26c5d5cc9025199eb71673d
|
||||
protected ParticleOptions getInkParticle() {
|
||||
return ParticleTypes.GLOW_SQUID_INK;
|
||||
diff --git a/src/main/java/net/minecraft/world/entity/LivingEntity.java b/src/main/java/net/minecraft/world/entity/LivingEntity.java
|
||||
index e9a31314424d9db911cd9806741222397c3072d7..4cd04661b39a7055f5767a3dff88f9a3e197d810 100644
|
||||
index d265a32bd273beed0e65e224e1c5f9c0bca7b3fb..49906b4dc8392eee592215d0b4cba85267a875fc 100644
|
||||
--- a/src/main/java/net/minecraft/world/entity/LivingEntity.java
|
||||
+++ b/src/main/java/net/minecraft/world/entity/LivingEntity.java
|
||||
@@ -218,9 +218,9 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
@@ -4880,15 +4880,6 @@ index e9a31314424d9db911cd9806741222397c3072d7..4cd04661b39a7055f5767a3dff88f9a3
|
||||
if (this.fireImmune() || this.level().isClientSide) {
|
||||
this.clearFire();
|
||||
}
|
||||
@@ -413,7 +419,7 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
boolean flag = this instanceof net.minecraft.world.entity.player.Player;
|
||||
|
||||
if (!this.level().isClientSide) {
|
||||
- if ((!gg.pufferfish.pufferfish.PufferfishConfig.enableSuffocationOptimization || (tickCount % 10 == 0 && couldPossiblyBeHurt(1.0F))) && this.isInWall()) { // Pufferfish - optimize suffocation
|
||||
+ if (shouldCheckForSuffocation() && this.isInWall()) { // Pufferfish - optimize suffocation // Purpur
|
||||
this.hurt(this.damageSources().inWall(), 1.0F);
|
||||
} else if (flag && !this.level().getWorldBorder().isWithinBounds(this.getBoundingBox())) {
|
||||
double d0 = this.level().getWorldBorder().getDistanceToBorder(this) + this.level().getWorldBorder().getDamageSafeZone();
|
||||
@@ -422,6 +428,7 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
double d1 = this.level().getWorldBorder().getDamagePerBlock();
|
||||
|
||||
@@ -4986,19 +4977,7 @@ index e9a31314424d9db911cd9806741222397c3072d7..4cd04661b39a7055f5767a3dff88f9a3
|
||||
EntityPotionEffectEvent event = CraftEventFactory.callEntityPotionEffectChangeEvent(this, effect, null, cause, EntityPotionEffectEvent.Action.CLEARED);
|
||||
if (event.isCancelled()) {
|
||||
continue;
|
||||
@@ -1376,6 +1412,11 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
return true;
|
||||
}
|
||||
// Pufferfish end
|
||||
+ // Purpur start
|
||||
+ public boolean shouldCheckForSuffocation() {
|
||||
+ return (!gg.pufferfish.pufferfish.PufferfishConfig.enableSuffocationOptimization || (tickCount % 10 == 0 && couldPossiblyBeHurt(1.0F)));
|
||||
+ }
|
||||
+ // Purpur end
|
||||
|
||||
@Override
|
||||
public boolean hurt(DamageSource source, float amount) {
|
||||
@@ -1467,13 +1508,13 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
@@ -1471,13 +1507,13 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
if (entity1 instanceof net.minecraft.world.entity.player.Player) {
|
||||
net.minecraft.world.entity.player.Player entityhuman = (net.minecraft.world.entity.player.Player) entity1;
|
||||
|
||||
@@ -5014,7 +4993,7 @@ index e9a31314424d9db911cd9806741222397c3072d7..4cd04661b39a7055f5767a3dff88f9a3
|
||||
LivingEntity entityliving2 = entitywolf.getOwner();
|
||||
|
||||
if (entityliving2 instanceof net.minecraft.world.entity.player.Player) {
|
||||
@@ -1584,6 +1625,18 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
@@ -1588,6 +1624,18 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
}
|
||||
}
|
||||
|
||||
@@ -5033,7 +5012,7 @@ index e9a31314424d9db911cd9806741222397c3072d7..4cd04661b39a7055f5767a3dff88f9a3
|
||||
org.bukkit.inventory.EquipmentSlot handSlot = (hand != null) ? org.bukkit.craftbukkit.CraftEquipmentSlot.getHand(hand) : null;
|
||||
EntityResurrectEvent event = new EntityResurrectEvent((org.bukkit.entity.LivingEntity) this.getBukkitEntity(), handSlot);
|
||||
event.setCancelled(itemstack == null);
|
||||
@@ -1750,7 +1803,7 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
@@ -1754,7 +1802,7 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
boolean flag = false;
|
||||
|
||||
if (this.dead && adversary instanceof WitherBoss) { // Paper
|
||||
@@ -5042,7 +5021,7 @@ index e9a31314424d9db911cd9806741222397c3072d7..4cd04661b39a7055f5767a3dff88f9a3
|
||||
BlockPos blockposition = this.blockPosition();
|
||||
BlockState iblockdata = Blocks.WITHER_ROSE.defaultBlockState();
|
||||
|
||||
@@ -1796,6 +1849,7 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
@@ -1800,6 +1848,7 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
|
||||
this.dropEquipment(); // CraftBukkit - from below
|
||||
if (this.shouldDropLoot() && this.level().getGameRules().getBoolean(GameRules.RULE_DOMOBLOOT)) {
|
||||
@@ -5050,7 +5029,7 @@ index e9a31314424d9db911cd9806741222397c3072d7..4cd04661b39a7055f5767a3dff88f9a3
|
||||
this.dropFromLootTable(source, flag);
|
||||
// Paper start
|
||||
final boolean prev = this.clearEquipmentSlots;
|
||||
@@ -1804,6 +1858,7 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
@@ -1808,6 +1857,7 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
// Paper end
|
||||
this.dropCustomDeathLoot(source, i, flag);
|
||||
this.clearEquipmentSlots = prev; // Paper
|
||||
@@ -5058,7 +5037,7 @@ index e9a31314424d9db911cd9806741222397c3072d7..4cd04661b39a7055f5767a3dff88f9a3
|
||||
}
|
||||
// CraftBukkit start - Call death event // Paper start - call advancement triggers with correct entity equipment
|
||||
org.bukkit.event.entity.EntityDeathEvent deathEvent = CraftEventFactory.callEntityDeathEvent(this, this.drops, () -> {
|
||||
@@ -2050,7 +2105,7 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
@@ -2054,7 +2104,7 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
MobEffectInstance mobeffect = this.getEffect(MobEffects.JUMP);
|
||||
float f2 = mobeffect == null ? 0.0F : (float) (mobeffect.getAmplifier() + 1);
|
||||
|
||||
@@ -5067,7 +5046,7 @@ index e9a31314424d9db911cd9806741222397c3072d7..4cd04661b39a7055f5767a3dff88f9a3
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2273,6 +2328,20 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
@@ -2277,6 +2327,20 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
}
|
||||
}
|
||||
|
||||
@@ -5088,7 +5067,7 @@ index e9a31314424d9db911cd9806741222397c3072d7..4cd04661b39a7055f5767a3dff88f9a3
|
||||
if (f > 0 || !human) {
|
||||
if (human) {
|
||||
// PAIL: Be sure to drag all this code from the EntityHuman subclass each update.
|
||||
@@ -2489,7 +2558,7 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
@@ -2493,7 +2557,7 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
|
||||
@Override
|
||||
protected void onBelowWorld() {
|
||||
@@ -5097,7 +5076,7 @@ index e9a31314424d9db911cd9806741222397c3072d7..4cd04661b39a7055f5767a3dff88f9a3
|
||||
}
|
||||
|
||||
protected void updateSwingTime() {
|
||||
@@ -2686,7 +2755,7 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
@@ -2690,7 +2754,7 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
}
|
||||
|
||||
protected long lastJumpTime = 0L; // Paper
|
||||
@@ -5106,7 +5085,7 @@ index e9a31314424d9db911cd9806741222397c3072d7..4cd04661b39a7055f5767a3dff88f9a3
|
||||
Vec3 vec3d = this.getDeltaMovement();
|
||||
// Paper start
|
||||
long time = System.nanoTime();
|
||||
@@ -2838,6 +2907,7 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
@@ -2842,6 +2906,7 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
|
||||
if (f3 > 0.0F) {
|
||||
this.playSound(this.getFallDamageSound((int) f3), 1.0F, 1.0F);
|
||||
@@ -5114,7 +5093,7 @@ index e9a31314424d9db911cd9806741222397c3072d7..4cd04661b39a7055f5767a3dff88f9a3
|
||||
this.hurt(this.damageSources().flyIntoWall(), f3);
|
||||
}
|
||||
}
|
||||
@@ -3059,10 +3129,10 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
@@ -3063,10 +3128,10 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
}
|
||||
|
||||
this.run += (f3 - this.run) * 0.3F;
|
||||
@@ -5128,7 +5107,7 @@ index e9a31314424d9db911cd9806741222397c3072d7..4cd04661b39a7055f5767a3dff88f9a3
|
||||
|
||||
// Paper start - stop large pitch and yaw changes from crashing the server
|
||||
this.yRotO += Math.round((this.getYRot() - this.yRotO) / 360.0F) * 360.0F;
|
||||
@@ -3074,7 +3144,7 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
@@ -3078,7 +3143,7 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
this.yHeadRotO += Math.round((this.yHeadRot - this.yHeadRotO) / 360.0F) * 360.0F;
|
||||
// Paper end
|
||||
|
||||
@@ -5137,7 +5116,7 @@ index e9a31314424d9db911cd9806741222397c3072d7..4cd04661b39a7055f5767a3dff88f9a3
|
||||
this.animStep += f2;
|
||||
if (this.isFallFlying()) {
|
||||
++this.fallFlyTicks;
|
||||
@@ -3363,19 +3433,19 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
@@ -3367,19 +3432,19 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
}
|
||||
|
||||
this.setDeltaMovement(d4, d5, d6);
|
||||
@@ -5162,7 +5141,7 @@ index e9a31314424d9db911cd9806741222397c3072d7..4cd04661b39a7055f5767a3dff88f9a3
|
||||
if (this.jumping && this.isAffectedByFluids()) {
|
||||
double d7;
|
||||
|
||||
@@ -3402,8 +3472,8 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
@@ -3406,8 +3471,8 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
this.noJumpDelay = 0;
|
||||
}
|
||||
|
||||
@@ -5173,7 +5152,7 @@ index e9a31314424d9db911cd9806741222397c3072d7..4cd04661b39a7055f5767a3dff88f9a3
|
||||
this.xxa *= 0.98F;
|
||||
this.zza *= 0.98F;
|
||||
this.updateFallFlying();
|
||||
@@ -3430,8 +3500,8 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
@@ -3434,8 +3499,8 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
this.travel(vec3d1);
|
||||
}
|
||||
|
||||
@@ -5184,7 +5163,7 @@ index e9a31314424d9db911cd9806741222397c3072d7..4cd04661b39a7055f5767a3dff88f9a3
|
||||
if (!this.level().isClientSide && !this.isDeadOrDying() && !freezeLocked) { // Paper - Freeze Tick Lock API
|
||||
int i = this.getTicksFrozen();
|
||||
|
||||
@@ -3448,18 +3518,20 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
@@ -3452,18 +3517,20 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
this.hurt(this.damageSources().freeze(), 1.0F);
|
||||
}
|
||||
|
||||
@@ -5210,7 +5189,7 @@ index e9a31314424d9db911cd9806741222397c3072d7..4cd04661b39a7055f5767a3dff88f9a3
|
||||
Location from = new Location(this.level().getWorld(), this.xo, this.yo, this.zo, this.yRotO, this.xRotO);
|
||||
Location to = new Location (this.level().getWorld(), this.getX(), this.getY(), this.getZ(), this.getYRot(), this.getXRot());
|
||||
io.papermc.paper.event.entity.EntityMoveEvent event = new io.papermc.paper.event.entity.EntityMoveEvent(this.getBukkitLivingEntity(), from, to.clone());
|
||||
@@ -3469,12 +3541,48 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
@@ -3473,12 +3540,48 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
this.absMoveTo(event.getTo().getX(), event.getTo().getY(), event.getTo().getZ(), event.getTo().getYaw(), event.getTo().getPitch());
|
||||
}
|
||||
}
|
||||
@@ -5259,7 +5238,7 @@ index e9a31314424d9db911cd9806741222397c3072d7..4cd04661b39a7055f5767a3dff88f9a3
|
||||
}
|
||||
|
||||
public boolean isSensitiveToWater() {
|
||||
@@ -3495,7 +3603,16 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
@@ -3499,7 +3602,16 @@ public abstract class LivingEntity extends Entity implements Attackable {
|
||||
int j = i / 10;
|
||||
|
||||
if (j % 2 == 0) {
|
||||
@@ -10760,7 +10739,7 @@ index a24ae93efcdb2da5782d342c7697a1bb253400c7..ec595b74a6376adb65840035cdaa7502
|
||||
}
|
||||
|
||||
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 1e07febcf7a3dfb281728cc5e3e4f15dd776d7e0..4952a7daa1aad68e3ba53123093cd879e0d544b5 100644
|
||||
index c65ab566c6241dd6a44bd11a449ef0c4b2f6dc65..c94a1b75593ad01e7f79fdc84818ea8ec269e124 100644
|
||||
--- a/src/main/java/net/minecraft/world/entity/boss/wither/WitherBoss.java
|
||||
+++ b/src/main/java/net/minecraft/world/entity/boss/wither/WitherBoss.java
|
||||
@@ -84,20 +84,59 @@ public class WitherBoss extends Monster implements PowerableMob, RangedAttackMob
|
||||
@@ -10954,21 +10933,7 @@ index 1e07febcf7a3dfb281728cc5e3e4f15dd776d7e0..4952a7daa1aad68e3ba53123093cd879
|
||||
|
||||
}
|
||||
|
||||
@@ -150,6 +291,13 @@ public class WitherBoss extends Monster implements PowerableMob, RangedAttackMob
|
||||
this.bossEvent.setName(this.getDisplayName());
|
||||
}
|
||||
|
||||
+ // Purpur start - optimize suffocation
|
||||
+ @Override
|
||||
+ public boolean shouldCheckForSuffocation() {
|
||||
+ return true;
|
||||
+ }
|
||||
+ // Purpur end
|
||||
+
|
||||
@Override
|
||||
protected SoundEvent getAmbientSound() {
|
||||
return SoundEvents.WITHER_AMBIENT;
|
||||
@@ -256,6 +404,16 @@ public class WitherBoss extends Monster implements PowerableMob, RangedAttackMob
|
||||
@@ -263,6 +404,16 @@ public class WitherBoss extends Monster implements PowerableMob, RangedAttackMob
|
||||
|
||||
@Override
|
||||
protected void customServerAiStep() {
|
||||
@@ -10985,7 +10950,7 @@ index 1e07febcf7a3dfb281728cc5e3e4f15dd776d7e0..4952a7daa1aad68e3ba53123093cd879
|
||||
int i;
|
||||
|
||||
if (this.getInvulnerableTicks() > 0) {
|
||||
@@ -272,7 +430,7 @@ public class WitherBoss extends Monster implements PowerableMob, RangedAttackMob
|
||||
@@ -279,7 +430,7 @@ public class WitherBoss extends Monster implements PowerableMob, RangedAttackMob
|
||||
}
|
||||
// CraftBukkit end
|
||||
|
||||
@@ -10994,7 +10959,7 @@ index 1e07febcf7a3dfb281728cc5e3e4f15dd776d7e0..4952a7daa1aad68e3ba53123093cd879
|
||||
// CraftBukkit start - Use relative location for far away sounds
|
||||
// this.level().globalLevelEvent(1023, new BlockPosition(this), 0);
|
||||
int viewDistance = ((ServerLevel) this.level()).getCraftServer().getViewDistance() * 16;
|
||||
@@ -296,7 +454,7 @@ public class WitherBoss extends Monster implements PowerableMob, RangedAttackMob
|
||||
@@ -303,7 +454,7 @@ public class WitherBoss extends Monster implements PowerableMob, RangedAttackMob
|
||||
|
||||
this.setInvulnerableTicks(i);
|
||||
if (this.tickCount % 10 == 0) {
|
||||
@@ -11003,7 +10968,7 @@ index 1e07febcf7a3dfb281728cc5e3e4f15dd776d7e0..4952a7daa1aad68e3ba53123093cd879
|
||||
}
|
||||
|
||||
} else {
|
||||
@@ -356,7 +514,7 @@ public class WitherBoss extends Monster implements PowerableMob, RangedAttackMob
|
||||
@@ -363,7 +514,7 @@ public class WitherBoss extends Monster implements PowerableMob, RangedAttackMob
|
||||
|
||||
if (this.destroyBlocksTick > 0) {
|
||||
--this.destroyBlocksTick;
|
||||
@@ -11012,7 +10977,7 @@ index 1e07febcf7a3dfb281728cc5e3e4f15dd776d7e0..4952a7daa1aad68e3ba53123093cd879
|
||||
i = Mth.floor(this.getY());
|
||||
j = Mth.floor(this.getX());
|
||||
int i1 = Mth.floor(this.getZ());
|
||||
@@ -389,8 +547,10 @@ public class WitherBoss extends Monster implements PowerableMob, RangedAttackMob
|
||||
@@ -396,8 +547,10 @@ public class WitherBoss extends Monster implements PowerableMob, RangedAttackMob
|
||||
}
|
||||
}
|
||||
|
||||
@@ -11025,7 +10990,7 @@ index 1e07febcf7a3dfb281728cc5e3e4f15dd776d7e0..4952a7daa1aad68e3ba53123093cd879
|
||||
}
|
||||
|
||||
this.bossEvent.setProgress(this.getHealth() / this.getMaxHealth());
|
||||
@@ -576,11 +736,11 @@ public class WitherBoss extends Monster implements PowerableMob, RangedAttackMob
|
||||
@@ -583,11 +736,11 @@ public class WitherBoss extends Monster implements PowerableMob, RangedAttackMob
|
||||
}
|
||||
|
||||
public int getAlternativeTarget(int headIndex) {
|
||||
@@ -11039,7 +11004,7 @@ index 1e07febcf7a3dfb281728cc5e3e4f15dd776d7e0..4952a7daa1aad68e3ba53123093cd879
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -595,6 +755,7 @@ public class WitherBoss extends Monster implements PowerableMob, RangedAttackMob
|
||||
@@ -602,6 +755,7 @@ public class WitherBoss extends Monster implements PowerableMob, RangedAttackMob
|
||||
|
||||
@Override
|
||||
protected boolean canRide(Entity entity) {
|
||||
@@ -11178,7 +11143,7 @@ index 18eaccb39a4c81338a8cbebe3de03934913ac2a4..7ad5583f05b608d5a34a33fb77c5bf91
|
||||
}
|
||||
// Paper end - fix sand duping
|
||||
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 80fc7918cb294b0d88a293bd6a920441cb55c3ad..d045877bfb0f364a43c8448cad21cc39d0565964 100644
|
||||
index d39f31e7cf315c7cdc1daab28164380e44dd8341..028b83b8e835cfdad19ae9edad76c524b98ead7f 100644
|
||||
--- a/src/main/java/net/minecraft/world/entity/item/ItemEntity.java
|
||||
+++ b/src/main/java/net/minecraft/world/entity/item/ItemEntity.java
|
||||
@@ -56,6 +56,12 @@ public class ItemEntity extends Entity implements TraceableEntity {
|
||||
@@ -11194,23 +11159,25 @@ index 80fc7918cb294b0d88a293bd6a920441cb55c3ad..d045877bfb0f364a43c8448cad21cc39
|
||||
|
||||
public ItemEntity(EntityType<? extends ItemEntity> type, Level world) {
|
||||
super(type, world);
|
||||
@@ -358,6 +364,15 @@ public class ItemEntity extends Entity implements TraceableEntity {
|
||||
return false;
|
||||
} else if (!this.getItem().getItem().canBeHurtBy(source)) {
|
||||
return false;
|
||||
@@ -346,7 +352,16 @@ public class ItemEntity extends Entity implements TraceableEntity {
|
||||
|
||||
@Override
|
||||
public boolean hurt(DamageSource source, float amount) {
|
||||
- if (this.isInvulnerableTo(source)) {
|
||||
+ // Purpur start
|
||||
+ } else if (
|
||||
+ (immuneToCactus && source.is(net.minecraft.world.damagesource.DamageTypes.CACTUS)) ||
|
||||
+ (immuneToFire && (source.is(DamageTypeTags.IS_FIRE) && source.is(net.minecraft.world.damagesource.DamageTypes.IN_FIRE)) ||
|
||||
+ (immuneToLightning && source.is(net.minecraft.world.damagesource.DamageTypes.LIGHTNING_BOLT)) ||
|
||||
+ (immuneToExplosion && source.is(DamageTypeTags.IS_EXPLOSION)))
|
||||
+ if (
|
||||
+ (immuneToCactus && source.is(net.minecraft.world.damagesource.DamageTypes.CACTUS)) ||
|
||||
+ (immuneToFire && (source.is(DamageTypeTags.IS_FIRE) || source.is(net.minecraft.world.damagesource.DamageTypes.ON_FIRE) || source.is(net.minecraft.world.damagesource.DamageTypes.IN_FIRE))) ||
|
||||
+ (immuneToLightning && source.is(net.minecraft.world.damagesource.DamageTypes.LIGHTNING_BOLT)) ||
|
||||
+ (immuneToExplosion && source.is(DamageTypeTags.IS_EXPLOSION))
|
||||
+ ) {
|
||||
+ return false;
|
||||
+ } else if (this.isInvulnerableTo(source)) {
|
||||
+ // Purpur end
|
||||
} else if (this.level().isClientSide) {
|
||||
return true;
|
||||
} else {
|
||||
@@ -555,6 +570,12 @@ public class ItemEntity extends Entity implements TraceableEntity {
|
||||
return false;
|
||||
} else if (!this.getItem().isEmpty() && this.getItem().is(Items.NETHER_STAR) && source.is(DamageTypeTags.IS_EXPLOSION)) {
|
||||
return false;
|
||||
@@ -549,6 +564,12 @@ public class ItemEntity extends Entity implements TraceableEntity {
|
||||
// com.google.common.base.Preconditions.checkArgument(!stack.isEmpty(), "Cannot drop air"); // CraftBukkit // Paper - Remove check
|
||||
this.getEntityData().set(ItemEntity.DATA_ITEM, stack);
|
||||
this.despawnRate = this.level().paperConfig().entities.spawning.altItemDespawnRate.enabled ? this.level().paperConfig().entities.spawning.altItemDespawnRate.items.getOrDefault(stack.getItem(), this.level().spigotConfig.itemDespawnRate) : this.level().spigotConfig.itemDespawnRate; // Paper
|
||||
@@ -16136,7 +16103,7 @@ index b16d9e2eaa589f19c563ee70b1a56d67dbcdecb0..71beab673f04cd051c46ea37f8c84731
|
||||
public static final FoodProperties BAKED_POTATO = (new FoodProperties.Builder()).nutrition(5).saturationMod(0.6F).build();
|
||||
public static final FoodProperties BEEF = (new FoodProperties.Builder()).nutrition(3).saturationMod(0.3F).meat().build();
|
||||
diff --git a/src/main/java/net/minecraft/world/inventory/AbstractContainerMenu.java b/src/main/java/net/minecraft/world/inventory/AbstractContainerMenu.java
|
||||
index 706b354ac9a1a6a4a1e61b2a109180d1dd22bbbd..9ca261c9f21279558961649cb4849ac379d67573 100644
|
||||
index 71b7a091e56dd68da280d13318a393170967b042..9614a0b5b32d88a5b212e33af649ca1aa2a22dfd 100644
|
||||
--- a/src/main/java/net/minecraft/world/inventory/AbstractContainerMenu.java
|
||||
+++ b/src/main/java/net/minecraft/world/inventory/AbstractContainerMenu.java
|
||||
@@ -76,6 +76,7 @@ public abstract class AbstractContainerMenu {
|
||||
@@ -17591,7 +17558,7 @@ index 8f97c9df726ac20cfce7bdddd5dd4f8c5aa76c35..4932374ab9a3d8582fb0ef024d817ad8
|
||||
}
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/world/level/Level.java b/src/main/java/net/minecraft/world/level/Level.java
|
||||
index d8d4a1ca2eb062af8b2de4ab44503983587cdd77..bdb32964524cb2a4398b8d3bedfb03b0cb805b6d 100644
|
||||
index 5c83d703211725ddc36602bb480545288d6a06d9..80ab17142c34d576409e5fb353ff31db9673b2c0 100644
|
||||
--- a/src/main/java/net/minecraft/world/level/Level.java
|
||||
+++ b/src/main/java/net/minecraft/world/level/Level.java
|
||||
@@ -176,6 +176,7 @@ public abstract class Level implements LevelAccessor, AutoCloseable {
|
||||
@@ -17670,7 +17637,7 @@ index d8d4a1ca2eb062af8b2de4ab44503983587cdd77..bdb32964524cb2a4398b8d3bedfb03b0
|
||||
this.generator = gen;
|
||||
this.world = new CraftWorld((ServerLevel) this, gen, biomeProvider, env);
|
||||
|
||||
@@ -967,18 +1013,18 @@ public abstract class Level implements LevelAccessor, AutoCloseable {
|
||||
@@ -966,18 +1012,18 @@ public abstract class Level implements LevelAccessor, AutoCloseable {
|
||||
}
|
||||
|
||||
protected void tickBlockEntities() {
|
||||
@@ -17694,7 +17661,7 @@ index d8d4a1ca2eb062af8b2de4ab44503983587cdd77..bdb32964524cb2a4398b8d3bedfb03b0
|
||||
// Spigot start
|
||||
// Iterator iterator = this.blockEntityTickers.iterator();
|
||||
int tilesThisCycle = 0;
|
||||
@@ -1011,10 +1057,10 @@ public abstract class Level implements LevelAccessor, AutoCloseable {
|
||||
@@ -1010,10 +1056,10 @@ public abstract class Level implements LevelAccessor, AutoCloseable {
|
||||
}
|
||||
this.blockEntityTickers.removeAll(toRemove);
|
||||
|
||||
@@ -17707,7 +17674,7 @@ index d8d4a1ca2eb062af8b2de4ab44503983587cdd77..bdb32964524cb2a4398b8d3bedfb03b0
|
||||
spigotConfig.currentPrimedTnt = 0; // Spigot
|
||||
}
|
||||
|
||||
@@ -1207,7 +1253,7 @@ public abstract class Level implements LevelAccessor, AutoCloseable {
|
||||
@@ -1206,7 +1252,7 @@ public abstract class Level implements LevelAccessor, AutoCloseable {
|
||||
|
||||
@Override
|
||||
public List<Entity> getEntities(@Nullable Entity except, AABB box, Predicate<? super Entity> predicate) {
|
||||
@@ -17716,7 +17683,7 @@ index d8d4a1ca2eb062af8b2de4ab44503983587cdd77..bdb32964524cb2a4398b8d3bedfb03b0
|
||||
List<Entity> list = Lists.newArrayList();
|
||||
((ServerLevel)this).getEntityLookup().getEntities(except, box, list, predicate); // Paper - optimise this call
|
||||
return list;
|
||||
@@ -1226,7 +1272,7 @@ public abstract class Level implements LevelAccessor, AutoCloseable {
|
||||
@@ -1225,7 +1271,7 @@ public abstract class Level implements LevelAccessor, AutoCloseable {
|
||||
}
|
||||
|
||||
public <T extends Entity> void getEntities(EntityTypeTest<Entity, T> filter, AABB box, Predicate<? super T> predicate, List<? super T> result, int limit) {
|
||||
@@ -17725,7 +17692,7 @@ index d8d4a1ca2eb062af8b2de4ab44503983587cdd77..bdb32964524cb2a4398b8d3bedfb03b0
|
||||
// Paper start - optimise this call
|
||||
//TODO use limit
|
||||
if (filter instanceof net.minecraft.world.entity.EntityType entityTypeTest) {
|
||||
@@ -1483,7 +1529,7 @@ public abstract class Level implements LevelAccessor, AutoCloseable {
|
||||
@@ -1482,7 +1528,7 @@ public abstract class Level implements LevelAccessor, AutoCloseable {
|
||||
}
|
||||
|
||||
public ProfilerFiller getProfiler() {
|
||||
@@ -17734,7 +17701,7 @@ index d8d4a1ca2eb062af8b2de4ab44503983587cdd77..bdb32964524cb2a4398b8d3bedfb03b0
|
||||
return (ProfilerFiller) this.profiler.get();
|
||||
}
|
||||
|
||||
@@ -1574,4 +1620,14 @@ public abstract class Level implements LevelAccessor, AutoCloseable {
|
||||
@@ -1573,4 +1619,14 @@ public abstract class Level implements LevelAccessor, AutoCloseable {
|
||||
return null;
|
||||
}
|
||||
// Paper end
|
||||
@@ -20938,7 +20905,7 @@ index 5e83fabb20bc2b0668cbf48530053ca1bb9092f3..4ffb4046b63cbc140c76721f51c9a7a0
|
||||
+ // Purpur end
|
||||
}
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java
|
||||
index f0ce29d21fe9af803ce4e41b8c037b2ec5d1b124..99dd93c066d4acc177de7f03ae45e491b535f4d1 100644
|
||||
index b25f5931f836fd4d8695120f0bcb7c52deff8583..b473f89c59c0fc080fadd0d4db320895e917fd41 100644
|
||||
--- a/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 {
|
||||
@@ -20977,7 +20944,7 @@ index f0ce29d21fe9af803ce4e41b8c037b2ec5d1b124..99dd93c066d4acc177de7f03ae45e491
|
||||
}
|
||||
return effects;
|
||||
}
|
||||
@@ -907,7 +907,7 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity {
|
||||
@@ -912,7 +912,7 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity {
|
||||
return EntityCategory.WATER;
|
||||
}
|
||||
|
||||
@@ -20986,7 +20953,7 @@ index f0ce29d21fe9af803ce4e41b8c037b2ec5d1b124..99dd93c066d4acc177de7f03ae45e491
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -1094,4 +1094,32 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity {
|
||||
@@ -1099,4 +1099,32 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity {
|
||||
getHandle().knockback(strength, directionX, directionZ);
|
||||
};
|
||||
// Paper end
|
||||
|
||||
@@ -220,10 +220,10 @@ index be7b3fe2dc84493dcde9e185717b0b7c7c2e9822..cfdaa744ff40c8a171ca9b36b305b326
|
||||
servergui.runFinalizers();
|
||||
}
|
||||
diff --git a/src/main/java/net/minecraft/world/level/Level.java b/src/main/java/net/minecraft/world/level/Level.java
|
||||
index bdb32964524cb2a4398b8d3bedfb03b0cb805b6d..9fb140b3b6a0c621466b85a6ec7df765a4e823b0 100644
|
||||
index 80ab17142c34d576409e5fb353ff31db9673b2c0..32bd43692b701b49776c10d9c4332bb41322b9fa 100644
|
||||
--- a/src/main/java/net/minecraft/world/level/Level.java
|
||||
+++ b/src/main/java/net/minecraft/world/level/Level.java
|
||||
@@ -1035,7 +1035,7 @@ public abstract class Level implements LevelAccessor, AutoCloseable {
|
||||
@@ -1034,7 +1034,7 @@ public abstract class Level implements LevelAccessor, AutoCloseable {
|
||||
TickingBlockEntity tickingblockentity = (TickingBlockEntity) this.blockEntityTickers.get(tileTickPosition);
|
||||
// Spigot start
|
||||
if (tickingblockentity == null) {
|
||||
@@ -259,10 +259,10 @@ index b08d4a2a74392b1d59b1eeeab3108103d83ad96c..8833a66f43e9a4ac486fa67db9e81470
|
||||
private final String bukkitVersion = Versioning.getBukkitVersion();
|
||||
private final Logger logger = Logger.getLogger("Minecraft");
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java
|
||||
index 99dd93c066d4acc177de7f03ae45e491b535f4d1..9d7965a33db1ce4c294fb06e77d16054d580fd54 100644
|
||||
index b473f89c59c0fc080fadd0d4db320895e917fd41..cdf28d1b5da2f602b020142d5bfc37922e315718 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftLivingEntity.java
|
||||
@@ -907,7 +907,7 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity {
|
||||
@@ -912,7 +912,7 @@ public class CraftLivingEntity extends CraftEntity implements LivingEntity {
|
||||
return EntityCategory.WATER;
|
||||
}
|
||||
|
||||
|
||||
@@ -66,7 +66,7 @@ index d8b27e3f2fa1ede41125ec27e129b1e1ad42caa7..2c59ed16ea909b6535df3d1d40d83b06
|
||||
|
||||
// Pufferfish start
|
||||
- implementation("org.yaml:snakeyaml:1.32")
|
||||
+ implementation("org.yaml:snakeyaml:2.2")
|
||||
+ implementation("org.yaml:snakeyaml:1.33")
|
||||
implementation ("com.github.carleslc.Simple-YAML:Simple-Yaml:1.8.4") {
|
||||
exclude(group="org.yaml", module="snakeyaml")
|
||||
}
|
||||
|
||||
@@ -104,7 +104,7 @@ index a0aa1f1a7adf986d500a2135aa42e138aa3c4f08..28a1d21900dbff4b9d1887b9aa4e68f4
|
||||
+ // Plazma end
|
||||
}
|
||||
diff --git a/src/main/java/io/papermc/paper/configuration/PaperConfigurations.java b/src/main/java/io/papermc/paper/configuration/PaperConfigurations.java
|
||||
index e471960e0443392f6f54732b052a4debf2a8fd97..928cb4827768667a975036da73b25abdd74a489f 100644
|
||||
index 2d3068b7748032342edd81e6ea4a7c08988fb28d..300b76731e1226b670cc51dfacf8e1cce4f04f7c 100644
|
||||
--- a/src/main/java/io/papermc/paper/configuration/PaperConfigurations.java
|
||||
+++ b/src/main/java/io/papermc/paper/configuration/PaperConfigurations.java
|
||||
@@ -135,7 +135,7 @@ public class PaperConfigurations extends Configurations<GlobalConfiguration, Wor
|
||||
@@ -116,7 +116,7 @@ index e471960e0443392f6f54732b052a4debf2a8fd97..928cb4827768667a975036da73b25abd
|
||||
|
||||
|
||||
public PaperConfigurations(final Path globalFolder) {
|
||||
@@ -300,7 +300,7 @@ public class PaperConfigurations extends Configurations<GlobalConfiguration, Wor
|
||||
@@ -303,7 +303,7 @@ public class PaperConfigurations extends Configurations<GlobalConfiguration, Wor
|
||||
}
|
||||
}
|
||||
|
||||
@@ -125,7 +125,7 @@ index e471960e0443392f6f54732b052a4debf2a8fd97..928cb4827768667a975036da73b25abd
|
||||
return createWorldContextMap(level.convertable.levelDirectory.path(), level.serverLevelData.getLevelName(), level.dimension().location(), level.spigotConfig);
|
||||
}
|
||||
|
||||
@@ -399,18 +399,7 @@ public class PaperConfigurations extends Configurations<GlobalConfiguration, Wor
|
||||
@@ -402,18 +402,7 @@ public class PaperConfigurations extends Configurations<GlobalConfiguration, Wor
|
||||
|
||||
private static boolean needsConverting(final Path legacyConfig) {
|
||||
return Files.exists(legacyConfig) && Files.isRegularFile(legacyConfig);
|
||||
@@ -145,7 +145,7 @@ index e471960e0443392f6f54732b052a4debf2a8fd97..928cb4827768667a975036da73b25abd
|
||||
|
||||
@Deprecated
|
||||
public static YamlConfiguration loadLegacyConfigFile(File configFile) throws Exception {
|
||||
@@ -434,9 +423,15 @@ public class PaperConfigurations extends Configurations<GlobalConfiguration, Wor
|
||||
@@ -437,9 +426,15 @@ public class PaperConfigurations extends Configurations<GlobalConfiguration, Wor
|
||||
}
|
||||
|
||||
// Symlinks are not correctly checked in createDirectories
|
||||
@@ -263,7 +263,7 @@ index 221d1d0e1b4b46de6ebca5faac09bbda875fae17..e009dba395779e2c89a36fe4524e5d40
|
||||
this.convertable = convertable_conversionsession;
|
||||
this.uuid = WorldUUID.getUUID(convertable_conversionsession.levelDirectory.path().toFile());
|
||||
diff --git a/src/main/java/net/minecraft/world/level/Level.java b/src/main/java/net/minecraft/world/level/Level.java
|
||||
index 9fb140b3b6a0c621466b85a6ec7df765a4e823b0..08f9af1d7aebba943096b59b6452818a1aafc94c 100644
|
||||
index 32bd43692b701b49776c10d9c4332bb41322b9fa..a6e7d98d1f4848b11a3776d8e7a42a56a1543865 100644
|
||||
--- a/src/main/java/net/minecraft/world/level/Level.java
|
||||
+++ b/src/main/java/net/minecraft/world/level/Level.java
|
||||
@@ -174,7 +174,12 @@ public abstract class Level implements LevelAccessor, AutoCloseable {
|
||||
@@ -642,7 +642,7 @@ index 0000000000000000000000000000000000000000..857ddc62dd9affbbebcd7cde8a6d675d
|
||||
+}
|
||||
diff --git a/src/main/java/org/plazmamc/plazma/configurations/PlazmaConfigurations.java b/src/main/java/org/plazmamc/plazma/configurations/PlazmaConfigurations.java
|
||||
new file mode 100644
|
||||
index 0000000000000000000000000000000000000000..b1104778995a3734f3b6df71d59172e546e152a2
|
||||
index 0000000000000000000000000000000000000000..481392f3ed3b746172dbf319a583ca5751bc0b35
|
||||
--- /dev/null
|
||||
+++ b/src/main/java/org/plazmamc/plazma/configurations/PlazmaConfigurations.java
|
||||
@@ -0,0 +1,304 @@
|
||||
@@ -699,7 +699,7 @@ index 0000000000000000000000000000000000000000..b1104778995a3734f3b6df71d59172e5
|
||||
+
|
||||
+ private static final Logger LOGGER = LogUtils.getLogger();
|
||||
+ static final String GLOBAL_CONFIGURATION_FILE_NAME= "plazma-global.yml";
|
||||
+ static final String LEVEL_DEFAULT_CONFIGURATION_FILE_NAME = "plazma-level-dafaults.yml";
|
||||
+ static final String LEVEL_DEFAULT_CONFIGURATION_FILE_NAME = "plazma-level-defaults.yml";
|
||||
+ static final String LEVEL_CONFIGURATION_FILE_NAME = "plazma-configuration.yml";
|
||||
+
|
||||
+ private static final String HEADER_START = """
|
||||
|
||||
@@ -7,7 +7,7 @@ Original: YouHaveTrouble/minecraft-optimization, AkiraDevelopment/SimplyMC
|
||||
Copyright (C) 2023 YouHaveTrouble, AkiraDevelopment
|
||||
|
||||
diff --git a/src/main/java/gg/pufferfish/pufferfish/PufferfishConfig.java b/src/main/java/gg/pufferfish/pufferfish/PufferfishConfig.java
|
||||
index bff1b41501c040487583a5a279fc7800fc6aedca..2d7e1ffa117fa2581ab2a42cd04d062f25559b11 100644
|
||||
index 3e36958365bc136516bafbaad0c168f7956406f1..b5eca4a809d5e7c77de9737941f3f6c35e4fc796 100644
|
||||
--- a/src/main/java/gg/pufferfish/pufferfish/PufferfishConfig.java
|
||||
+++ b/src/main/java/gg/pufferfish/pufferfish/PufferfishConfig.java
|
||||
@@ -211,8 +211,8 @@ public class PufferfishConfig {
|
||||
@@ -43,10 +43,10 @@ index bff1b41501c040487583a5a279fc7800fc6aedca..2d7e1ffa117fa2581ab2a42cd04d062f
|
||||
"If you want further away entities to tick less often, use 7.",
|
||||
"If you want further away entities to tick more often, try 9.");
|
||||
diff --git a/src/main/java/io/papermc/paper/configuration/GlobalConfiguration.java b/src/main/java/io/papermc/paper/configuration/GlobalConfiguration.java
|
||||
index 019d3bbd78fb0b06861979d223915fedb6c99442..553127c9a38612005530cffdb25544585e6c8234 100644
|
||||
index 3bc7230ca62ebe3426da293e436a962bb0134f85..1a4b5dc4c5340de66553936bbbc074d1654a3ef8 100644
|
||||
--- a/src/main/java/io/papermc/paper/configuration/GlobalConfiguration.java
|
||||
+++ b/src/main/java/io/papermc/paper/configuration/GlobalConfiguration.java
|
||||
@@ -142,7 +142,7 @@ public class GlobalConfiguration extends ConfigurationPart {
|
||||
@@ -143,7 +143,7 @@ public class GlobalConfiguration extends ConfigurationPart {
|
||||
|
||||
public class Watchdog extends ConfigurationPart {
|
||||
public int earlyWarningEvery = 5000;
|
||||
@@ -197,7 +197,7 @@ index 24763d3d270c29c95e0b3e85111145234f660a62..18bc271a34ffba8c83743fef7eaf4a2c
|
||||
}
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/Main.java b/src/main/java/net/minecraft/server/Main.java
|
||||
index 903da36aeec8e8c7d1f3101d1e93f87412a7eed5..79593800173ad2b837b081e6091e98adfa41fb99 100644
|
||||
index a8bf67cf0c579c407befe17d735440f1128d98c4..62a886dd6c9b3d22eb9d96b275a2f4e133f6d306 100644
|
||||
--- a/src/main/java/net/minecraft/server/Main.java
|
||||
+++ b/src/main/java/net/minecraft/server/Main.java
|
||||
@@ -155,7 +155,7 @@ public class Main {
|
||||
|
||||
BIN
res/logo-450.png
BIN
res/logo-450.png
Binary file not shown.
|
Before Width: | Height: | Size: 79 KiB |
BIN
res/logo-64.png
BIN
res/logo-64.png
Binary file not shown.
|
Before Width: | Height: | Size: 7.8 KiB |
BIN
res/logo-900.png
BIN
res/logo-900.png
Binary file not shown.
|
Before Width: | Height: | Size: 176 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 93 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 231 KiB |
Reference in New Issue
Block a user