Cities: Skylines

Cities: Skylines

Not enough ratings
IndustryLP 1.0.2
   
Award
Favorite
Favorited
Unfavorite
Mod
File Size
Posted
Updated
3.078 MB
9 Sep, 2021 @ 12:34pm
12 Sep, 2021 @ 5:00am
3 Change Notes ( view )

Subscribe to download
IndustryLP 1.0.2

Description
An Industrial Estate Generator Mod that uses Logic Programming (Answer Set Programming).

Abstract

This mod is included in my final project of my master's degree in computer engineering. The objective is to partially automating the urban planning of industrial parks in a simulation video game by means of automatic reasoning and knowledge representation techniques. For this purpose, a declarative tool governed by rules has been built to generate the framework of the industrial estate and whose output can be used by 'Cities: Skylines®'.

Dependencies

Since we are generating buildings without generating buildable area, it is advisable to install a mod that prevents them from being destroyed in the simulation. My recommendation is to use Ploppable RICO Revisited, as this is the one I have tested the project with.

How to use

The main UI has been divided into the sections below:



  1. Actions: Define region, modify region and generate.
  2. Main panel with Distributions, Preferences and Restrictions tabs.
  3. Main tool
  4. Tool cursor

For defining a region, you have to hold pressed the primary mouse button in any part of the terrain. If the region has enough size, the selection will have orange color, otherwise the selection will be red and when you released the button, it will be errased.

With a region defined, in modify region you can change the size if you hold pressed the primary mouse button in any vertex of the region. To move it you must to do the same in the middle point, and to rotate the area you have to press the secondary mouse button and move the cursor.



Once the region has been made, you must to select any road distribution to tell the generation how to put the industrial buildings. With a distribution selected, you could add building restrictions in any parcel.

If you add a preference, IndustryLP will understand that you want that building to be generated at that given position. On the other hand, if you add a restriction, the mod will understand that you don't want such buildings to be generated in that region.

For remove a restriction, you have to press the secondary mouse button in the building that you want to erase.

When you want to generate solutions, you must to press the generate action. A dialog window will be shown. In this dialog you can change the maximun number of solutions that the mod will show (0 returns all the possible solutions).



Another editable option is to add new rules in ASP Core 2[www.mat.unical.it] format that they will be used in the generation process. For generate the possible solutions we use clingo[github.com] tool to compute the answer sets of a logic program. All the logic program rules are store in .lp files in %mod folder%/logic_program folder.

Any new .lp file will be loaded in the generation process on the fly, so you can test you rules in the Advanced Edition text area and then pass to a file to save it in future generations.

Once you press Generate button, the main panel will change, adding the following sections:



  1. Current solution index / Number of solutions found.
  2. Buttons to change previous / next solution.
  3. Build actual solution.

The main solution will be shown in the region selected. When you build a solution, all the roads and buildings will be created in Cities: Skylines.

If by any chance incompatible rules are entered, the logic program controlling the generation will be unsatisfiable, that's to say, no stable model exists. A warning message will be displayed in the interface and you will have to change this in order to generate a valid solution.



NOTE: If you haven't any mod installed that prevents new building from being removed of the simulation if the area is not zoning with these building type, all the buildings generated will be buldoze because this. For preventing it, my recommendation is to use Ploppable RICO Revisited or any similar mod.

Resources

GitHub[github.com]



License

MIT License Copyright (c) 2019 Rafael Alcalde Azpiazu Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
11 Comments
ButtcheekBoys 3 Feb, 2022 @ 6:36pm 
@northstar2525 = Good Guy Greg meets Grammar Nazi lol
Nicklion (Italy) 24 Oct, 2021 @ 7:07am 
Best wishes for your master's degree! :)
Good_kid_Maad_City 19 Sep, 2021 @ 12:02am 
This mod seems pretty incredible, however, after 5+ attempts, carefullly reading the instructions each time, when I click Generate, it shows "Solutions 0/0" and nothing happens. The "thinking-icon"(?) just spins infinitely. Is this a bug or am i issing something? Am i supposed to select a road type? Ive tried using only vanilla assets. Thank you! I look forward to being able to use this mod appropriately!
northstar2525 17 Sep, 2021 @ 1:53pm 
Check your spelling, first sentence. If this is read by your instructors in your masters program, that spelling error is pretty glaring and they will see it. It's just a mistype.
Kas 14 Sep, 2021 @ 12:09pm 
neat
NEKERAFA  [author] 11 Sep, 2021 @ 2:25pm 
Hi @stbBANNEDWasp and @Brot. In this moment I am writing my final report, so I'm little busy. In the next week I hope to update the mod with some fixes and upload a video that I will use as a demo for the presentation. Still that, thanks for your support :3
Herr Trigger 11 Sep, 2021 @ 11:21am 
@Nekerafa Also I just look at your Profile and see you are in A Coruna, Spain. An interesting coincidence is that my family housed an exchange student from A Corunna about 15 year ago. We lived near Corunna, Michigan, United States so that was a fun coincidence.
Herr Trigger 11 Sep, 2021 @ 11:11am 
I also would like some more screenshot of Mod in use or even video or link to a video of the Mod running in a city. If this Mod works like i think and is stable. I expect this to be featured by some Skylines Content creators very soon. :steamhappy:
Brot 11 Sep, 2021 @ 6:47am 
This already looks really impressive, mate. I'd appreciate if you could provide a screenshot or two of what the final results look like!
NEKERAFA  [author] 10 Sep, 2021 @ 3:17am 
Hi @t1a2l, throughout today I will update the information of this mod with how to use it and dependencies that you need to work.