public static int runToNextInputFrameLimit(int move, int limit) {
    if ((move & 0b00001111) == 0) {
      return runToNextInputFrameHiLimit(limit) ? 1 : 0;
    } else if ((move & 0b11110000) == 0) {
      return runToNextInputFrameLoLimit(limit) ? 1 : 0;
    } else {
      return runToNextInputFrameHiLoLimit(limit);
    }
  }