Natural Wonder selector defaulting

__jack__

Warlord
Joined
Dec 29, 2009
Messages
141
Probably this one is for @LeeS

In the August patch we now have a natural wonder selector.

That's driven by the ConfigurationId "EXCLUDE_NATURAL_WONDERS", and we now have a setupparameters able to pass on array.

So GameConfiguration.GetValue("EXCLUDE_NATURAL_WONDERS") returns an array listing the excluded wonder e.g. GameConfiguration.GetValue("EXCLUDE_NATURAL_WONDERS")[1] is "FEATURE_BARRIER_REEF"

Which now point to my question: how can we change the default value of "EXCLUDE_NATURAL_WONDERS" from the XML side ?

e.g. in my Config.xml

<Row Key1="Ruleset" Key2="RULESET_STANDARD" ParameterId="NaturalWonders" Name="LOC_EXCLUDE_NATURAL_WONDER_NAME" Description="LOC_EXCLUDE_NATURAL_WONDER_DESC" Domain="StandardNaturalWonders" Hash="0" Array="1" ConfigurationGroup="Game" ConfigurationId="EXCLUDE_NATURAL_WONDERS" GroupId="MapOptions" UxHint="InvertSelection" SortIndex="230"/>

How can I put a DefaultValue = XXX where XXX would be an array ? Normally it is text or number, any syntax to pass an array in that?

Thanks !
 
The only way it might be done is the same way essentially an array is passed as argument data in ModifierArguments and RequirementArguments. ie:
Code:
Value="YIELD_GOLD,YIELD_FOOD,YIELD_FAITH"
But whether or not the game will implement such a thing for the FrontEnd Parameters table and its "Default" column or not (or whether it will just CTD) is something you would just have to try.

My suspicion is that it will not work. But :dunno:


Caching issues might also apply when trying this as a FrontEnd UpdateDatabase action. An Update or Replace statement might not work until you load the game once, make sure the mod is enabled, then exit to desktop before restarting the game from scratch with the mod already enabled. And you have to ensure your alteration to the table is being applied to the Ruleset for the Expansion you are running. There are three rows in table Parameters which have settings for the EXCLUDE_NATURAL_WONDERS parameter: one for each of the three main rulesets.
 
Last edited:
Top Bottom