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

KSP Loading Issue #2548

Closed
CZ-81H-YZ5Block5 opened this issue Apr 27, 2020 · 9 comments
Closed

KSP Loading Issue #2548

CZ-81H-YZ5Block5 opened this issue Apr 27, 2020 · 9 comments
Labels
Milestone

Comments

@CZ-81H-YZ5Block5
Copy link

I already installed the C++ 2015-2019 Redist that Principia required,but the Principia still can't load properly
Here's the texts in the Principia Dialog:
The Principia DLL failed to load.
An unknown error occurred; detected OS Microsoft Windows NT 10.0.14393.0 64-bit; tried loading dll at 'GameData\Principia\x64\principia.dll'. Note that the Microsoft Visual C++ 2015-2019 Redistributable (x64) - 14.22.27821 are required.

Warning: don't load a Principia save before you have fixed this error; it might get damaged.

the glog file of principia are not create.
KSP.log

@pleroy
Copy link
Member

pleroy commented Apr 27, 2020

I think we'll need more information to figure out what's happening. It would be good if you could:

  1. Download and install Process Monitor from the Microsoft site.
  2. Start it.
  3. Start KSP.
  4. Use the Filter menu in Process Monitor to filter Process Name contains KSP.
  5. Save the events in a PML file and send it to us.

@CZ-81H-YZ5Block5
Copy link
Author

https://share.weiyun.com/5VxiuUp
I don't know what format do you need,so here's the CSV Format.

@pleroy
Copy link
Member

pleroy commented Apr 27, 2020

Are you by any chance running KSP using a shortcut? If so, what is the "Start in:" directory for the shortcut?

The search for the Principia DLL normally starts at the directory containing KSP_x64.exe and appends GameData\Principia\x64\principia.dll. However, if using a shortcut, the search starts at the "Start in:" directory, which may not be the place where Principia is installed.

In your logs I see confusing references to two KSP installs named E:\National Department of Space and Aeroplanes\Kerbal Space Program-Stock- 多体 (the one that contains Principia, I presume) and E:\National Department of Space and Aeroplanes\Kerbal Space Program-Stock- 澶氫綋. I suspect that you have shortcuts that straddle the two installs.

ETA: If that's not the explanation, could you please do another run of Process Monitor and give us a PML file? That has much more information than the CSV file.

@CZ-81H-YZ5Block5
Copy link
Author

NO,I don't start KSP by a shortcunt,and I moved the whole KSP to E:\Kerbal Space Program-Stock- 多体\KSP_x64.exe,but it still doesn's work.And here's the PML file :https://share.weiyun.com/5bHi2aF

@CZ-81H-YZ5Block5
Copy link
Author

and here's the KSP.log
https://share.weiyun.com/5uovxkl

@eggrobin
Copy link
Member

@pleroy

In your logs I see confusing references to two KSP installs named E:\National Department of Space and Aeroplanes\Kerbal Space Program-Stock- 多体 (the one that contains Principia, I presume) and E:\National Department of Space and Aeroplanes\Kerbal Space Program-Stock- 澶氫綋.

>>> '多体'.encode('utf-8').decode('cp936')
'澶氫綋'

(from chat) C:\Program Files\Kerbal Space Program\1.9.1- 多体\GameData\Principia\principia.la

>>> '多体'.encode('utf-8').decode('cp1252')
'多体'

@eggrobin
Copy link
Member

Long story short: mono bug, the KSP directory needs to have an ASCII path.

Sigh.

@pleroy
Copy link
Member

pleroy commented Apr 28, 2020

To elaborate on @eggrobin's answer:

I was able to reproduce your problem by appending - 多体 to the directory containing KSP, thus, on my machine C:\Program Files\Kerbal Space Program\1.9.1- 多体. Looking at the traces I see that it tries to access the directory C:\Program Files\Kerbal Space Program\1.9.1- 多体\GameData\Principia, just like in your case it was trying to access E:\National Department of Space and Aeroplanes\Kerbal Space Program-Stock- 澶氫綋. It turns out that Mono is taking file paths encoded as UTF-8 and interpreting them in the local code page (CP936, simplified Chinese, in your case, CP1252, western Europe, in my case).

Mono is full of this kind of bugs. The only solution is unfortunately to use ASCII file paths.

@CZ-81H-YZ5Block5
Copy link
Author

Thank you very much

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants