How to set and use the regional resources placement

Gedemon

Modder
Super Moderator
Joined
Oct 4, 2004
Messages
11,581
Location
France
Here is an example for the GiantEarth:
Code:
     <RegionPosition>
          <Replace MapName="GiantEarth" Region="GROENLAND" X="157" Y="81" Width="22" Height="12" />
     </RegionPosition>
X,Y are the coordinate of the bottom-left plot of a "rectangle" of 22 plots width and 12 plots height.

For all regions currently used for resource exclusion/inclusion and real world deposit, see:
https://github.com/Gedemon/Civ6-YnAMP/blob/master/Maps/GiantEarth/Map.xml
and
https://github.com/Gedemon/Civ6-YnAMP/blob/master/Gameplay/Resource.xml

Now the option is deactivated for map not set for it, for example with the Huge map, to activate it after setting some regions, open Config.xml in the YnAMP - Huge Earth folder wit a text editor, find:
Code:
    <Parameters>
        <!--    HugeEarth Options
        <Row Key1="Map" Key2="HugeEarth.lua" ParameterId="ResourcesExclusion" Name="LOC_MAP_RESOURCES_PLACEMENT_EXCLUDE_NAME" Description="LOC_MAP_RESOURCES_PLACEMENT_EXCLUDE_DESCRIPTION" Domain="ResourcesExclusion" DefaultValue="PLACEMENT_EXCLUDE" ConfigurationGroup="Map" ConfigurationId="ResourcesExclusion" GroupId="MapOptions" SortIndex="275"/>
        <Row Key1="Map" Key2="HugeEarth.lua" ParameterId="RealDeposits" Name="LOC_MAP_RESOURCES_PLACEMENT_RWDEPOSIT_NAME" Description="LOC_MAP_RESOURCES_PLACEMENT_RWDEPOSIT_DESCRIPTION" Domain="RealDeposits" DefaultValue="PLACEMENT_DEPOSIT" ConfigurationGroup="Map" ConfigurationId="RealDeposits" GroupId="MapOptions" SortIndex="277"/>

        -->

and move the line of the option you want to activate below the line with "-->", for example to activate just exlusion/exclusive placement:

Code:
    <Parameters>
        <!--    HugeEarth Options
        <Row Key1="Map" Key2="HugeEarth.lua" ParameterId="RealDeposits" Name="LOC_MAP_RESOURCES_PLACEMENT_RWDEPOSIT_NAME" Description="LOC_MAP_RESOURCES_PLACEMENT_RWDEPOSIT_DESCRIPTION" Domain="RealDeposits" DefaultValue="PLACEMENT_DEPOSIT" ConfigurationGroup="Map" ConfigurationId="RealDeposits" GroupId="MapOptions" SortIndex="277"/>

        -->
        <Row Key1="Map" Key2="HugeEarth.lua" ParameterId="ResourcesExclusion" Name="LOC_MAP_RESOURCES_PLACEMENT_EXCLUDE_NAME" Description="LOC_MAP_RESOURCES_PLACEMENT_EXCLUDE_DESCRIPTION" Domain="ResourcesExclusion" DefaultValue="PLACEMENT_EXCLUDE" ConfigurationGroup="Map" ConfigurationId="ResourcesExclusion" GroupId="MapOptions" SortIndex="275"/>

the line with ParameterId="ResourcesExclusion" is used for exclusion/exclusive placement of resource as defined in the Resource.xml file in the base mod (<ResourceRegionExclude> and <ResourceRegionExclusive> tables).

the line with ParameterId="RealDeposits" is currently used to place Oil and Coal in specific regions (also defined in the Resource.xml file, the <ResourceRegionDeposit> table)

the difference between <ResourceRegionExclusive> and <ResourceRegionDeposit> tables is that a resource in the first table will be found only in the regions defined while in the second table they can also be placed in other regions by the game's.

For some map the option is not even disabled and the line must be added, between <Parameters> and </Parameters>, for example:

Code:
    <Parameters>
       
        <Row Key1="Map" Key2="HugeEarth.lua" ParameterId="RealDeposits" Name="LOC_MAP_RESOURCES_PLACEMENT_RWDEPOSIT_NAME" Description="LOC_MAP_RESOURCES_PLACEMENT_RWDEPOSIT_DESCRIPTION" Domain="RealDeposits" DefaultValue="PLACEMENT_DEPOSIT" ConfigurationGroup="Map" ConfigurationId="RealDeposits" GroupId="MapOptions" SortIndex="277"/>
        <Row Key1="Map" Key2="HugeEarth.lua" ParameterId="ResourcesExclusion" Name="LOC_MAP_RESOURCES_PLACEMENT_EXCLUDE_NAME" Description="LOC_MAP_RESOURCES_PLACEMENT_EXCLUDE_DESCRIPTION" Domain="ResourcesExclusion" DefaultValue="PLACEMENT_EXCLUDE" ConfigurationGroup="Map" ConfigurationId="ResourcesExclusion" GroupId="MapOptions" SortIndex="275"/>

    </Parameters>

The Key2 entry must be changed by the name of the map script file, you'll find it in the corresponding map's folder, for example LargestEarth.lua, PlayEuropeAgain.lua, etc...
 
Last edited:
Top Bottom