mirror of
https://github.com/PurpurMC/Purpur.git
synced 2026-02-19 01:17:42 +01:00
[ci-skip] there's some import tomfoolery happening in these patches...
This commit is contained in:
@@ -5,24 +5,16 @@ Subject: [PATCH] Add turtle egg block options
|
||||
|
||||
|
||||
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 70d46aafa9c16921e5c5bed3d97b8f402e25038a..1cc3e156eb612a7dc0a771d38252525c1884eaea 100644
|
||||
index 70d46aafa9c16921e5c5bed3d97b8f402e25038a..9925cfc1445d24bf673e273f81391a1dadfb677d 100644
|
||||
--- a/src/main/java/net/minecraft/world/level/block/TurtleEggBlock.java
|
||||
+++ b/src/main/java/net/minecraft/world/level/block/TurtleEggBlock.java
|
||||
@@ -10,7 +10,6 @@ import net.minecraft.util.RandomSource;
|
||||
import net.minecraft.world.entity.Entity;
|
||||
import net.minecraft.world.entity.EntityType;
|
||||
import net.minecraft.world.entity.LivingEntity;
|
||||
-import net.minecraft.world.entity.ambient.Bat;
|
||||
import net.minecraft.world.entity.animal.Turtle;
|
||||
import net.minecraft.world.entity.monster.Zombie;
|
||||
import net.minecraft.world.entity.player.Player;
|
||||
@@ -193,6 +192,25 @@ public class TurtleEggBlock extends Block {
|
||||
@@ -193,6 +193,25 @@ public class TurtleEggBlock extends Block {
|
||||
}
|
||||
|
||||
private boolean canDestroyEgg(Level world, Entity entity) {
|
||||
- return !(entity instanceof Turtle) && !(entity instanceof Bat) ? (!(entity instanceof LivingEntity) ? false : entity instanceof Player || world.getGameRules().getBoolean(GameRules.RULE_MOBGRIEFING)) : false;
|
||||
+ // Purpur start
|
||||
+ if (entity instanceof Turtle || entity instanceof net.minecraft.world.entity.ambient.Bat) {
|
||||
+ if (entity instanceof Turtle || entity instanceof Bat) {
|
||||
+ return false;
|
||||
+ }
|
||||
+ if (!world.purpurConfig.turtleEggsBreakFromExpOrbs && entity instanceof net.minecraft.world.entity.ExperienceOrb) {
|
||||
|
||||
Reference in New Issue
Block a user