mirror of
https://github.com/PaperMC/Paper.git
synced 2025-02-05 07:01:45 +01:00
Limit pet look distance
This commit is contained in:
parent
df65fbea3e
commit
21770104ec
@ -0,0 +1,11 @@
|
|||||||
|
--- a/net/minecraft/world/entity/ai/goal/FollowOwnerGoal.java
|
||||||
|
+++ b/net/minecraft/world/entity/ai/goal/FollowOwnerGoal.java
|
||||||
|
@@ -72,7 +72,7 @@
|
||||||
|
public void tick() {
|
||||||
|
boolean bl = this.tamable.shouldTryTeleportToOwner();
|
||||||
|
if (!bl) {
|
||||||
|
- this.tamable.getLookControl().setLookAt(this.owner, 10.0F, (float)this.tamable.getMaxHeadXRot());
|
||||||
|
+ if (this.tamable.distanceToSqr(this.owner) <= 16 * 16) this.tamable.getLookControl().setLookAt(this.owner, 10.0F, (float)this.tamable.getMaxHeadXRot()); // Paper - Limit pet look distance
|
||||||
|
}
|
||||||
|
|
||||||
|
if (--this.timeToRecalcPath <= 0) {
|
Loading…
Reference in New Issue
Block a user