eXecator Posted February 22, 2016 Share Posted February 22, 2016 Hi there, I'm currently a bit confused trying to use the config( . ) specifier for array members. I'm trying to replicate this: // XGGameData.uc struct native InclusionExclusionList { [...] } // XComTacticalMissionManager.uc class XComTacticalMissionManager extends Object [...] config(Missions); var const config array<InclusionExclusionList> InclusionExclusionLists; // DefaultMIssions.ini [XComGame.XComTacticalMissionManager] InclusionExclusionLists=(ListID="Open", [...]) InclusionExclusionLists=(ListID="NoBosses", [...]) So the XComTacticalMissionManager's InclusionExclusionLists memeber gets initialized via DefaultMissions.ini. To me the ini-lines look a little weird, like they are resetting InclusionExclusionLists instead of adding to it. But it works fine, so who cares about syntax... However if I try this myself with something like this // Foo.uc class Foo config(Foo); var const config array<Bar> Bars; // XComFoo.ini [FooMod.Foo] Bars = ([...]) Bars = ([...]) I'll end up with only 1 single, lonely Bar in my Bars. It will work though with those lines: Bars[0]=([...]) Bars[1]=([...])What am I missing here? Is it because of native behaviour of the TacticalManager or InclusionExclusionList? Is it because DefaultStuff.ini gets handled different from XComStuff.ini? Did I screw up somewhere and this should work? Link to comment Share on other sites More sharing options...
Lucubration Posted February 23, 2016 Share Posted February 23, 2016 I think I ran into something like this while trying to add a custom perk tree. Instead of writing this: SoldierRanks=( [...] ) SoldierRanks=( [...] ) I had to prefix each line with '+': +SoldierRanks=( [...] ) +SoldierRanks=( [...] ) I'm not sure if that'll apply to your situation. I assume that I had to do it because the particular file that I was putting lines in is XComClassData.ini, which apparently follows a naming convention indicating that it is modifying DefaultClassData.ini rather than acting as a stand-alone file. Also, I agree with you about the syntax; it really does look like they're overwriting the value over and over. Link to comment Share on other sites More sharing options...
eXecator Posted February 23, 2016 Author Share Posted February 23, 2016 Hey many thanks, the plusses did the trick. Maybe the Default.ini's are "plus" by default or something. :cool: Link to comment Share on other sites More sharing options...
davidlallen Posted February 24, 2016 Share Posted February 24, 2016 Further discussion here:http://forums.nexusmods.com/index.php?/topic/3837480-best-practices-with-ini-changes/&do=findComment&comment=34942655 Link to comment Share on other sites More sharing options...
Recommended Posts