Fix dimno parsing only working for negative dimnos

This commit is contained in:
David Vierra 2016-08-25 07:28:16 -10:00
parent 462474972f
commit 446c4de243

View File

@ -684,7 +684,7 @@ class WorldEditor(object):
if dimName == "": if dimName == "":
return 0 return 0
matches = re.findall(r'-[0-9]+', dimName) matches = re.findall(r'-?[0-9]+', dimName)
if not len(matches): if not len(matches):
raise ValueError("Could not parse a dimension number from %s", dimName) raise ValueError("Could not parse a dimension number from %s", dimName)
return int(matches[-1]) return int(matches[-1])