From ee7b3749f3dc9a5be256e8362104ba491c2b1104 Mon Sep 17 00:00:00 2001 From: IBBoard Date: Sun, 19 Dec 2021 15:08:58 +0000 Subject: [PATCH] Re #18: Fail at pitch invasion This prevents us continuing and getting obscure issues that are caused by inconsistent state --- bbreplay/replay.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/bbreplay/replay.py b/bbreplay/replay.py index e82f83f..e5dbb46 100644 --- a/bbreplay/replay.py +++ b/bbreplay/replay.py @@ -248,8 +248,7 @@ def _process_kickoff(self, cmds, log_entries, board): board.blitz() yield from self._process_turn(cmds, log_entries, board, False) elif kickoff_result == KickoffEvent.PITCH_INVASION: - # XXX: Players may get stunned, but we've not currently got any examples so we need to check what happens - pass + raise NotImplementedError("Cannot process 'Pitch Invasion' event because injured players aren't identified") else: raise NotImplementedError(f"{kickoff_result} not yet implemented")