Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

#ignore, wrong repo #46

Closed
Kaitto opened this issue Mar 25, 2017 · 0 comments
Closed

#ignore, wrong repo #46

Kaitto opened this issue Mar 25, 2017 · 0 comments

Comments

@Kaitto
Copy link

Kaitto commented Mar 25, 2017

Im working in a server with Spigot 1.10.2 with this build (http://ci.citizensnpcs.co/job/Builder/20/, not using the lastest build #21 as it is for version 1.11) and citizens-2.0.20 (SNAPSHOT)

NPC walks to the build but after placing the first block it starts to build everything so fast and teleports around the construction (Just as this comment describes it https://dev.bukkit.org/projects/builder-citizens2?comment=610)
I was looking for some patch that gave me the best solution to this problem, but I do not think it is solved, or it is a specific problem to this version of citizens or builders .. or its combination, I do not know.

Anyway, I got tired and I decided to try my luck with maven (first time) and look for that bug. I do not want to do a pull or anything like that (Especially if I'm using versions that are old, but if this problem persists in others, which I do not know, it must be compatible), but whoever interests me here is my change:

on BuilderTrait.java, inside SetupNextBlock(), after npc.getNavigator().getLocalParameters().stuckAction(BuilderTeleportStuckAction.INSTANCE);

add:
npc.getNavigator().setPaused(false);
npc.getNavigator().getPathStrategy().update();

It seems that after setting the target, the path must be updated.
Well that's all, I hope it helps

(ups, this was for Morphan1 folk)

@Kaitto Kaitto closed this as completed Mar 25, 2017
@Kaitto Kaitto changed the title NPC builds too fast and teleports randomly (Navigator not updating) #ignore, wrong repo Mar 25, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant