Results 1 to 12 of 12

Thread: How to change settlement_min requirement for different cultures

  1. #1
    Libertus
    Join Date
    Aug 2015
    Location
    North Carolina, USA
    Posts
    90

    Default How to change settlement_min requirement for different cultures

    Aradan's solution in Post #11 works for the problem of this thread. Please see his post for an idea of how to make this work.

    I'm currently modding Barbarian Invasion and I'm trying to find a way to change the "settlement_min" setting for the Barbarian and Nomad (Hun included) cultures for the defenses building chain (walls) without altering it for the Roman/Carthaginian/Eastern cultures.

    Basically, I've always found the Barbarian (RTW included) and Nomadic wall defenses to not match the settlement model_strat on the campaign map. The "wooden palisade" works and looks right with a town and large town. The Barbarian/Nomadic "wooden wall" which is just taller on the campaign map, looks strange to me coupled with a large town, but looks right with a minor city (which also is taller). Same thing with the Barbarian/Nomadic "stone wall": it looks off when applied to a minor city (a round settlement with a square stone wall?), but looks natural applied to a large city and huge city. So... I want to change the "settlement_min" setting for the defenses building chain inside the export_descr_buildings.txt, but without affecting the other 3 cultures minimums.

    I want the Roman/Carthaginian/Eastern cultures to remain the same with the "settlement_min" setting, but I want Barbarian/Nomad/Hun to look like this:

    Town -------> wooden_pallisade
    Large Town -> No new building
    Minor City --> wooden_wall
    Large City --> stone_wall
    Huge City --> No new building

    However, you can't (as far as I know) give different factions different "settlement_min" requirements for the same building chain. So, I'm looking for a way around this:

    1. I create a new building chain along the lines of "defenses2" and create this for just Barbarian/Nomad/Hun cultures. While it could work, allowing me to change the settlement minimum setting to what I want, I'm hoping it is unnecessary. Also, I'm guessing there are other files (telling the game what the model/texture for each wall is) that I would have to change, and I'm unfamiliar with such files. I doubt I know all files required to preform such a change.

    2. Can I change the current "wooden_wall" and "stone_wall" for said cultures so that the game believes they are now the levels "stone_wall" and "large_stone_wall", that way, I get the models I want in the campaign at the appropriate settlement minimum level? I also would be able to edit the bonuses for different factions, so that helps. But this would mean "technically" the Barbarian/Nomad/Hun cultures would not have a "wooden_wall" entry, because that entry was moved up to "stone_wall"... is that possible?

    In short: I'm looking for a way to make the Barbarian/Nomad/Hun culture's "wooden_wall" and "stone_wall" entries become available at "settlement_min" of "minor_city" and "large_city" respectively, without altering the Roman/Carthaginian/Eastern entries in any way. Is this possible?
    Last edited by Crusader Vanguard; October 02, 2015 at 03:31 PM. Reason: Inform everyone there is a way to do this

  2. #2
    z3n's Avatar State of Mind
    took an arrow to the knee

    Join Date
    Aug 2011
    Posts
    4,640

    Default Re: How to change settlement_min requirement for different cultures

    You create a fake wall entry which only exists to let you do that.
    Redfox has the credit for that idea.
    Check Diadochi Total War for the entry 'magic_wall'.

    There are numerous places however in which that entry has to exist. Good luck and remember notepad++ and the search function are your friend. Check the logical places and also refer to the guide posted by Medusa and the accompanying advice I posted shortly after in regards to other files to check.

    It is a difficult task in which persistence is your best ally. Although the tutorials for adding buildings may help too by krn3ll.
    The AI Workshop Creator
    Europa Barbaroum II AI/Game Mechanics Developer
    The Northern Crusades Lead Developer
    Classical Age Total War Retired Lead Developer
    Rome: Total Realism Animation Developer
    RTW Workshop Assistance MTW2 AI Tutorial & Assistance
    Broken Crescent Submod (M2TW)/IB VGR Submod (BI)/Animation (RTW/BI/ALX)/TATW PCP Submod (M2TW)/TATW DaC Submod (M2TW)/DeI Submod (TWR2)/SS6.4 Northern European UI Mod (M2TW)

  3. #3
    Libertus
    Join Date
    Aug 2015
    Location
    North Carolina, USA
    Posts
    90

    Default Re: How to change settlement_min requirement for different cultures

    I think I finally found the thread you are referring to, z3n. Took me a little while to find. And yes... if what you and Medusa wrote is any indication, the "magic wooden wall" will be hard, if not impossible to implement into Barbarian Invasion. I'm a decent modder, but... I'm not sure if I'm that good. I wish the instructions were a little clearer.

    First off, I believe this is the thread you are referring too, the "DTW Walls Source MAX files" thread? Medusa is post #14 and yours is #16.

    This "modification" will add a lot more than what I asked for. Not that I'm complaining, but I'm asking will it do what I asked? If I'm right, Medusa said so in his instructions with this:

    Quote Originally Posted by Medusa0 View Post
    menu_english.txt for these entries:
    {UI_CUSTOMISE_SETTLEMENT_DEFENSES_LEVEL_2} TALL WOODEN PALLISADE
    {UI_CUSTOMISE_SETTLEMENT_DEFENSES_LEVEL_3} WOODEN WALL (DTW)
    {UI_CUSTOMISE_SETTLEMENT_DEFENSES_LEVEL_4} STONE WALL
    {UI_CUSTOMISE_SETTLEMENT_DEFENSES_LEVEL_5} STONE WALL
    If I understand correctly, that "defenses_level_2" means walls for a large town and therefore "defenses_level_5" means huge city, then I think that would do what I wanted (assuming "tall wooden palisade" isn't as tall as the Barbarian Wooden Wall in the vanilla campaign).

    But won't this change even Roman/Carthaginian/Eastern culture walls to this "magic wall" format? I just want to simply change Barbarian/Nomad/Hun minimum settlement requirements for the wooden wall and stone wall so they go one settlement level higher each, to minor city and large city. This sounds like it will need to completely override the entire wall system (all cultures, or it will cause problems). Can I somehow manage to edit the massive amount of modding here so that it's only necessary for Barbarian/Nomad/Hun cultures? Honestly, I was hoping for an answer a little simpler than this.

    Thanks for replying, z3n. If you could help clear up some of my confusion, I would appreciate it.

  4. #4
    z3n's Avatar State of Mind
    took an arrow to the knee

    Join Date
    Aug 2011
    Posts
    4,640

    Default Re: How to change settlement_min requirement for different cultures

    I honestly doubt it will work myself as Redfox only tricked RTW into reading the fake entry. In fact it had to be that way since there are hardcoded slots for those walls if I remember correctly which may likely mean you can't mod settlement wall levels specifically in that fashion. Only modify existing entries... If it looks too time consuming or difficult I wouldn't bother.

    When I did it I had a personal vendetta against the short palliside type walls because of their UI picture looking completely and utterly different. (more like Redfox's wooden walls). Therefore I had made it my goal to mod them in to match their UI picture.




    What you could try is something like this

    First at the very top add the hidden_resource "none" without quotations
    Code:
    building defenses
    {
        levels wooden_pallisade wooden_wall stone_wall large_stone_wall epic_stone_wall 
        {
            wooden_pallisade requires factions { barbarian, carthaginian, eastern, parthia, egyptian, greek, roman, } 
            {
                capability
                {
                    wall_level 0
                    tower_level 1
                }
                construction  1 
                cost  400 
                settlement_min town
                upgrades
                {
                    wooden_wall
                }
            }
            wooden_wall requires factions { carthaginian, *Nomads?? eastern, parthia,* egyptian, greek, roman, } 
            {
                capability
                {
                    wall_level 1
                    gate_strength 1
                    tower_level 1
                }
                construction  2 
                cost  800 
                settlement_min large_town
                upgrades
                {
    wooden wall 
                }
            }
    wooden_wall requires factions { barbarian, *nomads?? eastern, parthia,* } 
            {
                capability
                {
                    wall_level 1
                    tower_level 1
                    gate_defences 1
                    gate_strength 1
                }
                construction  3 
                cost  1600 
                settlement_min city
                upgrades
                {
    stone_wall
                }
            }
    stone_wall requires factions { carthaginian, eastern, parthia, egyptian, greek, roman, } 
            {
                capability
                {
                    wall_level 3
                    tower_level 1
                    gate_defences 2
                    gate_strength 2
                }
                construction  5 
                cost  3200 
                settlement_min large_city
                upgrades
                {
                    epic_stone_wall
                }
            }
            epic_stone_wall requires factions { carthaginian, eastern, parthia, egyptian, greek, roman, } and hidden_resource none
            {
                capability
                {
                    wall_level 0
                    tower_level 0
                    gate_defences 0
                    gate_strength 0
                }
                construction 0
                cost 0
                settlement_min huge_city
                upgrades
    Now there are no guarentees it will work and also note that the syntax is wrong so change it by hand according to this in your own file along with some guesses as to what you mean by nomads... and it'll probably CTD since I've not modded RTW in ages but there you have it. Don't forget to delete your map.rwm.


    And yes, thats the right post.
    The AI Workshop Creator
    Europa Barbaroum II AI/Game Mechanics Developer
    The Northern Crusades Lead Developer
    Classical Age Total War Retired Lead Developer
    Rome: Total Realism Animation Developer
    RTW Workshop Assistance MTW2 AI Tutorial & Assistance
    Broken Crescent Submod (M2TW)/IB VGR Submod (BI)/Animation (RTW/BI/ALX)/TATW PCP Submod (M2TW)/TATW DaC Submod (M2TW)/DeI Submod (TWR2)/SS6.4 Northern European UI Mod (M2TW)

  5. #5
    Libertus
    Join Date
    Aug 2015
    Location
    North Carolina, USA
    Posts
    90

    Default Re: How to change settlement_min requirement for different cultures

    I'm not going to try Redfox's method. Not only does it seem overly complicated for what I'm asking for, it adds so much and changes far more than I want, and I'm not even completely sure what all it changes... but I know it's more than what I want, and considering everything said about it, I'd be very lucky if it even worked. I'll try something else.

    Now, as for your second suggestion... I have no idea what your code is suppose to do. I apologize, but I don't understand how that coding works.

    This is the simplest I can put it: I want the Barbarian wall called "wooden_wall" to become available to Barbarian factions at the minor city level, instead of the large town level. Same thing for the Barbarian "stone_wall"... I want it to become available at the large city level, not the minor city level like the other cultures. That is it. I do not want to change the Roman, Carthaginian, or Eastern walls in any way.

    And what do I mean by nomads? I mean the nomadic culture available in Barbarian Invasion. I AM NOT modding RTW. I am modding Barbarian Invasion. I want both the Barbarian and Nomadic (which I include the Hun culture in) factions to have a different minimum level settlement for their "wooden_wall" and "stone_wall" defenses than the other cultures.

    Based on what I can see and understand of your coding, it looks designed to make that happen, but it doesn't match the "levels" listing at the beginning of the building chain, the "none" hidden resource doesn't seem to have a purpose that I can see, you seem to have removed all benefits from epic stone walls (which I don't want to do), the "large stone walls" don't exist anymore, and this would change the Roman/Carthaginian/Eastern cultures walls as much as the cultures I want to change. z3n, I don't see how this code works at all.

    I apologize z3n, I just don't see how this coding even works, since the most obvious thing your coding does first is it changes all cultures, not just the ones I want, to have this system. I could be mistaken, but that's what I see.

    Do you believe this could work: I create a new building chain, something like "defenses2", and I only give it 3 levels: "wooden_pallisade", "wooden_wall", and "stone_wall", and I make the minimum level for each of these buildings "town", "minor_city", and "large_city", that way the walls would appear at the city levels I want. But I don't know how to link this "second" wall building chain to the wall files elsewhere in the game. How would the walls appear in campaign battles if I created a new wall chain outside the defenses one? Does that make sense? How do I tie in the new wall building chain into all the other files on walls, like there models, textures, etc, so they will work properly on the campaign map and in campaign battles in Barbarian/Nomad/Hun cultured settlements?

  6. #6
    z3n's Avatar State of Mind
    took an arrow to the knee

    Join Date
    Aug 2011
    Posts
    4,640

    Default Re: How to change settlement_min requirement for different cultures

    A hidden resource none that doesn't exist anywhere will effectively disable the highest level walls which unless I misunderstood is what you wanted in your OP.
    The rest of the code is deliberately designed to allow the cultures you stated to build their walls in the normal cities, while the other cultures you requested to be able to build the specific type of walls you requested can be built at the requested settlement level.

    Reading the code is simple, all you need to understand (which you already do, so I'm not sure why you don't get it yet ) is the min level of settlement which is city.
    And the cultures which can build it, which are barbarian.

    wooden wall
    }
    }
    wooden_wall requires factions { barbarian, nomad }
    {
    capability
    {
    wall_level 1
    tower_level 1
    gate_defences 1
    gate_strength 1
    }
    construction 3
    cost 1600
    settlement_min city
    upgrades

    Basically what I was doing was creating a duplicate entry of wooden_wall solely for barbarian/nomad cultures while the other cultures can still build it at the normal settlement level, and also removing the large/epic stone walls as you requested in your OP.
    The AI Workshop Creator
    Europa Barbaroum II AI/Game Mechanics Developer
    The Northern Crusades Lead Developer
    Classical Age Total War Retired Lead Developer
    Rome: Total Realism Animation Developer
    RTW Workshop Assistance MTW2 AI Tutorial & Assistance
    Broken Crescent Submod (M2TW)/IB VGR Submod (BI)/Animation (RTW/BI/ALX)/TATW PCP Submod (M2TW)/TATW DaC Submod (M2TW)/DeI Submod (TWR2)/SS6.4 Northern European UI Mod (M2TW)

  7. #7
    Libertus
    Join Date
    Aug 2015
    Location
    North Carolina, USA
    Posts
    90

    Default Re: How to change settlement_min requirement for different cultures

    Okay, z3n, I think I'm getting a clearer picture. You're coding was a little hard to follow, but you're right, the important part is the "settlement_min" stat. I'm still a little uncertain, but... I THINK you mean something like this:

    This is a copy of the "defenses" building chain that... I think... is what you are trying to get me to build. Will this coding function properly if I implement it in BI? I bolded important segments:

    Code:
    building defenses
    {
        levels wooden_pallisade wooden_wall stone_wall large_stone_wall epic_stone_wall 
        {
            wooden_pallisade requires factions { barbarian, carthaginian, eastern, hun, nomad, roman, } 
            {
                capability
                {
                    wall_level 0
                    tower_level 1
                    happiness_bonus bonus 2
                }
                construction  1 
                cost  400 
                settlement_min town
                upgrades
                {
                    wooden_wall
                }
            }
            wooden_wall requires factions { carthaginian, eastern, roman, } 
            {
                capability
                {
                    wall_level 1
                    gate_strength 1
                    tower_level 1
                    happiness_bonus bonus 4
                }
                construction  2 
                cost  800 
                settlement_min large_town
                upgrades
                {
                    stone_wall
                }
            }
             wooden_wall requires factions { barbarian, hun, nomad, } 
            {
                capability
                {
                    wall_level 1
                    gate_strength 1
                    tower_level 1
                    happiness_bonus bonus 4
                }
                construction  2 
                cost  800 
                settlement_min city
                upgrades
                {
                    stone_wall
                }
            }
            stone_wall requires factions { carthaginian, eastern, roman, } 
            {
                capability
                {
                    wall_level 2
                    tower_level 1
                    gate_defences 1
                    gate_strength 1
                    happiness_bonus bonus 6
                    law_bonus bonus 2
                }
                construction  3 
                cost  1600 
                settlement_min city
                upgrades
                {
                    large_stone_wall
                }
            }
            stone_wall requires factions { barbarian, hun, nomad, } 
            {
                capability
                {
                    wall_level 2
                    tower_level 1
                    gate_defences 1
                    gate_strength 1
                    happiness_bonus bonus 6
                    law_bonus bonus 2
                }
                construction  3 
                cost  1600 
                settlement_min large_city
                upgrades
                {
                }
            large_stone_wall requires factions { eastern, roman, carthaginian, } 
            {
                capability
                {
                    wall_level 3
                    tower_level 1
                    gate_defences 2
                    gate_strength 2
                    happiness_bonus bonus 8
                    law_bonus bonus 4
                }
                construction  5 
                cost  3200 
                settlement_min large_city
                upgrades
                {
                    epic_stone_wall
                }
            }
            epic_stone_wall requires factions { eastern, roman, carthaginian, } 
            {
                capability
                {
                    wall_level 4
                    tower_level 2
                    gate_defences 2
                    gate_strength 2
                    happiness_bonus bonus 10
                    law_bonus bonus 6
                }
                construction  6 
                cost  6400 
                settlement_min huge_city
                upgrades
                {
                }
            }
        }
        plugins 
        {
        }
    }
    Okay, in the above code, "wooden_pallisade" is the same for all cultures (note all 6 BI cultures can build it), same settlement minimum level.

    Then I created two "wooden_wall" entries (I'm assuming based on what you have said, this is acceptable coding). They both have the same internal name, the same bonuses, defenses, and both upgrade to a "stone_wall"... however, the Carthaginian/Eastern/Roman "wooden_wall" is set for "settlement_min" "large_town", while the Barbarian/Hun/Nomad one is set for "settlement_min" "city". If the double-entry is "acceptable" coding for the game, that would work perfectly.

    Same thing for the "stone_wall" entry. There are two: one for the Carthaginian/Eastern/Roman cultures and the other for Barbarian/Hun/Nomad cultures; the only difference between the two being that the first list of cultures have "stone_wall" at "city" level, while the latter get it at the "large city" level. Also, I deleted the "large_stone_wall" upgrade from the Barbarian/Hun/Nomad version of "stone_wall", so they shouldn't be able to upgrade even if they got a large stone wall.

    Also, the "large_stone_wall" and "epic_stone_wall" entries don't list Barbarian/Hun/Nomad cultures, so they can't get them anyway. I don't see the need for the "none" hidden resource.

    Will this coding work in-game, z3n?

  8. #8
    z3n's Avatar State of Mind
    took an arrow to the knee

    Join Date
    Aug 2011
    Posts
    4,640

    Default Re: How to change settlement_min requirement for different cultures

    epic_stone_wall will not let the siege towers reach their walls its an unfortunate bug. I am not entirely sure whether large stone walls have the same one but presumably they don't. In any case, it might not work because there are now 6 entries for walls instead of 1.

    You may likely end up having to move large stone wall up one slot into the huge, while removing this levels wooden_pallisade wooden_wall stone_wall large_stone_wall epic_stone_wall Then, move stone wall into the large stone wall slot and leave the rest where they were before.


    Anotherwords something like this.

    Code:
    building defenses
    {
        levels wooden_pallisade wooden_wall stone_wall large_stone_wall  
        {
            wooden_pallisade requires factions { barbarian, carthaginian, eastern, hun, nomad, roman, } 
            {
                capability
                {
                    wall_level 0
                    tower_level 1
                    happiness_bonus bonus 2
                }
                construction  1 
                cost  400 
                settlement_min town
                upgrades
                {
                    wooden_wall
                }
            }
            wooden_wall requires factions { carthaginian, eastern, roman, } 
            {
                capability
                {
                    wall_level 1
                    gate_strength 1
                    tower_level 1
                    happiness_bonus bonus 4
                }
                construction  2 
                cost  800 
                settlement_min large_town
                upgrades
                {
                    stone_wall
                }
            }
             wooden_wall requires factions { barbarian, hun, nomad, } 
            {
                capability
                {
                    wall_level 1
                    gate_strength 1
                    tower_level 1
                    happiness_bonus bonus 4
                }
                construction  2 
                cost  800 
                settlement_min city
                upgrades
                {
                    stone_wall
                }
            }
            stone_wall requires factions { carthaginian, eastern, roman, } 
            {
                capability
                {
                    wall_level 2
                    tower_level 1
                    gate_defences 1
                    gate_strength 1
                    happiness_bonus bonus 6
                    law_bonus bonus 2
                }
                construction  3 
                cost  1600 
                settlement_min city
                upgrades
                {
                    large_stone_wall
                }
            }
            stone_wall requires factions { barbarian, hun, nomad, } 
            {
                capability
                {
                    wall_level 2
                    tower_level 1
                    gate_defences 1
                    gate_strength 1
                    happiness_bonus bonus 6
                    law_bonus bonus 2
                }
                construction  3 
                cost  1600 
                settlement_min large_city
                upgrades
                {
                }
            large_stone_wall requires factions { eastern, roman, carthaginian, } 
            {
                capability
                {
                    wall_level 3
                    tower_level 1
                    gate_defences 2
                    gate_strength 2
                    happiness_bonus bonus 8
                    law_bonus bonus 4
                }
                construction  5 
                cost  3200 
                settlement_min large_city
                upgrades
                {
                }
            }
        }
        plugins 
        {
        }
    }
    However the only way to know for sure is start up the game and see if it crashes or not. If it doesn't then it should work, anyway then go into a custom battle and select the settlement/faction type which would have the wooden walls and see for yourself. I can't give you any guarantee as I'm simply helping you concept the idea, not testing it for you.
    The AI Workshop Creator
    Europa Barbaroum II AI/Game Mechanics Developer
    The Northern Crusades Lead Developer
    Classical Age Total War Retired Lead Developer
    Rome: Total Realism Animation Developer
    RTW Workshop Assistance MTW2 AI Tutorial & Assistance
    Broken Crescent Submod (M2TW)/IB VGR Submod (BI)/Animation (RTW/BI/ALX)/TATW PCP Submod (M2TW)/TATW DaC Submod (M2TW)/DeI Submod (TWR2)/SS6.4 Northern European UI Mod (M2TW)

  9. #9
    Libertus
    Join Date
    Aug 2015
    Location
    North Carolina, USA
    Posts
    90

    Default Re: How to change settlement_min requirement for different cultures

    Quote Originally Posted by z3n View Post
    epic_stone_wall will not let the siege towers reach their walls its an unfortunate bug. I am not entirely sure whether large stone walls have the same one but presumably they don't.
    I play battles every once in a while (not nearly as much as I play campaigns), but I rarely do siege battles. AI is annoying and it's often very hard to get the units to actually do what you ask. I know that siege towers don't work, but other equipment does. Adds to the challenge. So, that's fine, and I don't wish to delete epic stone walls.

    Quote Originally Posted by z3n View Post
    In any case, it might not work because there are now 6 entries for walls instead of 1. You may likely end up having to move large stone wall up one slot into the huge, while removing this levels wooden_pallisade wooden_wall stone_wall large_stone_wall epic_stone_wall Then, move stone wall into the large stone wall slot and leave the rest where they were before.
    So, you mean because I have more than 5 "walls" listed, it won't work, because there are only 5 wall levels listed? Then even your modified code with the epic stone walls cut out won't work because there are 2 wooden wall entries and 2 stone wall entries. Add that with the large stone wall and wooden palisade, you got 6 entries for 5 levels. I had 7 entries for 5 levels. Both won't work if there is a max on one entry per level listed in the levels column.

    I think the ultimate question boils down to this: will the game allow a building chain (defenses) to have only 5 levels (the one's listed in the column "levels": wooden_pallisade wooden_wall stone_wall large_stone_wall epic_stone_wall) but have 7 "entries" in the main section (the individual entries controlling each "level". For my plan it was: wooden_pallisade wooden_wall wooden_wall stone_wall stone_wall large_stone_wall epic_stone_wall). Will this work correctly in-game? Is this sound coding?

    Quote Originally Posted by z3n View Post
    However the only way to know for sure is start up the game and see if it crashes or not. If it doesn't then it should work, anyway then go into a custom battle and select the settlement/faction type which would have the wooden walls and see for yourself. I can't give you any guarantee as I'm simply helping you concept the idea, not testing it for you.
    I understand that you're not going to test it for me. I didn't expect you to... however:

    I'm asking about this "concept" idea while I'm transferring a new culture into my mod (amazon). I'm currently stumped on an error in my "descr_settlement_plan.txt" where it "failed to find plan id Greek_Town" for the Amazonian plan levels. Until I figure out what caused this error... I cannot start the game. So unless you know how I can fixed this error, I might be a while starting my game to test our theory.

    Maybe I will go into my "backups" and pull out my original BI and try it there...

    Thanks for your help, z3n.

  10. #10
    z3n's Avatar State of Mind
    took an arrow to the knee

    Join Date
    Aug 2011
    Posts
    4,640

    Default Re: How to change settlement_min requirement for different cultures

    Then even your modified code with the epic stone walls cut out won't work because there are 2 wooden wall entries and 2 stone wall entries.
    In mine there was only one stone wall not two.
    The AI Workshop Creator
    Europa Barbaroum II AI/Game Mechanics Developer
    The Northern Crusades Lead Developer
    Classical Age Total War Retired Lead Developer
    Rome: Total Realism Animation Developer
    RTW Workshop Assistance MTW2 AI Tutorial & Assistance
    Broken Crescent Submod (M2TW)/IB VGR Submod (BI)/Animation (RTW/BI/ALX)/TATW PCP Submod (M2TW)/TATW DaC Submod (M2TW)/DeI Submod (TWR2)/SS6.4 Northern European UI Mod (M2TW)

  11. #11

    Default Re: How to change settlement_min requirement for different cultures

    Adding extra wall levels in-between the 'default' ones is tricky, because it affects a lot of things and can cause some coding headaches. No need to go down that road.

    Do this instead:

    Code:
    building defenses
    {
        levels wooden_pallisade wooden_wall stone_wall large_stone_wall epic_stone_wall 
        {
            wooden_pallisade requires factions { barbarian, carthaginian, eastern, egyptian, greek, roman, nomad, } 
            {
                capability
                {
                    wall_level 0
                    tower_level 1
                }
                construction  1 
                cost  400 
                settlement_min town
                upgrades
                {
                    wooden_wall requires factions { carthaginian, eastern, egyptian, greek, roman, }
                    wooden_wall requires factions { barbarian, nomad, } and building_present_min_level core_building governors_palace
                }
            }
            wooden_wall requires factions { barbarian, carthaginian, eastern, egyptian, greek, roman, nomad, } 
            {
                capability
                {
                    wall_level 1
                    gate_strength 1
                    tower_level 1
                }
                construction  2 
                cost  800 
                settlement_min large_town
                upgrades
                {
                    stone_wall requires factions { carthaginian, eastern, egyptian, greek, roman, }
                    stone_wall requires factions { barbarian, nomad, } and building_present_min_level core_building proconsuls_palace
                }
            }
            stone_wall requires factions { carthaginian, eastern, egyptian, greek, roman, barbarian, nomad, } 
            {
                capability
                {
                    wall_level 2
                    tower_level 1
                    gate_defences 1
                    gate_strength 1
                }
                construction  3 
                cost  1600 
                settlement_min city
                upgrades
                {
                    large_stone_wall
                }
            }
        [...]
        }
        plugins 
        {
        }
    }
    Last edited by Aradan; September 13, 2015 at 04:52 AM.

  12. #12
    Libertus
    Join Date
    Aug 2015
    Location
    North Carolina, USA
    Posts
    90

    Default Re: How to change settlement_min requirement for different cultures

    Quote Originally Posted by z3n View Post
    In mine there was only one stone wall not two.
    z3n, I'm sorry, but I see two "stone_wall" entries listed inside your coding you posted (#8). You have 6 entries I can see: wooden_pallisade, wooden_wall, wooden_wall, stone_wall, stone_wall, large_stone_wall.

    Quote Originally Posted by Aradan View Post
    Adding extra wall levels in-between the 'default' ones is tricky, because it affects a lot of things and can cause some coding headaches. No need to go down that road.

    Do this instead:

    Code:
    building defenses
    {
        levels wooden_pallisade wooden_wall stone_wall large_stone_wall epic_stone_wall 
        {
            wooden_pallisade requires factions { barbarian, carthaginian, eastern, egyptian, greek, roman, nomad, } 
            {
                capability
                {
                    wall_level 0
                    tower_level 1
                }
                construction  1 
                cost  400 
                settlement_min town
                upgrades
                {
                    wooden_wall requires factions { carthaginian, eastern, egyptian, greek, roman, }
                    wooden_wall requires factions { barbarian, nomad, } and building_present_min_level core_building governors_palace
                }
            }
            wooden_wall requires factions { barbarian, carthaginian, eastern, egyptian, greek, roman, nomad, } 
            {
                capability
                {
                    wall_level 1
                    gate_strength 1
                    tower_level 1
                }
                construction  2 
                cost  800 
                settlement_min large_town
                upgrades
                {
                    stone_wall requires factions { carthaginian, eastern, egyptian, greek, roman, }
                    stone_wall requires factions { barbarian, nomad, } and building_present_min_level core_building proconsuls_palace
                }
            }
            stone_wall requires factions { carthaginian, eastern, egyptian, greek, roman, barbarian, nomad, } 
            {
                capability
                {
                    wall_level 2
                    tower_level 1
                    gate_defences 1
                    gate_strength 1
                }
                construction  3 
                cost  1600 
                settlement_min city
                upgrades
                {
                    large_stone_wall
                }
            }
        [...]
        }
        plugins 
        {
        }
    }
    Thank you Aradan for jumping in and helping. I appreciate it. You're method does make more sense, and would allow me to use only 5 entries and keep my epic_stone_wall entry. Thank you.
    Last edited by Crusader Vanguard; September 21, 2015 at 12:18 PM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •