Fix instant crash on mainmenu

This commit is contained in:
Howard Stark 2018-08-05 22:15:25 -04:00
parent 3eef5e2972
commit f320c6710a
No known key found for this signature in database
GPG Key ID: 9FA4E350B33067F3
4 changed files with 14 additions and 2 deletions

View File

@ -42,8 +42,7 @@ public class PathingBehavior extends Behavior {
@Override
public void onTick(TickEvent event) {
// System.out.println("Ticking");
if (current == null) {
if(event.getType() == TickEvent.Type.OUT || current == null) {
return;
}
current.onTick(event);

View File

@ -13,6 +13,14 @@ public final class TickEvent {
this.type = type;
}
public Type getType() {
return type;
}
public EventState getState() {
return state;
}
public enum Type {
/**

View File

@ -0,0 +1,4 @@
package baritone.bot.pathing.movement.movements;
public class MovementFall {
}

View File

@ -35,6 +35,7 @@ public class PathExecutor extends Behavior {
@Override
public void onTick(TickEvent event) {
if(event.)
if (pathPosition >= path.length()) {
//stop bugging me, I'm done
//TODO Baritone.INSTANCE.behaviors.remove(this)