diff --git a/game.py b/game.py index 8c549d3..6eca5d8 100644 --- a/game.py +++ b/game.py @@ -56,7 +56,7 @@ def load(logDir): except json.JSONDecodeError: log(f"Skipping line: {line}", "load") res.reverse() # so that it will stop when at the latest event it recognizes - return res + return res, len(res) def getCMDR(logs): diff --git a/main.py b/main.py index 634b94c..e422741 100644 --- a/main.py +++ b/main.py @@ -93,7 +93,7 @@ def mainGameLoop(): j = 0 while j < len(logs): logLineNow = logs[j] - now = eventHandler(logLineNow["event"], j) + now, logLineCount = eventHandler(logLineNow["event"], j) log("Event: " + str(now) + " No: " + str(j), "mainGameLoop") j += 1 if now != 1: