mirror of https://github.com/cabaletta/baritone
discard next segment properly
This commit is contained in:
parent
9ecd24c755
commit
b2583773d5
|
@ -463,8 +463,12 @@ public final class PathingBehavior extends Behavior implements IPathingBehavior,
|
||||||
} else {
|
} else {
|
||||||
if (next == null) {
|
if (next == null) {
|
||||||
if (executor.isPresent()) {
|
if (executor.isPresent()) {
|
||||||
queuePathEvent(PathEvent.NEXT_SEGMENT_CALC_FINISHED);
|
if (executor.get().getPath().getSrc().equals(current.getPath().getDest())) {
|
||||||
next = executor.get();
|
queuePathEvent(PathEvent.NEXT_SEGMENT_CALC_FINISHED);
|
||||||
|
next = executor.get();
|
||||||
|
} else {
|
||||||
|
logDebug("Warning: discarding orphan next segment with incorrect start");
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
queuePathEvent(PathEvent.NEXT_CALC_FAILED);
|
queuePathEvent(PathEvent.NEXT_CALC_FAILED);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue