Jump to content
TPB

ToolController m_EditPrefabInfo Properties Compendium

17 posts in this topic Last Reply

Highlighted Posts

Posted:
Last Online:  
 

Hello everyone,

 

I've been compiling a list of all the properties that I know of that are editable within ploppable assets, and what each one does and how to manipulate it.

 

This topic will be a record of these and we can keep expanding it as more variables are exposed.

 

For now I only know of properties within the ToolController's editPrefabInfo um, section, module or whatever its called. Once we learn more we can change the title of the topic.

 

I'm not a programmer so I have really no idea what any of the code means or anything else. I just have patience to do tests, experiment and analyse.

 

Please consider contributing your own discoveries to this list.

 

--

 

FAQ

 

What is ToolController and m_editPrefabInfo?

 

Please consider contributing if you know more, as I have not really any clue.

 

But I know that's where most of these variables that we can manipulate are located. 

 

I think these are only related to stuff you can plop, so when someone step up to provide us with modding information we can again, update this topic accordingly.

(More info needed)

 

How do I examine m_editPrefabInfo

 

The best way I know of is through a Mod called Mod Tools by nlight. Get it here.

 

Once you have the mod, enable it in content Manager, then open an asset that you wish to examine in the Asset editor.

 

Click anywhere in the editor scene, then press CTRL+E to open the Mod Tools explorer.

 

On your left is a huge list of um, modules or whatever they are called. Find ToolController. Click on it.

 

Just down the list is another instance of ToolController, Click on it.

 

Welcome to the Tool Controller.

 

As you can see there are a bunch of lines of code and variables that we can apparently edit, but for now I've only learned what the stuff inside the PrefabInfo m_editPrefabInfo section does.

 

So find the line that reads PrefabInfo m_editPrefabInfo and collapse it. This is where we will be fiddling with stuff.

 

Why should I examine ToolController and m_EditPrefabInfo?

 

If you want to modify your assets in certain ways, to make them more appealing or for any other practical reason, you'll want to learn your way around this interface.

 

 


 

 

NOTE: Different types of assets have different properties. For instance, only props and tress have the m_createRuining property, which causes the dirt-patch to appear when plopped.

 

For the sake of clarity, I won't include include properties who's effects are too obvious, or uninteresting.

 

I'll also include properties that look interesting, even if I still don't know how to use them.

 

Green = Information complete more or less complete.

Orange = Partial information.

Red = Very little information.

 

Please comment below to add your knowledge.

 
 

List of Editable Properties and what they do (Incomplete, more info needed)

 

  • m_createRuining


    When enabled, causes props and trees to spawn a dirt patch at the base.
    I personally hate that dirt patch, so thank you CO for exposing this.
    Default is on.


     

  • m_autoRemove


    When enabled, asset will be automatically bulldozed when you try to place something over it.
    Like when you plop a school over some residential buildings. A small bulldoze icon appears over them, and they get highlighted. But you can still plop it.
    Useful.
    Default is off.


     

  • m_circular


    Tick this box to make your asset circular. Unsure exactly how size is translated. This effect is not seen in the Asset Editor. You can see it only in-game. Assets will still load as quads in the editor.
    Useful.
    Default is off.


     

  • m_clipTerrain


    This property I have played with a bit but am still unsure of what exactly it does. I suspects it affects the way the base of the model interacts with the terrain. There is a post about it in the Paradox forums, although without that many answers. I'll add it later to this spoiler.


     

  • m_flattenTerrain


    Same as above, but a bit more obvious. Still have not tested extensively so more information is needed.


     

  • m_fullGravel, m_fullPavement


    It does what it says in the box. Tick either of these to have the entire ground surface of the asset rendered as gravel or pavement.


     

  • m_placementMode


    Roadside   (00 in Hex editor) - Asset must be plopped alongside a road(how annoying). Most assets have this as default, but not all obviously.

    ShoreLine  (01) - Asset must be plopped along the shore, like water and sewage pumps.

    OnWater    (02) - Asset must be plopped inside water, like the advanced wind turbine.

    OnGround  (03) - Asset can be plopped anywhere on the ground(excluding steep slopes) With this mode, any road, highway and rail stubs(maybe ped too, haven't tested) that you place inside your asset in a way that they overhang, will snap to the ends of existing roads, rail or highway. Like my Modular Avenue pieces do. The exception is they won't snap to ends that are themselves part of another non-intersection asset.

    OnSurface (04) - Asset can be placed on any surface as long as it doesnt collide with other assets and the terrain is not too steep. This is the default for intersection assets. Allows you to plop on ground AND/OR on water. Needs more testing.


     

  • m_useColorVariations


    This allows for color variations on the main asset model. It's automatically on for stuff that has a large model like the train station template, and other stuff(haven't tested extensively)
    But it's off for parks, iirc. So in theory we can turn this on and have the model change colors on parks too.
    UPDATE: It seems this feature is currently not working for most asset templates.
    Confirmed to work: LC Lvl1, HC Lvl1


     

  • m_expandFrontYard


    I've tested this a little bit, it doesn't seem to have an effect, unless the asset is circular. I used this on a circular Modular Avenue piece to allow the zoning to reach a road curve that's not near the edge of the asset. It doesnt go all the way, but it did add a few zonable spaces.
    Needs more testing, effect might be dynamic, ie. perhaps the zones expand once stuff grows on them.


     

  • m_placementStyle


    Unsure what this is.
    Options are Manual, Automatic, Procedural.
    Most assets(or all?) have this set to Manual.
    Have not tested.


     

  • m_material


    This property is only available with assets that have imported models. I Include it because it seems you can change the base color of the model here. It's grey as default. I suspect if you change the shade of grey here you can control the lighting on your model.
    More info needed.


     

  • m_MaxBrightness, m_MinBrightness


    Have not played with this, so unsure what the effects are or how exactly to manipulate it.
    Need more info.


     

  • m_MaxScale, m_MinScale


    These are properties exclusive to Tree assets.
    They control the range of sizes that trees appear at when placed.
    Set both values to the same number to have no variation in size.
    I tested this on 04/18 and can confirm it works.
    NneRQSH.png
    4kYa3lk.png


     

  • m_UICategory, m_UIEditorCategory


    The properties seem obvious but I have not succeeded in changing an item's menu location yet. Need more info, what do these do? How to manipulate properly? Seems its not fully exposed atm.
    More info needed.


     

  • m_UIPriority


    This is a very nice property that allows you to group your assets together in their menu. 
    Most stuff has this set to 0 by default. Hence the mess in the menus.
    Can be a negative number.
    More information on how to handle a very large amount of menu items is needed. Perhaps a UIPriority Index. Or even better, let users organize the order themselves?


     

  • m_variations


    This is an extremely interesting property of trees, and possibly props too, haven't looked.
    No idea how it works, but there are fields for prefab id's or something similar. 
    I suspect you can have actual model variations of your tree, so that when you plop them they not only change size but also shape and structure. NICE.
    Need more info please CO!


     

  • m_noBase


    This one I just spotted, and I'll be testing right after I submit this topic. If it does what I think it does, it's fantastic.
    What I think it does is remove the "foundation" part of models, so that there will not be a ugly grey block showing if the ground is uneven under, say, rock models. Which was an issue I was having yesterday with a rock asset I'm working on.


  Edited by TPB  
  • Like 7

Share this post


Link to post
Share on other sites
Posted:
Last Online:  
 

Useful info here... I'll look at some stuff in the color variation system (since there is something preventing some of the buildings we build to use all 4 color choices ingame). Maybe it can be unlocked this way.

Share this post


Link to post
Share on other sites
Posted:
Last Online:  
 

Great idea! 

m_flattenTerrain

There's a few buildings with subway entrances in them in the workshop that sound like they could benefit from this, since they naturally conform to slopes and distort the building. Definitely something worth testing!

 

Does it look like there's any way to combine functionality of different asset types into one asset yet? Like a commercial building with commercial building stats that also serves as a subway stop? Maybe an office building that also offers tourism and happiness for those that live near it? A house that can contribute to the power grid by having its own green energy methods installed, but that still serves as a house for cims?

Share this post


Link to post
Share on other sites
Posted:
Last Online:  
 

m_MaxScale, m_MinScale...

 

This is exactly what I was looking for. Now if only there was an option for wind sway, I'd be set.

Share this post


Link to post
Share on other sites
Posted:
Last Online:  
 

Hi there, 

This is great information TPB  :thumb:

 

before, TPB gave me good advice about these properties in chat of Steam,

Thank you again TPB for your kindness and used your time too. I appreciate that and am very glad so much !! 

 

We(Japanese) don't have a successful forum about MODing and ASSETing yet unfortunately,

so I'm hard to learn and study, I have trouble with English that am weak in.

I need a specialist as like you TPB who speak japanese, I hope so.  :D

 

Play and enjoy the C:SL together as long as possible  :yes:

 

 

Thank you

 

--- Edited ---

I'm sorry TPB, I don't understand and speak English well,

so I troubled you when speak in chat with you. not right English, not good English....and more  :(

Share this post


Link to post
Share on other sites
  • Original Poster
  • Posted:
    Last Online:  
     

    Useful info here... I'll look at some stuff in the color variation system (since there is something preventing some of the buildings we build to use all 4 color choices ingame). Maybe it can be unlocked this way.

     

    You've been including the _c map as well, I assume?

     

     

    Great idea! 

    m_flattenTerrain

    There's a few buildings with subway entrances in them in the workshop that sound like they could benefit from this, since they naturally conform to slopes and distort the building. Definitely something worth testing!

     

    Does it look like there's any way to combine functionality of different asset types into one asset yet? Like a commercial building with commercial building stats that also serves as a subway stop? Maybe an office building that also offers tourism and happiness for those that live near it? A house that can contribute to the power grid by having its own green energy methods installed, but that still serves as a house for cims?

     

    Not that I know of yet, you can't even change an item's menu location, let alone that. But this is something that would be awesome, hopefully CO staff will find this thread and give us some info.

     

     

    m_MaxScale, m_MinScale...

     

    This is exactly what I was looking for. Now if only there was an option for wind sway, I'd be set.

     

    I also am very interested in the wind effect becoming exposed in future patches. So far I haven't found this anywhere. For me it would be a means to use props in the game by turning wind off and importing them as trees. Then we could paint props in the game which would be cool.

     

     

    Hi there,  *snip*

     

    --- Edited ---

    I'm sorry TPB, I don't understand and speak English well,

    so I troubled you when speak in chat with you. not right English, not good English....and more  :(

     

     

    No need to apologize mas71, I am happy to help, especially if that person is someone I consider an SC4  Legend ;)

    Feel free to send me any questions directly to Steam chat at any time, 24/7.

    Share this post


    Link to post
    Share on other sites
    Posted:
    Last Online:  
     

     

     

    m_MaxScale, m_MinScale...

     

    This is exactly what I was looking for. Now if only there was an option for wind sway, I'd be set.

     

    I also am very interested in the wind effect becoming exposed in future patches. So far I haven't found this anywhere. For me it would be a means to use props in the game by turning wind off and importing them as trees. Then we could paint props in the game which would be cool.

     

     

     

    As I mentioned in a previous post, the wind (and object sway) disappears in an area surrounded by tall buildings (a CBD, for example). I believe the sway is a function of how windy an area is. There's got to be a controller for that somewhere that is tied to surrounding building height or something. For now, I am going to develop my models and import them as trees, I will just be constrained to plopping them downtown until someone figures out how to turn off the wind. But again, the good thing about importing as trees, interference with road/building corners do not exist! The possibilities are endless :thumb:

    Share this post


    Link to post
    Share on other sites
  • Original Poster
  • Posted:
    Last Online:  
     

     

     

    As I mentioned in a previous post, the wind (and object sway) disappears in an area surrounded by tall buildings (a CBD, for example). I believe the sway is a function of how windy an area is. There's got to be a controller for that somewhere that is tied to surrounding building height or something. For now, I am going to develop my models and import them as trees, I will just be constrained to plopping them downtown until someone figures out how to turn off the wind. But again, the good thing about importing as trees, interference with road/building corners do not exist! The possibilities are endless :thumb:

     

     

    There is another trick you can use for now as well. I've seen a few "brush" assets out there that just tell you to do that to put the billboard or whatnot wherever you want.

     

    Make your asset into the normal category, set the size to 1x1 and enable m_circular (and set m_placementMode to the right type). Then by using the Overlap function of the No Pillars mod (which you really should get if you don't have) you can plop these little round assets almost anywhere, even on roads and stuff.

     

    Not ideal but it works for now as a workaround.

    Share this post


    Link to post
    Share on other sites
    Posted:
    Last Online:  
     

     

    Useful info here... I'll look at some stuff in the color variation system (since there is something preventing some of the buildings we build to use all 4 color choices ingame). Maybe it can be unlocked this way.

     

    You've been including the _c map as well, I assume?

     

    Yep... but nevermind what I said... the fact that color varieties don't grow can't be related to the assets themselves (or only partially) because when we switched from 1.06b to 1.07c I noticed that my custom building that only grew one color now grew a different one, but still only one.

    Changing something in the asset might not solve that.  :boggle:

    Share this post


    Link to post
    Share on other sites
    Posted:
    Last Online:  
     

     

    • m_useColorVariations

      This allows for color variations on the main asset model. It's automatically on for stuff that has a large model like the train station template, and other stuff(haven't tested extensively)

      But it's off for parks, iirc. So in theory we can turn this on and have the model change colors on parks too.

       

     

    afaik atm Color Variations work for almost none of the templates. eg Lower Commercial L1 will work. L2-L3 don't; they have this option enabled by default though.

    already tried to hex it. could we make a list for templates that actually work? i know LC L1 and HC L1 work as they should.

     

    Eg:

    http://steamcommunity.com/sharedfiles/filedetails/?id=419054907 wont use Color Variations

    http://steamcommunity.com/sharedfiles/filedetails/?id=423841720 does use Color Variations

    • Like 1

    Share this post


    Link to post
    Share on other sites
  • Original Poster
  • Posted:
    Last Online:  
     

    Good idea, I'll add that to the spoiler for m_useColorVariations shortly. thank you!

     

    EDIT: I tested the m_minScale and m_MaxScale properties and it does exactly what expected. See the relevant spoiler in main topic for  images.


      Edited by TPB  

    Share this post


    Link to post
    Share on other sites
    Posted:
    Last Online:  
     

    • m_clipTerrain

      This property I have played with a bit but am still unsure of what exactly it does. I suspects it affects the way the base of the model interacts with the terrain. There is a post about it in the Paradox forums, although without that many answers. I'll add it later to this spoiler.

    [/indent]

     
    m_clipTerrain :
    makes the ground and structure fit on the ground, example : the asphalt on ground will "clip" (follow) the terrain inclination. But the walls (foundations) will be higher/lower depending on the foundation. So the foundations make the "walls" look like the building is always flat even if a cliff is present or not.

    Share this post


    Link to post
    Share on other sites
    Posted:
    Last Online:  
     

    I found a few more that might be of interest. These are some properties that let you change the render distances for the primary model and the LOD model. Note that these properties are different for buildings and props, confirming my suspicion that the game handles LOD models for buildings and props differently.

     

    For buildings:

     

    m_minLodDistance: The minimum distance at which the game starts using the LOD model

    m_maxPropDistance: The maximum distance at which the game will draw props that are part of the building. When you zoom out further than this the prop vanishes.

    m_maxLodDistance: Probably related to the other two somehow, but I've played around with it and it doesn't seem to do anything.

     

    For props:

    m_maxRenderDistance: The maximum distance at which the prop gets drawn. When the prop is placed as part of a building the game just seems to just use whichever value is larger between this value and m_maxPropDistance for the building.

    m_lodRenderDistance: By default both this and m_maxRenderDistance are set to 1000, which is probably why the game doesn't seem to use LODs for props. If you set m_lodRenderDistance lower it may be possible for the game to render an LOD model for the prop, but I haven't gotten this to work for me.

     

    Also, one more property that might be of interest is m_size, which is located under m_generatedInfo (a subcategory of m_editPrefabInfo). This value is a 3 component vector giving the x, y, and z dimensions of the asset in game units which are (about?) 1/8 of a grid square. It is generated automatically when a model is imported, so ordinarily there shouldn't really be a need to mess with it. However, it is useful in certain cases for props when the game is giving you the "Generated info has zero size" error. By modifying this value manually you can fix broken props.

    • Like 1

    Share this post


    Link to post
    Share on other sites
    Posted:
    Last Online:  
     

    To continue the list, there is one property, m_class, that defines a building's AI. It is stored as a string, and the string is preceded by a byte denoting the length of it. For example, if the string is Beautification Item, then the hex view looks like this:


    6D 5F 63 6C 61 73 73  m_class
    13 42 65 61 75 74 69  .Beauti
    66 69 63 61 74 69 6F  ficatio
    6E 20 49 74 65 6D     n Item
    

    The "dot" (not always) before "Beautification" is the count byte. The string is 19 characters long. 19 is converted to 13 on the hexadecimal base.
     
    When this property is changed to, say, Deathcare Facility, the building AI is replaced. It will now act as a cemetery or crematorium, delivering hearses to transport bodies. This is the most significant change. The behavior of the building will assume the behavior linked with the building AI. Now it will also belong to the Healthcare and Deathcare UI group, and color variations will be available, while parks (whose m_class is Beautification Item) don't have variable color model even with m_useColorVariation manually turned on.

     

    The building AI introduced by m_class has many influences over other properties. There are a lot of different building AI's. To name just a few, there are also Highway, Wind Turbine Facility, Electricity Facility, Water Facility, Police Facility, etc.

     

    m_UICategory, m_UIEditorCategory

    The properties seem obvious but I have not succeeded in changing an item's menu location yet.

     

    The building AI's settings will override a certain set of fields, depending on the type of AI, so manually editing these fields would have no effect.


      Edited by Sims firehouse  

    Share this post


    Link to post
    Share on other sites
    Posted:
    Last Online:  
     

    m_expandfrontyard

     

     

     

    When an asset grows in a space bigger than it's size, eg a 3x3 asset growing in a 3x4 space, the asset takes up the 3x3 space and the back row of tiles will be used as a back garden.

    This is the default. It means you can have houses that get bigger gardens on bigger plots. (the editor lets you set up props in the asset that will only show if it spawns in an area bigger than the asset size).

     

    Expand front yard does the opposite; it moves the 3x3 asset to the back of the 3x4 space and will show any props etc that were placed in front of the asset in the editor.

     

    This is a handy option for commercial, as it means you can have extra front carparking space if the asset spawns on a bigger plot.

     

    doobas™

    • Like 1

    Share this post


    Link to post
    Share on other sites
    Posted:
    Last Online:  
     

    Hey guys, I've been fishing through modtools looking for a cause of the outside connections problem with custom assets.

    You know; the fact that know custom station, harbor or airport attracts tourists/cargo.

     

    So, I was looking through >tool controller, then into m_editprefabinfo, then into m_paths. I was looking at the airport in particular and if you find m_netinfo that is "airplane stop" you can see that itemclass: connectionclass = null.

     

    Would this be the problem?? the lack of connection class loading? I have no idea how this could be fixed or whether this is the problem anyway but if you have any thoughts please share!

     

    #edit: I should also mention it is the same with m_netinfo "station track" and m_netinfo "cargo track", which is what makes me think it is the problem.. and I honestly can't find any other mention of connections


    Come follow me on Twitter @CS_badpeanut 🥜 or Facebook!

    Share this post


    Link to post
    Share on other sites
    Posted:
    Last Online:  
    Currently: Viewing STEX Restoration Tracker
     

    With TPB to continue updating this resource, we've decided to hand it over to the community.
     
    If you're interested in contributing, please see here for more info. :read:
     
    Thanks.


    Quick Links

    “SimCity 4 is not just a game, but a tool driven by our own imagination and creativity.”

    Buy me a coffee

    Share this post


    Link to post
    Share on other sites
    Guest
    This topic is now closed to further replies.

    ×

    Thank You for the Continued Support!

    Simtropolis depends on donations to fund site maintenance costs.
    Without your support, we just would not be in our 24th year online!  You really help make this a great community. *:thumb:

    But we still need your support to stay online. If you're able to, please consider a donation to help us stay up and running. This helps sustain a platform where we can share our community creations for years to come.

    Make a Donation, Get a Gift!

    Expand your city with the best from the Simtropolis Exchange.
    Make a Donation and get one or all three discs today!

    STEX Collections

    By way of a "Thank You" gift, we'd like to send you our STEX Collector's DVD. It's some of the best buildings, lots, maps and mods collected for you over the years. Check out the STEX Collections for more info.

    Each donation helps keep Simtropolis online, open and free!

    Thank you for reading and enjoy the site!

    More About STEX Collections