From 863a44ff1a52b02425b95cf9836ba525e4024d3d Mon Sep 17 00:00:00 2001 From: Zunawe Date: Thu, 22 Aug 2024 17:26:00 -0700 Subject: [PATCH] Pokemon Emerald: Add +, do less hacks --- worlds/pokemon_emerald/data.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/worlds/pokemon_emerald/data.py b/worlds/pokemon_emerald/data.py index e49bd44206e8..c07a2966c3bf 100644 --- a/worlds/pokemon_emerald/data.py +++ b/worlds/pokemon_emerald/data.py @@ -383,7 +383,7 @@ def _init() -> None: label = [] for word in map_name[4:].split("_"): # 1F, B1F, 2R, etc. - re_match = re.match("^B?\d[FRP]$", word) + re_match = re.match("^B?\d+[FRP]$", word) if re_match: label.append(word) continue @@ -392,7 +392,7 @@ def _init() -> None: re_match = re.match("^([A-Z]+)(\d+)$", word) if re_match: label.append(re_match.group(1).capitalize()) - label.append(str(int(re_match.group(2)))) + label.append(re_match.group(2).lstrip("0")) continue if word == "OF":