mirror of
https://github.com/PurpurMC/Purpur.git
synced 2026-02-19 09:27:43 +01:00
Upstream has released updates that appears to apply and compile correctly Paper Changes: df0d7b0d Update upstream CB 6ea3c2cf [CI-SKIP] Rebuild patches d7bed4cb Heavily optimise random block ticking (#2914) b66d9ff8 Update upstream CB ba71c5d6 Stop stripping private use block Unicode from signs 28d9dcfc Entity Jump API (#1587) 9976a768 Fix PlayerNaturallySpawnCreaturesEvent boolean inversion 054e20da Clean up imports on ThrownEggHatchEvent a8984ccb Add ThrownEggHatchEvent (#1982) 9f24d495 Allow nerfed blazes, endermen to take water damage (#2847)
44 lines
2.3 KiB
Diff
44 lines
2.3 KiB
Diff
From dc6745d6610beb00f366080393e08a022c278487 Mon Sep 17 00:00:00 2001
|
|
From: William Blake Galbreath <blake.galbreath@gmail.com>
|
|
Date: Sat, 17 Aug 2019 15:27:09 -0500
|
|
Subject: [PATCH] Add option for zombies targetting turtle eggs
|
|
|
|
---
|
|
src/main/java/net/minecraft/server/EntityZombie.java | 2 +-
|
|
src/main/java/net/pl3x/purpur/PurpurWorldConfig.java | 2 ++
|
|
2 files changed, 3 insertions(+), 1 deletion(-)
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/EntityZombie.java b/src/main/java/net/minecraft/server/EntityZombie.java
|
|
index e9e2be88e..1e60cc399 100644
|
|
--- a/src/main/java/net/minecraft/server/EntityZombie.java
|
|
+++ b/src/main/java/net/minecraft/server/EntityZombie.java
|
|
@@ -64,7 +64,7 @@ public class EntityZombie extends EntityMonster {
|
|
@Override
|
|
protected void initPathfinder() {
|
|
this.goalSelector.a(0, new net.pl3x.purpur.pathfinder.PathfinderGoalHasRider(this)); // Purpur
|
|
- this.goalSelector.a(4, new EntityZombie.a(this, 1.0D, 3));
|
|
+ if (world.purpurConfig.zombieTargetTurtleEggs) this.goalSelector.a(4, new EntityZombie.a(this, 1.0D, 3)); // Purpur
|
|
this.goalSelector.a(8, new PathfinderGoalLookAtPlayer(this, EntityHuman.class, 8.0F));
|
|
this.goalSelector.a(8, new PathfinderGoalRandomLookaround(this));
|
|
this.targetSelector.a(0, new net.pl3x.purpur.pathfinder.PathfinderGoalHasRider(this)); // Purpur
|
|
diff --git a/src/main/java/net/pl3x/purpur/PurpurWorldConfig.java b/src/main/java/net/pl3x/purpur/PurpurWorldConfig.java
|
|
index 39c56149a..1ab98d49e 100644
|
|
--- a/src/main/java/net/pl3x/purpur/PurpurWorldConfig.java
|
|
+++ b/src/main/java/net/pl3x/purpur/PurpurWorldConfig.java
|
|
@@ -808,10 +808,12 @@ public class PurpurWorldConfig {
|
|
public boolean zombieRidable = false;
|
|
public boolean zombieRidableInWater = false;
|
|
public boolean zombieRequireShiftToMount = true;
|
|
+ public boolean zombieTargetTurtleEggs = true;
|
|
private void zombieSettings() {
|
|
zombieRidable = getBoolean("mobs.zombie.ridable", zombieRidable);
|
|
zombieRidableInWater = getBoolean("mobs.zombie.ridable-in-water", zombieRidableInWater);
|
|
zombieRequireShiftToMount = getBoolean("mobs.zombie.require-shift-to-mount", zombieRequireShiftToMount);
|
|
+ zombieTargetTurtleEggs = getBoolean("mobs.zombie.target-turtle-eggs", zombieTargetTurtleEggs);
|
|
}
|
|
|
|
public boolean zombieHorseCanSwim = false;
|
|
--
|
|
2.24.0
|
|
|