**DISCLAIMER: This is a work in progress and I do not work on Cities Skyline, this is my hobby project I do on my free time**
Alright so what's the deal here?
So what I want to do is add political functionality to the masterpiece of Colossal Order which is the game of Cities Skyline. The core goal being that your citizens should have more detailed demographics and you as mayor at the end should be able to proclaim yourself an independent city state and all the craziness that follow there. Having somewhat special privileges being a first party developer at Paradox I've been exploring the modding possibilities of this game I've grown addicted to and starting adding my own functionality to it. So far it isn't much but I'm creating this thread a bit prematurely to give some other modders the opportunity to learn from my experiences and maybe even outpace me in the development of their own mods. DO NOTE THAT THIS MOD IS NOT PLAYABLE YET!
The source code
The source can be located there https://github.com/Groogy/Republic
I don't know what your experience is modding from before but if you do know C# and perhaps even the Unity engine, then creating a mod for Cities: Skyline shouldn't be that terribly alien to you. I will happily answer any questions people have in how to interact with the modding API provided by CO from my own experiences. I develop in Visual Studio 2013 and it works quite well, I have a post-build script that copies the DLL to the folder where Cities: Skyline can read it. The folder where Cities: Skyline read mods like this is in <user directory>\AppData\Local\Colossal Order\Cities_Skylines\Addons\Mods on windows. The DLL's you have to link against are ICitites.dll and UnityEngine.dll primarily, these can be found in the installation directory of Cities: Skyline. You should also set your target .NET framework to be 2.0 I believe.
Currrently implemented features
Debugger
The debugger at the moment is very lightweight and the features of it are runtime code compilation through a console to run custom commands in C# and watches of any data in you can access. The Debugger as it is right now is very hard coded and works only if you copy the mono-files from the install directory of Cities into the steamapps\common folder. I'll try and improve the debugger to somehow solve this problem for you in the future and make it much more dynamic and feature rich such as code-injection. For now you can use it as a lesson into reflection and capabilities of a language as C#
Getting setup
So far I've gotten the mod setup, it gets loaded and it makes sure there is a core created for the mod to always rely on, known for people experienced in programming as a "Singleton". So its a good thing to look at if you are confused to know how to get your own mod started. Mainly look at the Republic.cs file to get the gist of it.
Features planned for the future
Citizen expansion
Currently aiming to somehow figure out how I can attach more data per-citizen in the game, current idea is to keep my separate structure outside the in-game data and keep it synced with the data generated by the vanilla game. However this is a PIA and I would like a more elegant solution. Data to be tracked would be issues like political affiliation, religious views and nice additions in a similar fashion.
Government
With the milestone progression system in the game, eventually you would unlock a Mayor's office building and with it the Government menu where you can view the previously mentioned data statistics. Its also from here you should be able to declare yourself a independent city state when you've grown big enough and step forward as the eternal President of this most esteemed republic of <insert name of city here>. It should however be a journey to get here, not every city in the world declares itself independent every other day.
Military
Of course in order to defend your new glorious republic from the oppressive UN and the nation you came from you need a military to defend yourself.... and of course quell the rebellion you'll get every now and then. For now this idea is in the far future and I'll focus on getting government stuff done first before moving on here and I'll fill this out when I get here eventually.
Misc
I probably can always add more stuff as I go a long with the game. Essentially I've grown addicted to the game and I've racked up so much hours on it by now that I want to add more to it.
Why is there a fancy platypus symbol on the thread?
If you somehow missed the big red disclaimer I put in the top, no I do not have any associations with Colossal Order but I do work on the game Crusader Kings 2. I did however get very and terminally addicted to the game of Cities: Skyline to the very degree that I decided I wanted to add more stuff to it on my free time. Do not see anything of what's written here as an official statement of Paradox, it will make both of our lives much much easier.
This thread will change as I get more work on the mod done. For now feel free to ask my any questions to get your own mods started!
A good place to have a look as well is here: http://www.skylineswiki.com/Modding_API
Alright so what's the deal here?
So what I want to do is add political functionality to the masterpiece of Colossal Order which is the game of Cities Skyline. The core goal being that your citizens should have more detailed demographics and you as mayor at the end should be able to proclaim yourself an independent city state and all the craziness that follow there. Having somewhat special privileges being a first party developer at Paradox I've been exploring the modding possibilities of this game I've grown addicted to and starting adding my own functionality to it. So far it isn't much but I'm creating this thread a bit prematurely to give some other modders the opportunity to learn from my experiences and maybe even outpace me in the development of their own mods. DO NOTE THAT THIS MOD IS NOT PLAYABLE YET!
The source code
The source can be located there https://github.com/Groogy/Republic
I don't know what your experience is modding from before but if you do know C# and perhaps even the Unity engine, then creating a mod for Cities: Skyline shouldn't be that terribly alien to you. I will happily answer any questions people have in how to interact with the modding API provided by CO from my own experiences. I develop in Visual Studio 2013 and it works quite well, I have a post-build script that copies the DLL to the folder where Cities: Skyline can read it. The folder where Cities: Skyline read mods like this is in <user directory>\AppData\Local\Colossal Order\Cities_Skylines\Addons\Mods on windows. The DLL's you have to link against are ICitites.dll and UnityEngine.dll primarily, these can be found in the installation directory of Cities: Skyline. You should also set your target .NET framework to be 2.0 I believe.
Currrently implemented features
Debugger
The debugger at the moment is very lightweight and the features of it are runtime code compilation through a console to run custom commands in C# and watches of any data in you can access. The Debugger as it is right now is very hard coded and works only if you copy the mono-files from the install directory of Cities into the steamapps\common folder. I'll try and improve the debugger to somehow solve this problem for you in the future and make it much more dynamic and feature rich such as code-injection. For now you can use it as a lesson into reflection and capabilities of a language as C#
Getting setup
So far I've gotten the mod setup, it gets loaded and it makes sure there is a core created for the mod to always rely on, known for people experienced in programming as a "Singleton". So its a good thing to look at if you are confused to know how to get your own mod started. Mainly look at the Republic.cs file to get the gist of it.
Features planned for the future
Citizen expansion
Currently aiming to somehow figure out how I can attach more data per-citizen in the game, current idea is to keep my separate structure outside the in-game data and keep it synced with the data generated by the vanilla game. However this is a PIA and I would like a more elegant solution. Data to be tracked would be issues like political affiliation, religious views and nice additions in a similar fashion.
Government
With the milestone progression system in the game, eventually you would unlock a Mayor's office building and with it the Government menu where you can view the previously mentioned data statistics. Its also from here you should be able to declare yourself a independent city state when you've grown big enough and step forward as the eternal President of this most esteemed republic of <insert name of city here>. It should however be a journey to get here, not every city in the world declares itself independent every other day.
Military
Of course in order to defend your new glorious republic from the oppressive UN and the nation you came from you need a military to defend yourself.... and of course quell the rebellion you'll get every now and then. For now this idea is in the far future and I'll focus on getting government stuff done first before moving on here and I'll fill this out when I get here eventually.
Misc
I probably can always add more stuff as I go a long with the game. Essentially I've grown addicted to the game and I've racked up so much hours on it by now that I want to add more to it.
Why is there a fancy platypus symbol on the thread?
If you somehow missed the big red disclaimer I put in the top, no I do not have any associations with Colossal Order but I do work on the game Crusader Kings 2. I did however get very and terminally addicted to the game of Cities: Skyline to the very degree that I decided I wanted to add more stuff to it on my free time. Do not see anything of what's written here as an official statement of Paradox, it will make both of our lives much much easier.
This thread will change as I get more work on the mod done. For now feel free to ask my any questions to get your own mods started!
A good place to have a look as well is here: http://www.skylineswiki.com/Modding_API
Last edited:
- 8