Skip to content

Commit 179c3ab

Browse files
committed
Adds raise exception for unknown Hotkey actions
1 parent ce2dcd9 commit 179c3ab

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

sc2reader/parsers.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -209,7 +209,9 @@ def parse_hotkey_event(self, buffer, frames, type, code, pid):
209209
return AddToHotkeyEvent(frames, pid, type, code, hotkey, overlay)
210210
elif action == 2:
211211
return GetHotkeyEvent(frames, pid, type, code, hotkey, overlay)
212-
212+
else:
213+
raise TypeError("Hotkey Action '{0}' unknown")
214+
213215
class ActionParser_18574(ActionParser_16561):
214216
def parse_ability_event(self, buffer, frames, type, code, pid):
215217
flag = buffer.read_byte()

0 commit comments

Comments
 (0)