Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issues with unpacking #19

Closed
cookins opened this issue Feb 15, 2019 · 6 comments
Closed

Issues with unpacking #19

cookins opened this issue Feb 15, 2019 · 6 comments

Comments

@cookins
Copy link

cookins commented Feb 15, 2019

hello
i have last python, freshly installed in Windows. i cant unpack some pak file from game Stardrop - here what i getting:

>>> C:\Users\****\Desktop\u4pak.py unpack E:\games\STARDROP\STARDROP\Content\Paks\STARDROP-WindowsNoEditor.pak
  File "<stdin>", line 1
    C:\Users\****\Desktop\u4pak.py unpack E:\games\STARDROP\STARDROP\Content\Paks\STARDROP-WindowsNoEditor.pak
                                                                                                              ^
SyntaxError: unexpected character after line continuation character

any suggestions?
thanks!

p.s.
never used pyhton before... if you ask!

@panzi
Copy link
Owner

panzi commented Feb 15, 2019

Did you enter this in the Python shell? You need to run that script from the Windows command prompt.

Open cmd.exe, then enter python C:\Users\****\Desktop\u4pak.py unpack E:\games\STARDROP\STARDROP\Content\Paks\STARDROP-WindowsNoEditor.pak

@cookins
Copy link
Author

cookins commented Feb 16, 2019

now i tried same thing from cmd.exe - paste from cmd:

Microsoft Windows [Version 10.0.17134.590]
(c) 2018 Microsoft Corporation. All rights reserved.

C:\WINDOWS\system32>python
Python 3.7.2 (tags/v3.7.2:9a3ffc0492, Dec 23 2018, 22:20:52) [MSC v.1916 32 bit (Intel)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> E:\games\STARDROP\STARDROP\Content\Paks\u4pak.py unpack
  File "<stdin>", line 1
    E:\games\STARDROP\STARDROP\Content\Paks\u4pak.py unpack
                                                          ^
SyntaxError: unexpected character after line continuation character
>>>

@panzi
Copy link
Owner

panzi commented Feb 16, 2019

You're not doing what I said you should do. The E:\game\... part is NOT Python code. Entering it in a python shell of course gives you a syntax error. It is the filename of a script that shall be run. You need to pass it as an argument to the python binary. It should look somewhat like this:

Microsoft(R) Windows DOS
(C)Copyright Microsoft Corp 1990-2019.

C:\WINDOWS\SYSTEM32> cd "C:\Users\cookins\Documents"
C:\Users\cookins\Documents> python.exe "C:\Users\cookins\Desktop\u4pak.py" unpack "E:\games\STARDROP\STARDROP\Content\Paks\STARDROP-WindowsNoEditor.pak"

Followed by the output of the u4pak.py script.

@cookins
Copy link
Author

cookins commented Feb 16, 2019

my bad.
im newbie with python.
is that correct? -
E:\games\STARDROP\STARDROP\Content\Paks>python.exe "u4pak.py" unpack "STARDROP-WindowsNoEditor.pak"
but i getting that:
'utf-8' codec can't decode byte 0xbb in position 93: invalid start byte

@panzi
Copy link
Owner

panzi commented Feb 16, 2019

Ok, that is weird. You could try to replace the 'utf-8' in line 538 of u4pak.py with 'latin1'. Does it work then? But 0xbb in latin1 is the character », which would be an odd character in a file name.

@cookins
Copy link
Author

cookins commented Feb 17, 2019

Maybe some other time. Don't have it for now. Sorry for trouble.

@panzi panzi closed this as completed May 14, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants