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
https://steamhost.cn/steamcommunity_com/sharedfiles/filedetails/?id=2930517551
I got a request: is it possible to change the class of other road types such as elevated, bridge, slope and tunnel? Currently the mod only changes the basic road type class.
Also, it would be PERFECT if you could create your own classes, although I don't know if it's possible
Is this working with the latest verions of CS MT (all DLC included ParkLife) ?
Does this mean I can take a vehicle in the asset editor and make it a prop by myself?
And the ItemClass list is automatically generated from loaded all ItemClassCollections available when this mod is loaded--
-- I shall have to remember to change that if I have a report of a specific mod's new itemclass not appearing; L3-5 industrial/commercial for example.
Similarly UICategories are automatically generated from those populated by existing assets, though adding unpopulated categories derived from textureAtlases is possible.
DontCryJustDie Jul 1 @ 9:42am
@tcgames65 I just found that in the new source code https://forum.paradoxplaza.com/forum/index.php?threads/taxiai.867224/
Now all we need is a Taxi Depot.
I'll refactor and update later when I have this solved.
I used the "this.m_info.m_class.m_service = ItemClass.Service.Residential;" I'm not sure if its ideal to access it like that, but it did the trick. I can also change the level.
Do you think it'd be possible to silence the noise a building generates? For example I made a "security post", which is basically just a 1x1 tile shed you can use to secure isolated parks so they don't complain about crime. But it plays the police station ambient noise, which sounds very city'esque.
What they will need is your mod, containing your custom AI Class to use that content.
You should be able to use the "Add Required Items" option (in the Steam Workshop) to make downloading it pseudo-automatic. Getting endusers to enable it will be a bit more difficult. (shrugs)
I traced back the code in the SimulationStep methods and found a flag called "ZonesUpdated". This was setting off a long series of if statements that eventualy lead to the buildings demise via "Demolition" tag. I think i read this backwards. It means the zones have been updated, and its time to do some logic. I initialy though it meant that the zones were already updated.
One line of code to remove the tag after every frame, and the building survives!
The whole mod is only 50 lines of code, with 5 lines that do the work.
Ill continue to use your mods to see if I can make this happen. My mod derives a new AI class from ResidentialBuildingAI, so it shouldnt confict with other mods. I also think I only need your mod to assign the new AI, UI categories, and ItemClass. Will someone who downloads my mod + custom building asset need your mods as well?
And yes, I believe that is is 15 on the enum. Might be more practical to alter the simulation step to clear the demolishing flag though I've not played with custom classes to know how the game uses it exactly..
I was able to just derive a new AI class from ResidentialBuildingAI, and override the two methods that dealt with the width and height. I used the building AI changer to assign my new fancy AI class to a 8x8 monument.
Still having issues with the lot vanishing though. Theres no way you can place zoned land under a large lot. I'm trying to see if I can cancel the zone test, or find a way to keep the building flags from changing to none, or even find the method that gets called when the game wants to delete it.
Is it possible to edit or do anything with the ItemClass list that your mod uses? It would be great if I could add a custom ItemClass, and then use your mod to assign it.
The plopped building seems to get deleted when a growable wants the lot for itself. It does still last longer though when its on a zoned plot. I tired a park and a highway with the ResidentialBuildingAI, and on all zone types.
Ill going to look into some free C# learning resources tomorrow, and see if I can pull of a simple mod like the 25 tile unlock. I did take a C++ programming class in school, but never used it beyond that.
That is unless your intrested in making a large ploppable RCI mod... :)
I'm working on a few large 3D models that would be a great way to promote the mod if it gets done.
As for the size limit--
You should be able to use 'reflection' to replace the GetWidthRange and GetLengthRange methods in PrivateBuildingAI (to use the existing AI) or create your own derived class types containing the new override functions.
I don't know which would work better as I have not tried for myself.
I really think this is a feature that people want.
I'm pretty sure the 4x4 limit could be cheaply overcome by just making the building bigger than the lot.
Beyond lot size and maybe giving them thier own interface tab, are there any other issues that you forsee that would prevent this from working in game?
I've got a little web programming experiance with no C#, but I'm willing to learn a bit to make this work. Would one need to decompile the PrivateBuildingAI, and find a way to override the lot size limit?
Or maybe duplicate it, remame it, and use a mod like the building AI changer?
The PrivateBuildingAI has a hardcoded size limit of 4x4. You would need to make (or find) a mod that would bypass or remove this limitation.
But changing the building class to one that is player-placed will indeed make it plopable (as in the above screenshot). These plopped buildings seem to use the ItemClass level, which for most user building types is 1. So if you used the Monument class, a unique 4x4 residental monument only holds 10 people (unless you change the ItemClass level for all monuments to 5 or greater.) Or call it a highway.
Could this be used to make large unique residential plopables?