Create basepatch in proper directory if required.

This commit is contained in:
caitsith2
2020-06-20 19:14:09 -07:00
parent 95742ddb98
commit e1bfa8780c
2 changed files with 3 additions and 4 deletions

3
Rom.py
View File

@@ -105,8 +105,7 @@ class LocalRom(object):
if self.verify(self.buffer):
with open(local_path('basepatch.sfc'), 'wb') as stream:
stream.write(self.buffer)
create_patch_file(local_path('basepatch.sfc'))
os.rename(local_path('basepatch.bmbp'), os.path.join('data', 'basepatch.bmbp'))
create_patch_file(local_path('basepatch.sfc'), destination=local_path(os.path.join('data', 'basepatch.bmbp')))
os.remove(local_path('data/base2current.json'))
else:
raise RuntimeError(