xNul / palworld-host-save-fix

Fixes the bug which forces a player to create a new character when they already have a save. Useful for migrating maps from co-op to dedicated servers and from one dedicated server to another.
MIT License
887 stars 68 forks source link

IndexError: string index out of range #117

Closed catttuhh closed 5 months ago

catttuhh commented 5 months ago

image PS C:\Users\Kendy\Desktop\UESaveEditor> python fix-host-save.py C:\Users\Kendy\Desktop\UESaveEditor\uesave.exe C:\Users\Kendy\Desktop\UESaveEditor\A1AC29344F19AF21A8AE94807DAFEB53 CC1CB4ED00000000000000000000000 00000000000000000000000000000001

WARNING: Running this script WILL change your save files and could potentially corrupt your data. It is HIGHLY recommended that you make a backup of your save folder before continuing. Press enter if you would like to continue.

Traceback (most recent call last): File "C:\Users\Kendy\Desktop\UESaveEditor\fix-host-save.py", line 244, in main() File "C:\Users\Kendy\Desktop\UESaveEditor\fix-host-save.py", line 43, in main temp_new = str(int(new_guid[x-1] + new_guid[x], 16))+',\n' IndexError: string index out of range

How i can do ?

KeoughDarklance commented 5 months ago

I am having the same issue.

xNul commented 5 months ago

@catttuhh it looks like you're missing a zero on the end of your GUID there. You have 23 zeroes instead of 24.

@KeoughDarklance I bet you're having a similar problem.

I'll add a check to make sure the GUIDs are the right lengths

xNul commented 5 months ago

Added to the code. I'll be committing it to the repository soon.