Jump to content
Flann

Overriding a prop with a prop family

11 posts in this topic Last Reply

Highlighted Posts

Posted:
Last Online:  
 

This is a question that came up today in chat after Girafe was kind enough to make some excellent fence props to replace a few maxis fences.  There was a fence created with a few variations of ivy and I thought it would be cool to put them in a family.  However, the original goal was to override one prop, which works just fine with a 1 to 1 replacement, however, what about telling the game to use a family for that prop instead?

I know that the original prop exemplar has to be overridden somehow, but I can't get it to become reference to the family instead.  Anyone know if this is possible?

  • Like 1

Proud member of the NAM development team.

Share this post


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

Have you tried giving the prop family the instance ID of the prop? Or creating a new prop family that uses the instance ID?

  • Like 1

🚜 Get well soon, Cori! 🚜

Share this post


Link to post
Share on other sites
  • Original Poster
  • Posted:
    Last Online:  
     
    32 minutes ago, BartonThinks said:

    Have you tried giving the prop family the instance ID of the prop? Or creating a new prop family that uses the instance ID?

    Yes I did try this, but the old prop was still displayed.

    • Like 2

    Proud member of the NAM development team.

    Share this post


    Link to post
    Share on other sites
    Posted:
    Last Online:  
     
    7 hours ago, Flann said:

    Yes I did try this, but the old prop was still displayed.

    So, I'm a little out of my depth on this one, but I think the problem might be that props and prop families are defined differently in rep 12 (ObjectID) of the LotConfigPropertyLotObject property.

    That said, I'm not 100% sure how the ObjectID rep functions. The SC4 Wiki says that the ObjectID rep is structured as follows:

    0xA0000000 = 0,2,4,6,8,a,c,e - Random one of these characters in case the other ID's are the same.
    0x0BBBB000 = Object Family
    0x00000CCC = Unique Object ID for this family. Incremental for similar objects.

    If I'm reading this correctly (and that's a big if), the ObjectID rep can define a prop's wealth, it's occupant group, and whether it's a standard prop or a prop family. This would prevent a simple override of a prop with a prop family, since you would need to update the ObjectID reps on every lot where the prop is in use.

    Fingers crossed I'm wrong about this. In any case, I'd love to see what @Girafe came up with for those fences. I rely pretty heavily on the HD fences found in WMP Mega Props Vol 01, but Girafe's stuff is always excellent.

    • Like 1
    • Thanks 1

    🚜 Get well soon, Cori! 🚜

    Share this post


    Link to post
    Share on other sites
  • Original Poster
  • Posted:
    Last Online:  
     
    7 hours ago, BartonThinks said:

    So, I'm a little out of my depth on this one, but I think the problem might be that props and prop families are defined differently in rep 12 (ObjectID) of the LotConfigPropertyLotObject property.

    That said, I'm not 100% sure how the ObjectID rep functions. The SC4 Wiki says that the ObjectID rep is structured as follows:

    0xA0000000 = 0,2,4,6,8,a,c,e - Random one of these characters in case the other ID's are the same.
    0x0BBBB000 = Object Family
    0x00000CCC = Unique Object ID for this family. Incremental for similar objects.

    If I'm reading this correctly (and that's a big if), the ObjectID rep can define a prop's wealth, it's occupant group, and whether it's a standard prop or a prop family. This would prevent a simple override of a prop with a prop family, since you would need to update the ObjectID reps on every lot where the prop is in use.

    Fingers crossed I'm wrong about this. In any case, I'd love to see what @Girafe came up with for those fences. I rely pretty heavily on the HD fences found in WMP Mega Props Vol 01, but Girafe's stuff is always excellent.

    Interestingly, in the test lot that I created in PIMX the objectID reps all look the same (all zeros) except for the the last digits which are arranged incrementally.  0x000000001, 0x00000002 and so forth.

    edit

    So thus far it seems that unless there is an exemplar overriding the original prop, the game will display that prop, despite the presence of a prop family with the same id.


    Proud member of the NAM development team.

    Share this post


    Link to post
    Share on other sites
  • Original Poster
  • Posted:
    Last Online:  
     
    8 minutes ago, twalsh102 said:

    @Flann, could you verify how you created your Prop Family?

    image.png.b6cfbb91ff22e258f83c6c866b1b2840.png

     

    image.png.93b6a78f4e78b02250db7849d6a224bb.png

     

    * edit

    I used PIM X 'add to family' originally, then I created the cohort with reader.  Note these exemplars are in two families, the second has the same id as the maxis fence prop.


      Edited by Flann  

    more info

    Proud member of the NAM development team.

    Share this post


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

    It appears this might be a dead end.  I tried one more thing which was to delete the original prop exemplar from simcity1.dat.  Upon loading the city, there was no change on my test lot.  When i replopped it did in fact load the family.  This suggests that any instance of the prop would have to be regrown or replopped.  Further, it seems to require modifying the game files, which most are not going to want to do.

    Restoring the original simcity1.dat and reloading the game led to no immediate change in the test lot, but replopping restored the original fence.

    image.png.793fa18e17c6011eb0c601fa413f619c.png

    • Like 2

    Proud member of the NAM development team.

    Share this post


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

    @Flann -- Does that mean the override works for newly grown lots, it just doesn't work on existing lots?


    🚜 Get well soon, Cori! 🚜

    Share this post


    Link to post
    Share on other sites
  • Original Poster
  • Posted:
    Last Online:  
     
    1 minute ago, BartonThinks said:

    @Flann -- Does that mean the override works for newly grown lots, it just doesn't work on existing lots?

    It works when the original prop exemplar is removed from the game files, so in a sense it's not really an override per se.  And yes the lots need to be regrown or plopped.

    • Like 1
    • Thanks 1

    Proud member of the NAM development team.

    Share this post


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

    I don't know if this is that much of a help, but there is actually an alternative to using prop families: the so-called prop variation technique. This is a technique Maxis uses themselves, and it gets the same result as the prop family technique. It also has the advantage that you don't need to modify prop exemplars of other authors, and furthermore, you can increase the chance of one specific prop that you prefer over others, such as one prop has an 80% chance to appear and another one only 20% (this is possible, I tried).

    To do that, remember which of the LotConfigPropertyLotData's is the "base prop", in this case the fence, and write down the ID's of the props you want to use. For instance: You want 4 props to be displayed randomly.

    Step 1: Place one of these props on a lot, and write down its IID.

    Step 2: Open Reader and look for the LotConfigPropertyLotData with this IID.

    Step 3: Add the IID's of all other props.

    The result should look like this: 0x00000001,(11 other reps),0x(IID 1st prop),0x(IID 2nd prop),0x(IID 3rd prop),0x(IID 4th prop). The rep number should show 16 instead of 13.

    To give one prop a higher chance to appear, just calculate the ratio between the props: For a 80% vs 20%, just put in 4 times the same prop and once the other one.

    This also works with props with different footprint sizes. Only disadvantage: LE only shows you the first of these props, namely, the one with the IID at the 13th rep. This can cause difficulties if you edit lots of other authors, making you oversee additional dependencies. SC4Tool cannot recognize them as well.

    • Like 2
    • Thanks 2

    11241036 Lotting/Modding Thread - Support for all of my uploaded plugins

    Visit my CJ Maxiland, where I'm taking on an enlarged version of Timbuktu!

     

    Share this post


    Link to post
    Share on other sites

    Sign In or register to comment...

    To comment in reply, you must be a community member

    Sign In  

    Already have an account? Sign in here.

    Sign In Now

    Create an Account  

    Sign up to join our friendly community. It's easy!  

    Register a New Account


    ×

    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