testserver/Spigot-Server-Patches/0366-Mark-entities-as-being...

27 lines
1.2 KiB
Diff
Raw Normal View History

From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Shane Freeder <theboyetronic@gmail.com>
Date: Sun, 28 Jul 2019 00:51:11 +0100
Subject: [PATCH] Mark entities as being ticked when notifying navigation
diff --git a/src/main/java/net/minecraft/server/level/WorldServer.java b/src/main/java/net/minecraft/server/level/WorldServer.java
2021-03-16 13:04:28 +00:00
index 280ecd3634d77b93cf0923f4c4a5cfd7f114e848..7282ac286e4f1333c25a8515275b27b9efb19343 100644
--- a/src/main/java/net/minecraft/server/level/WorldServer.java
+++ b/src/main/java/net/minecraft/server/level/WorldServer.java
2021-03-16 13:04:28 +00:00
@@ -1474,6 +1474,7 @@ public class WorldServer extends World implements GeneratorAccessSeed {
VoxelShape voxelshape1 = iblockdata1.getCollisionShape(this, blockposition);
if (VoxelShapes.c(voxelshape, voxelshape1, OperatorBoolean.NOT_SAME)) {
+ boolean wasTicking = this.tickingEntities; this.tickingEntities = true; // Paper
Iterator iterator = this.navigators.iterator();
while (iterator.hasNext()) {
2021-03-16 13:04:28 +00:00
@@ -1495,6 +1496,7 @@ public class WorldServer extends World implements GeneratorAccessSeed {
}
}
+ this.tickingEntities = wasTicking; // Paper
}
}