Install Steam
login
|
language
简体中文 (Simplified Chinese)
繁體中文 (Traditional Chinese)
日本語 (Japanese)
한국어 (Korean)
ไทย (Thai)
Български (Bulgarian)
Čeština (Czech)
Dansk (Danish)
Deutsch (German)
Español - España (Spanish - Spain)
Español - Latinoamérica (Spanish - Latin America)
Ελληνικά (Greek)
Français (French)
Italiano (Italian)
Bahasa Indonesia (Indonesian)
Magyar (Hungarian)
Nederlands (Dutch)
Norsk (Norwegian)
Polski (Polish)
Português (Portuguese - Portugal)
Português - Brasil (Portuguese - Brazil)
Română (Romanian)
Русский (Russian)
Suomi (Finnish)
Svenska (Swedish)
Türkçe (Turkish)
Tiếng Việt (Vietnamese)
Українська (Ukrainian)
Report a translation problem
any plans for Cities Skylines 2?
Why do you need to debug the python server in the first place? The IronPython engine does not work? :)
Alt+S brings up the ingame console, but it does not appear to be attached to the python server (pressing F5 on priint("Hello World!") has no effect. Should it? The wiki suggests that the in game component " will automatically connect to it after you open the Python Console dialog window." Should the ingame console be usable?
In VC22, I'm not yet able to execute code and have it affect the game state. The edittor isn't recognizing game symbols. What should I be using as the Python environment? Am I on the right track?
Looking at the PC source code suggests it's using a vanilla TCP connection. As VSC doesn't offer that option (ssh is supported), I've installed VS22. Manually launching SkylinesRemotePythonDotnet.exe, and then, in VS22, Debug->Attach To Process produces several lines of output of the form '
SkylinesRemotePythonDotnet.exe' (CLR v4.0.30319: SkylinesRemotePythonDotnet.exe): Loaded 'C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Xml/v4.0_4.0.0.0__b77a5c561934e089/System.Xml.dll' . Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
In C:S I've enabled all the options except "execute scripts synchronously"
On further reflection, I think I understand why my prior attempts failed: what I need to do is establish a connection with SkylinesRemotePythonDotnet.exe running as a "remote" sever, not as a local interpreter. I found multiple tutorials on how to do this in VSC, so it seems probable that it's possible to do it with Python Console. However, I do not know what port to use, if there is an authentication token, etc. Any clarification you could provide would be most appreciated.
Am I correct in assuming SkylinesRemotePythonDotnet.exe is the Python interpreter? VSC (and PyCharm) both complain with similar messages (e.g., VSC's says, "An invalid Python interpreter is selected"). I tried making a copy named python.exe. in the same directory, but it too was rejected. To ensure I understood the configuration process correctly, I also installed IronPython and had no trouble VCS to use it.
I'm now at a loss on how to proceed. Would you please elaborate on how to configure VSC (preferably or VS otherwise) to work with your marvelous creation?
The wiki mentions "You can run and debug the extarnal Python application directly from Visual Studio" and "you can start the server in VS." My efforts to do so have thus far proven futile and I realize the fault may be my own because my attempts (thus far) have been with VSC (with the MS Python Tools installed as recommended on the IronPython page) rather than VS proper.
[continued]