OpenXcom Forum

Modding => Help => Topic started by: The Martian on December 04, 2017, 07:39:44 pm

Title: Altering existing item's values the have been added by other mods
Post by: The Martian on December 04, 2017, 07:39:44 pm
If you are altering the values of an item that was introduced in a different mod, what is the best way to go about it?

Should the "- delete: STR_ITEM_NAME" command be used and then the entire item be redefined in your new mod?

Or can individual values be changed from within your mod while leaving the source mods values untouched?

Example, change the weight and accuracy of the laser rifle without redefining it entirely:
Code: [Select]
  - type: STR_LASER_RIFLE
    weight: 12
    accuracyAimed: 9
    listOrder: 50


Or for example adding the variable that prevents HWP from accessing their inventory during battle:
Code: [Select]
armors:
  - type: EXAMPLE_ARMOR
    allowInv: false
Title: Re: Altering existing item's values the have been added by other mods
Post by: Warboy1982 on December 05, 2017, 03:17:28 am
individual values can be changed from within your mod, while leaving the source mods values untouched.

mod load order dictates the final value.
Title: Re: Altering existing item's values the have been added by other mods
Post by: The Martian on December 08, 2017, 06:41:58 pm
Perfect! ^_^

Thank you for the information.