OpenXcom Forum
Modding => Work In Progress => Topic started by: NastyKhan on June 05, 2021, 07:44:59 pm
-
Hi,
Is there a way to ADD my custom items to "startingBase" items collection without removing everything else from the list and without re-declaring whole list?
startingBase:
items:
STR_SNIPER_RIFLE: 2
STR_SNIPER_RIFLE_AMMO: 6
I googled this, but it doesn't seem to work:
#base mod:
items:
- type: STR_WEAPON
compatibleAmmo: !info #this tag does not change anything, but when used it will show (in the log file) if the list supports this functionality or not
- STR_AMMO_1
- STR_AMMO_2
#sub-mod
items:
- type: STR_WEAPON
compatibleAmmo: !add #now `STR_WEAPON` will have ammo list equal to `[STR_AMMO_1, STR_AMMO_2, STR_AMMO_3]`
- STR_AMMO_3
#another sub-mod
items:
- type: STR_WEAPON
compatibleAmmo: !remove #now `STR_WEAPON` will have ammo list equal to `[STR_AMMO_1, STR_AMMO_3]`
- STR_AMMO_2
Best regards
-
...
Is there a way to ADD my custom items to "startingBase" items collection without removing everything else from the list and without re-declaring whole list?
...
Just tested it out on my system (since i wasn't sure). For OXC you need to re-declare the whole list (no need to remove anything, once you define ```items:``` the previously defined list is thrown away).
...
googled this, but it doesn't seem to work:
...
For support of the syntax as shown by your google result you need OXCE (see: https://openxcom.org/forum/index.php/topic,5258.0.html), OXC does not support this.
Hope this helps
-
Hmm... That makes sense. Thank you :)
-
One caveat, in this case this will never work as engine load this in very specific way that can't have enable this.