1. We have added a Gift Upgrades feature that allows you to gift an account upgrade to another member, just in time for the holiday season. You can see the gift option when going to the Account Upgrades screen, or on any user profile screen.
    Dismiss Notice

Modify Terrain / Resources Pantheons are Applied To?

Discussion in 'Civ6 - Creation & Customization' started by Bleser, Apr 21, 2019.

  1. Bleser

    Bleser Prince

    Joined:
    Jun 23, 2002
    Messages:
    442
    Location:
    USA
    Hello,

    I've been poking around in the database to see how to modify some of the Pantheon parameters but have gotten stuck after I get over to the Modifiers table.

    Basically, for the 'Lady of the Reeds' Pantheon, I want to make the bonus apply to ALL floodplains, not just desert floodplains, but I can't seem to find where the game defines which tiles a Pantheon affects. I see how I would change the yield_type and yield_value, but not the terrain or terrain features impacted.

    I think I'm just missing the link or table name - anyone have a clue?

    Thanks in advance!
     
  2. Laurana Kanan

    Laurana Kanan Don’t underestimate who I am.

    Joined:
    Apr 10, 2014
    Messages:
    1,977
    Gender:
    Female
    Location:
    Near the Greatest Snow on Earth
    Bleser likes this.
  3. Bleser

    Bleser Prince

    Joined:
    Jun 23, 2002
    Messages:
    442
    Location:
    USA
    Great, thanks! I'll subscribe and see how it was done. Appreciate the link!
     
  4. isau

    isau Deity

    Joined:
    Jan 15, 2007
    Messages:
    3,052
    So, with Pantheons and any other religious belief, you're dealing with a situation that may be a little hard to picture. The way it basically works on a conceptual level is this:

    Most Beliefs operate at a global level for the game map. This means when any belief is selected, it is applied to the entire "game world" as a top level global effect. Then, by relying on RequirementSets, the game determines which cities to apply the Modifier to.

    For example, when a player chooses Lady of the Reeds and Marshes, the operation works like this:
    1. A Modifier (derived from the BeliefModifiers table) for Lady and Reeds and Marshes is added to the stack of Beliefs operating in the game world
    2. Lady of the Reeds and Marshes effects are turned on whenever a city acquires this belief. Since LotR&M is a belief that operates on cities, the game looks at each city to see if the effect should go into effect for that city.


    Getting More Technical
    Many (not all) of the Beliefs in game use one of these two Modifiers:
    • MODIFIER_ALL_PLAYERS_ATTACH_MODIFIER
    • MODIFIER_ALL_CITIES_ATTACH_MODIFIER

    Lady of Reeds and Marshes, like most Beliefs that change the way a city that follows a belief works, uses MODIFIER_ALL_CITIES_ATTACH_MODIFIER.

    ALL literally means all--every single one in the game. If there were no RequirementSet specified every single city in game would get the effects. However, since the Belief needs to be limited t cities following this Pantheon, the CITY_FOLLOWS_PANTHEON_REQUIREMENTS RequirementSet is specified.



    Note that MODIFIER_ALL_CITIES_ATTACH_MODIFIER is a "broadcast" Modifier--it doesn't actually do anything on its own than pass along another Modifier to cities it should apply to. It's the Modifier that is being broadcast where you will find the RequirementSet that determines whether a given tile meets the requirements of LotR&M.

    Firaxis didn't IMO use the most helpful names in naming these two Modifiers:

    • LADY_OF_THE_REEDS_PRODUCTION - the Global modifier
    • LADY_OF_THE_REEDS_PRODUCTION_MODIFIER - the Modifier being broadcast to each city that actually adds the production

    LADY_OF_THE_REEDS_PRODUCTION_MODIFIER has a RequirementSet called PLOT_HAS_REEDS_REQUIREMENTS that determines whether a given plot meets requirements.



    Some SQL Code that May be Helpful
    You can "deep dive" into Beliefs with this codeplugged into a SQL database tool:

    Code:
    select * from beliefmodifiers
    left join modifiers using (modifierid)
    left join modifierarguments using (modifierid)
    left join modifiers as m2 on m2.ModifierId = modifierarguments.Value
    left join modifierarguments as ma2 on ma2.modifierid = m2.modifierid
    This code will display the modifiers directly attached to the BeliefModifier, and, if there is a secondary Modifier that is being broadcast, load that and its ModifierArguments as well.

    Here it is SQLite Studio:
    upload_2019-4-21_13-31-39.png



    To fix your specific issue, you want to update PLOT_HAS_REEDS_REQUIREMENTS. When Firaxis added the 2 new types of Floodplains they kept the original ones and just added two new features,onefor Plains and one for Grass. If you add those as Requirements to the PLOT_HAS_REEDS_REQUIREMENTS set, it should work. Examples of what needs to be included are in the screenshot below, showing how that requirementset is implemented for Marsh, Oasis, and Desert Floodplains (and also Rise and Wheat, since I had added those in via a mod).

    upload_2019-4-21_13-35-38.png
     
    Bleser likes this.
  5. Bleser

    Bleser Prince

    Joined:
    Jun 23, 2002
    Messages:
    442
    Location:
    USA
    @isau - fantastic - thank you!
     

Share This Page