aboutsummaryrefslogtreecommitdiffhomepage
path: root/patch-remap/mache-vineflower-stripped/net/minecraft/world/entity/monster/Guardian.java.patch
diff options
context:
space:
mode:
Diffstat (limited to 'patch-remap/mache-vineflower-stripped/net/minecraft/world/entity/monster/Guardian.java.patch')
-rw-r--r--patch-remap/mache-vineflower-stripped/net/minecraft/world/entity/monster/Guardian.java.patch28
1 files changed, 28 insertions, 0 deletions
diff --git a/patch-remap/mache-vineflower-stripped/net/minecraft/world/entity/monster/Guardian.java.patch b/patch-remap/mache-vineflower-stripped/net/minecraft/world/entity/monster/Guardian.java.patch
new file mode 100644
index 0000000000..49115ccb40
--- /dev/null
+++ b/patch-remap/mache-vineflower-stripped/net/minecraft/world/entity/monster/Guardian.java.patch
@@ -0,0 +1,28 @@
+--- a/net/minecraft/world/entity/monster/Guardian.java
++++ b/net/minecraft/world/entity/monster/Guardian.java
+@@ -61,7 +62,8 @@
+ private int clientSideAttackTime;
+ private boolean clientSideTouchedGround;
+ @Nullable
+- protected RandomStrollGoal randomStrollGoal;
++ public RandomStrollGoal randomStrollGoal;
++ public Guardian.GuardianAttackGoal guardianAttackGoal; // CraftBukkit - add field
+
+ public Guardian(EntityType<? extends Guardian> entityType, Level level) {
+ super(entityType, level);
+@@ -74,10 +76,11 @@
+
+ @Override
+ protected void registerGoals() {
+- MoveTowardsRestrictionGoal moveTowardsRestrictionGoal = new MoveTowardsRestrictionGoal(this, 1.0);
+- this.randomStrollGoal = new RandomStrollGoal(this, 1.0, 80);
+- this.goalSelector.addGoal(4, new Guardian.GuardianAttackGoal(this));
+- this.goalSelector.addGoal(5, moveTowardsRestrictionGoal);
++ MoveTowardsRestrictionGoal pathfindergoalmovetowardsrestriction = new MoveTowardsRestrictionGoal(this, 1.0D);
++
++ this.randomStrollGoal = new RandomStrollGoal(this, 1.0D, 80);
++ this.goalSelector.addGoal(4, guardianAttackGoal = new Guardian.GuardianAttackGoal(this)); // CraftBukkit - assign field
++ this.goalSelector.addGoal(5, pathfindergoalmovetowardsrestriction);
+ this.goalSelector.addGoal(7, this.randomStrollGoal);
+ this.goalSelector.addGoal(8, new LookAtPlayerGoal(this, Player.class, 8.0F));
+ this.goalSelector.addGoal(8, new LookAtPlayerGoal(this, Guardian.class, 12.0F, 0.01F));