Author Topic: [Solved] Submodding armors layersDefinition  (Read 2060 times)

Offline mikKoi

  • Sergeant
  • **
  • Posts: 44
  • That's raider country!
    • View Profile
[Solved] Submodding armors layersDefinition
« on: April 26, 2022, 10:30:09 pm »
Hi, I’m trying to submod Xpiratez's armor layers to add custom stuff, but it seems to be more tricky than just modding existing items etc. So, if I write it like in XPZ:

Code: [Select]
armors:
  - type: STR_PEASANT_NUDE_UC
    layersDefinition:
      M28: ["", "", "M28_NUDE", "", "", "", "", "", "", "", "", "GLASSES_M28", "", "HAIR_M28"]

It causes a crash before the inventory screen: Layered armor sprite definition [STR_PEASANT_NUDE_UC] not found

What magic do I need to perform to gain access to layersDefinition or is it unsubmoddable?
« Last Edit: February 12, 2023, 12:33:04 pm by Meridian »

Offline Meridian

  • Global Moderator
  • Commander
  • *****
  • Posts: 8615
    • View Profile
Re: Submodding armors layersDefinition
« Reply #1 on: April 26, 2022, 10:35:53 pm »
you need to define all items in the "layersDefinition"

the code you have above deletes all items defined in piratez ruleset and adds just your 1 item

Offline mikKoi

  • Sergeant
  • **
  • Posts: 44
  • That's raider country!
    • View Profile
Re: Submodding armors layersDefinition
« Reply #2 on: April 26, 2022, 10:40:00 pm »
Sure, I just realized it by myself, but bit too late. :-\

Will do that. Thanks.

Offline Yankes

  • Commander
  • *****
  • Posts: 3206
    • View Profile
Re: Submodding armors layersDefinition
« Reply #3 on: April 27, 2022, 12:44:14 pm »
In theory I could add there option for `!add` tag that preserve old values.

Offline Docent

  • Colonel
  • ****
  • Posts: 101
    • View Profile
Re: Submodding armors layersDefinition
« Reply #4 on: April 28, 2022, 12:07:04 pm »
In theory I could add there option for `!add` tag that preserve old values.

It would be cool. This tag greatly simplifies the creation of submods.