Skip to content

Commit 4873e3f

Browse files
HaHaWTHlynxplay
andauthored
Fix Bee anger never gets timeout (#13546)
Co-authored-by: Bjarne Koll <[email protected]>
1 parent 81b9122 commit 4873e3f

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed

paper-server/patches/sources/net/minecraft/world/entity/NeutralMob.java.patch

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,25 @@
1313
}
1414
}
1515

16+
@@ -61,11 +_,16 @@
17+
this.stopBeingAngry();
18+
} else {
19+
if (target != null) {
20+
- if (persistentAngerTarget == null || !persistentAngerTarget.matches(target)) {
21+
+ // Paper start - Backport fix for MC-305388 from 26.1-snapshot-5
22+
+ boolean newTarget = persistentAngerTarget == null || !persistentAngerTarget.matches(target);
23+
+ if (newTarget) {
24+
this.setPersistentAngerTarget(EntityReference.of(target));
25+
}
26+
27+
- this.startPersistentAngerTimer();
28+
+ if (newTarget || updateAnger) {
29+
+ this.startPersistentAngerTimer();
30+
+ }
31+
+ // Paper end - Backport fix for MC-305388 from 26.1-snapshot-5
32+
}
33+
34+
if (persistentAngerTarget != null && !this.isAngry() && (target == null || !isValidPlayerTarget(target) || !updateAnger)) {
1635
@@ -120,7 +_,7 @@
1736
default void stopBeingAngry() {
1837
this.setLastHurtByMob(null);

0 commit comments

Comments
 (0)