summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--crystal.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/crystal.py b/crystal.py
index 92d3375..ab58a19 100644
--- a/crystal.py
+++ b/crystal.py
@@ -1724,7 +1724,11 @@ class TrainerGroupParam(SingleByteParam):
class MoveParam(SingleByteParam):
def to_asm(self):
- return moves[self.byte]
+ if self.byte in moves.keys():
+ return moves[self.byte]
+ else:
+ # this happens for move=0 (no move) in trainer headers
+ return str(self.byte)
class MenuDataPointerParam(PointerLabelParam):
#read menu data at the target site