Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,12 @@ public Match match(List<TimingInput> inputList) {
Match result = null;
for (int i = 0; i < inputList.size() - 1; i++) {
if (inputList.get(i).isStopTick() && !inputList.get(i + 1).isStopTick()) {
Match match = startsWithMatch(inputList.subList(i + 1, inputList.size()));
List<TimingInput> inputSubList = inputList.subList(i + 1, inputList.size());
Match match = startsWithMatch(inputSubList);

if (match == null && isSymmetrical())
match = getMirrored().startsWithMatch(inputSubList);

if (match != null)
result = match;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ private static int findFirstButtonDiff(boolean[] curInputs, boolean[] aftInputs)
}

public boolean isStopTick() {
return inputVector.isStop() && !P && !N && G == GroundState.GROUNDED;
return inputVector.isStop() && G == GroundState.GROUNDED;
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,13 +49,8 @@ public static String match(List<TimingInput> inputList) {
List<Timing.Match> matches = new ArrayList<>();
for (Map.Entry<String, Timing> entry : patterns.entrySet()) {
Timing.Match match = entry.getValue().match(inputList);

if (match == null && entry.getValue().isSymmetrical()) {
match = entry.getValue().getMirrored().match(inputList);
}
if (match != null) {
if (match != null)
matches.add(match);
}
}

if (matches.isEmpty())
Expand Down
Loading