Fix inputs overrides not resetting when out of world, fixes #43
This commit is contained in:
parent
8ee65f1212
commit
a9cac7718e
@ -56,8 +56,7 @@ public class PathingBehavior extends Behavior {
|
||||
@Override
|
||||
public void onTick(TickEvent event) {
|
||||
if (event.getType() == TickEvent.Type.OUT) {
|
||||
current = null;
|
||||
next = null;
|
||||
this.cancel();
|
||||
return;
|
||||
}
|
||||
if (current == null) {
|
||||
@ -148,7 +147,9 @@ public class PathingBehavior extends Behavior {
|
||||
return current;
|
||||
}
|
||||
|
||||
public PathExecutor getNext() {return next;}
|
||||
public PathExecutor getNext() {
|
||||
return next;
|
||||
}
|
||||
|
||||
public Optional<IPath> getPath() {
|
||||
return Optional.ofNullable(current).map(PathExecutor::getPath);
|
||||
|
Loading…
Reference in New Issue
Block a user