mirror of
https://github.com/Samsuik/Sakura.git
synced 2025-12-22 16:29:16 +00:00
Upstream has released updates that appear to apply and compile correctly Paper Changes: PaperMC/Paper@3ea95ef Do not access world state to see if we can see a Player PaperMC/Paper@71c84c8 Updated Upstream (Bukkit/CraftBukkit/Spigot) (#10277) PaperMC/Paper@e3bc4c4 Make debug mode print current configuration phase PaperMC/Paper@d0ebfbb Fix corrupted plugin.yml breaking plugin loading (#10279) PaperMC/Paper@681bbff Fix spawnreason saving
29 lines
1.1 KiB
Diff
29 lines
1.1 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: Hermelijn15 <j.s.dekker-1@student.utwente.nl>
|
|
Date: Fri, 17 Nov 2023 20:09:03 +0100
|
|
Subject: [PATCH] Added list of ItemEntity's that ignore explosions
|
|
|
|
|
|
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 c7f06c3cfb737bd17a706798bf9cf0e1af5f0cc0..e5e4e9f67390b407abc1bd01242cddbe118b3e45 100644
|
|
--- a/src/main/java/net/minecraft/world/entity/item/ItemEntity.java
|
|
+++ b/src/main/java/net/minecraft/world/entity/item/ItemEntity.java
|
|
@@ -579,6 +579,17 @@ public class ItemEntity extends Entity implements TraceableEntity {
|
|
|
|
}
|
|
|
|
+ // Sakura start
|
|
+ @Override
|
|
+ public boolean ignoreExplosion(net.minecraft.world.level.Explosion explosion) {
|
|
+ if (this.level().sakuraConfig().entity.items.explosionResistantItems.contains(this.getItem().getItem())) {
|
|
+ return true;
|
|
+ } else {
|
|
+ return super.ignoreExplosion(explosion);
|
|
+ }
|
|
+ }
|
|
+ // Sakura end
|
|
+
|
|
public void setTarget(@Nullable UUID owner) {
|
|
this.target = owner;
|
|
}
|