mirror of
https://github.com/MarioSpore/Grinch-AP.git
synced 2025-10-21 20:21:32 -06:00
Fix incorrect player number targetting if player name contains P
This commit is contained in:
@@ -89,7 +89,7 @@ def upload_to_db(folder):
|
|||||||
for file in os.listdir(folder):
|
for file in os.listdir(folder):
|
||||||
file = os.path.join(folder, file)
|
file = os.path.join(folder, file)
|
||||||
if file.endswith(".bmbp"):
|
if file.endswith(".bmbp"):
|
||||||
player = int(file.split("P")[-1].split(".")[0].split("_")[0])
|
player = int(file.split("P")[1].split(".")[0].split("_")[0])
|
||||||
patches.add(Patch(data=open(file, "rb").read(), player=player))
|
patches.add(Patch(data=open(file, "rb").read(), player=player))
|
||||||
elif file.endswith(".txt"):
|
elif file.endswith(".txt"):
|
||||||
spoiler = open(file, "rt").read()
|
spoiler = open(file, "rt").read()
|
||||||
|
Reference in New Issue
Block a user