Skip to content

Forced combinations is not working as expected #304

Description

Hello how are you?

Awesome library! So it seems forced combinations is not working as expected. Essentially it works sometimes but not always. What I mean is it does not match like its suppose to and sometimes matches other things together.

In this case I want the Service Shirt to Always match Servicer Visor and nothing else.

Here is an example:

Layer configuration

  {
    growEditionSizeTo: 20,
    namePrefix: “Series 1”, // Use to add a name to Metadata `name:`
    layersOrder: [
      { name: “Background” },
      { name: “Body” },
      { name: “Mouth” },
      { name: “Clothes” },
      { name: “Nose” },
      { name: “Eyes” },
      { name: “Traditional Hat”, trait: “Hat” }
    ],
  }

Forced Combinations

const forcedCombinations = {
  "Service Shirt": "Service Visor",
}

Output 1 Does't Work

Setting up the folling forced combinations for Service Shirt:  S e r v i c e   V i s o r
DNA: [
  '0.3:Indigo#833.png',
  '1.0:Skin#100.png',
  '2.9:Rage#698.png',
  '3.0:Service Shirt#970.png',
  '4.1:Curve#1104.png',
  '5.9:Determined#954.png',
  '6.2:Gold Crown#85.png'
]

Output 2 Works

Setting up the folling forced combinations for Service Shirt:  S e r v i c e   V i s o r

Adding the following to incompatible list Snake Crown
DNA: [
  ‘0.11:Violet Blue#833.png’,
  ‘1.0:Skin#100.png’,
  ‘2.8:Cool#1006.png’,
  ‘3.0:Service Shirt#970.png’,
  ‘4.3:Rounded#1112.png’,
  ‘5.9:Quick#954.png’,
  ‘6.0:Service Visor#555.png’
]

I also tried adding incompatible layers as a test and it still does not work always as expected (only sometimes)

const incompatible = {
  "Gown": ["Service Visor"],
  "Jacket": ["Service Visor"],
  "Suit": ["Service Visor"],
  "Service Visor": ["Gold Crown"]
};

Thanks for the help!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions