3
0
Mirror von https://github.com/PaperMC/Paper.git synchronisiert 2024-12-23 14:50:08 +01:00
Paper/nms-patches/BehaviorWork.patch

27 Zeilen
1.5 KiB
Diff

--- a/net/minecraft/server/BehaviorWork.java
+++ b/net/minecraft/server/BehaviorWork.java
@@ -27,19 +27,19 @@
protected void a(WorldServer worldserver, EntityVillager entityvillager, long i) {
BehaviorController<EntityVillager> behaviorcontroller = entityvillager.getBehaviorController();
- behaviorcontroller.setMemory(MemoryModuleType.LAST_WORKED_AT_POI, (Object) i);
+ behaviorcontroller.setMemory(MemoryModuleType.LAST_WORKED_AT_POI, i); // CraftBukkit - decompile error
behaviorcontroller.getMemory(MemoryModuleType.JOB_SITE).ifPresent((globalpos) -> {
- behaviorcontroller.setMemory(MemoryModuleType.LOOK_TARGET, (Object) (new BehaviorTarget(globalpos.getBlockPosition())));
+ behaviorcontroller.setMemory(MemoryModuleType.LOOK_TARGET, (new BehaviorTarget(globalpos.getBlockPosition()))); // CraftBukkit - decompile error
});
entityvillager.fd();
- this.a(worldserver, entityvillager);
+ this.doWork(worldserver, entityvillager); // PAIL
if (entityvillager.fc()) {
entityvillager.fb();
}
}
- protected void a(WorldServer worldserver, EntityVillager entityvillager) {}
+ protected void doWork(WorldServer worldserver, EntityVillager entityvillager) {} // PAIL
protected boolean b(WorldServer worldserver, EntityVillager entityvillager, long i) {
Optional<GlobalPos> optional = entityvillager.getBehaviorController().getMemory(MemoryModuleType.JOB_SITE);