-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathCS2_debug_build
24 lines (18 loc) · 1.39 KB
/
CS2_debug_build
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
# Cities Skylines 2 as Debug Build
This guide allows you to use breakpoints and debug insights from within your IDE solution.
1. Find you Unity Editor install directory (`C:\Program Files\Unity 2022.3.7f1`, Version may change in the future) and navigate to the subdirectory `\Editor\Data\PlaybackEngines\windowsstandalonesupport\Variations\win64_player_development_mono\`
2. Copy `UnityPlayer.dll` to the game directory
3. In your game directory, navigate to the freshly created `Cities2_Data` directory and edit `boot.config` using a text editor
4. Add the line `player-connection-debug=1` to the bottom of the file
5. Done!
Now you should be able to start the game normally via Steam. (by using the PDX Launcher, skipping the launcher with start parameters didn't work for me)
You will need to have the `Unity Game Development` workload installed in the Visual Studio installer, otherwise "attach to unity debugger" will not be shown in Visual Studio and Rider.
When the game window opens, you can attach the Debugger like so:
## Visual Studio
1. Debug -> Attach Unity Debugger
2. Select the (hopefully only one) process shown and click attach
3. Your set breakpoints will now be hit, as long as your mod is locally installed
## Rider
1. Run -> Attach to Unity Process...
2. Select the (hopefully only one) process shown and click OK
3. Your set breakpoints will now be hit, as long as your mod is locally installed