Edit Game Difficulties?

Tokata_RuNeLess

Chieftain
Joined
Sep 17, 2015
Messages
39
Location
USTC in Hefei, China
It seemed that TRAITS_DIFFICULTIES_... are hard-coded in the game dll file if I didn't make mistake. I checked the whole Assets folder and just couldn't find a way to directly edit game difficulties. Obviously there can be alternative ways to do this but I think its better to know the specific data of each difficulty. Besides I'm trying to edit the game rule using script code (lua, yeah) as little as possible so its not an ideal way to solve it.

BTW it seems that they love using traits in CIV6.
 
Yeah, made the same observation. Other stuff also leads to Traits, including Leader Agendas, and that seems to be a dead end.

I hope I'm missing something, because that sort of hard-coding is going to be really crippling to everyday modders.
 
There's this stuff in leaders.xml , you can edit this obviously, but i think just having this in here suggests you can't edit difficulties individually.


Spoiler :

<Row>
<ModifierId>HIGH_DIFFICULTY_SCIENCE_SCALING</ModifierId>
<Name>Amount</Name>
<Type>LinearScaleFromDefaultHandicap</Type>
<Value>0</Value>
<Extra>8</Extra>
</Row>
<Row>
<ModifierId>HIGH_DIFFICULTY_SCIENCE_SCALING</ModifierId>
<Name>YieldType</Name>
<Value>YIELD_SCIENCE</Value>
</Row>
<Row>
<ModifierId>HIGH_DIFFICULTY_CULTURE_SCALING</ModifierId>
<Name>Amount</Name>
<Type>LinearScaleFromDefaultHandicap</Type>
<Value>0</Value>
<Extra>8</Extra>
</Row>
<Row>
<ModifierId>HIGH_DIFFICULTY_CULTURE_SCALING</ModifierId>
<Name>YieldType</Name>
<Value>YIELD_CULTURE</Value>
</Row>
<Row>
<ModifierId>HIGH_DIFFICULTY_PRODUCTION_SCALING</ModifierId>
<Name>Amount</Name>
<Type>LinearScaleFromDefaultHandicap</Type>
<Value>0</Value>
<Extra>20</Extra>
</Row>
<Row>
<ModifierId>HIGH_DIFFICULTY_PRODUCTION_SCALING</ModifierId>
<Name>YieldType</Name>
<Value>YIELD_PRODUCTION</Value>
</Row>
<Row>
<ModifierId>HIGH_DIFFICULTY_GOLD_SCALING</ModifierId>
<Name>Amount</Name>
<Type>LinearScaleFromDefaultHandicap</Type>
<Value>0</Value>
<Extra>20</Extra>
</Row>
<Row>
<ModifierId>HIGH_DIFFICULTY_GOLD_SCALING</ModifierId>
<Name>YieldType</Name>
<Value>YIELD_GOLD</Value>
</Row>
<Row>
<ModifierId>HIGH_DIFFICULTY_FAITH_SCALING</ModifierId>
<Name>Amount</Name>
<Type>LinearScaleFromDefaultHandicap</Type>
<Value>0</Value>
<Extra>8</Extra>
</Row>
<Row>
<ModifierId>HIGH_DIFFICULTY_FAITH_SCALING</ModifierId>
<Name>YieldType</Name>
<Value>YIELD_FAITH</Value>
</Row>
<Row>
<ModifierId>BARBARIAN_CAMP_GOLD_SCALING</ModifierId>
<Name>Amount</Name>
<Type>LinearScaleFromDefaultHandicap</Type>
<Value>0</Value>
<Extra>-5</Extra>
</Row>
<Row>
<ModifierId>BARBARIAN_CAMP_GOLD_SCALING</ModifierId>
<Name>Improvement</Name>
<Value>IMPROVEMENT_BARBARIAN_CAMP</Value>
</Row>
<Row>
<ModifierId>HIGH_DIFFICULTY_COMBAT_SCALING</ModifierId>
<Name>Amount</Name>
<Type>LinearScaleFromDefaultHandicap</Type>
<Value>-1</Value>
<Extra>1</Extra>
</Row>
<Row>
<ModifierId>LOW_DIFFICULTY_COMBAT_SCALING</ModifierId>
<Name>Amount</Name>
<Type>LinearScaleFromDefaultHandicap</Type>
<Value>0</Value>
<Extra>-1</Extra>
</Row>
<Row>
<ModifierId>HIGH_DIFFICULTY_UNIT_XP_SCALING</ModifierId>
<Name>Amount</Name>
<Type>LinearScaleFromDefaultHandicap</Type>
<Value>0</Value>
<Extra>10</Extra>
</Row>
<Row>
<ModifierId>LOW_DIFFICULTY_UNIT_XP_SCALING</ModifierId>
<Name>Amount</Name>
<Type>LinearScaleFromDefaultHandicap</Type>
<Value>0</Value>
<Extra>-15</Extra>
</Row>
<Row>
<ModifierId>HIGH_DIFFICULTY_FREE_TECH_BOOSTS</ModifierId>
<Name>Amount</Name>
<Type>LinearScaleFromDefaultHandicap</Type>
<Value>0</Value>
<Extra>1</Extra>
</Row>
<Row>
<ModifierId>HIGH_DIFFICULTY_FREE_TECH_BOOSTS</ModifierId>
<Name>ApplyImmediately</Name>
<Value>true</Value>
</Row>
<Row>
<ModifierId>HIGH_DIFFICULTY_FREE_CIVIC_BOOSTS</ModifierId>
<Name>Amount</Name>
<Type>LinearScaleFromDefaultHandicap</Type>
<Value>0</Value>
<Extra>1</Extra>
</Row>
<Row>
<ModifierId>HIGH_DIFFICULTY_FREE_CIVIC_BOOSTS</ModifierId>
<Name>ApplyImmediately</Name>
<Value>true</Value>
</Row>
 
Yeah, nevermind. Not sure how I missed those tables. ^^

That difficulty scaling is pretty silly. But I guess just adding dummy buildings/perks via lua will do the job if it has to.
 
There's this stuff in leaders.xml , you can edit this obviously, but i think just having this in here suggests you can't edit difficulties individually.

I'm not sure which one were you replied to, me or Ryika. Makes me kinda nervous yeah.

However seemed they also have the following code in Leaders.xml

Spoiler :

<Row>
<RequirementId>REQUIRES_HIGH_DIFFICULTY</RequirementId>
<Name>Handicap</Name>
<Value>DIFFICULTY_PRINCE</Value>
</Row>
<Row>
<RequirementId>REQUIRES_LOW_DIFFICULTY</RequirementId>
<Name>Handicap</Name>
<Value>DIFFICULTY_WARLORD</Value>
</Row>


So I guess that any level higher than prince are just all the same. ←which is obviously impossible.
... or there must be something else related to the 8 different in-game difficulty levels, which is not here in Leaders.xml.
I just hope that Difficulties.xml is not a useless decoration, though it seemed so.
 
So I guess that any level higher than prince are just all the same. ←which is obviously impossible.
... or there must be something else related to the 8 different in-game difficulty levels, which is not here in Leaders.xml.
I just hope that Difficulties.xml is not a useless decoration, though it seemed so.



Well the way those values I posted appear to work is that they apply to all difficulty levels simultaenously at different numbers.

For instance:

<Row>
<ModifierId>HIGH_DIFFICULTY_FREE_CIVIC_BOOSTS</ModifierId>
<Name>Amount</Name>
<Type>LinearScaleFromDefaultHandicap</Type>
<Value>0</Value>
<Extra>1</Extra>
</Row>

This should give 0 civics at the default difficulty, which is probably prince. Then on King, they get 1 civic, on Emperor they get 2, On Deity 3. With some of these, negative values may also be given to the lower difficulties (doesn't make sense for civics of course).
The value 'Value' should determine what they get at the middle point, the 'extra' determines what gets added/removed per step.
 
Still missing the values for starting units. Would realy like to have a boosted AI without a second settler as this can get realy out of hand at marathon speed.
 
Back
Top Bottom