private float[] ChildOddMod(float[] input) { float modifier = 0.0f; if (root.wealth == Wealth.poor) { modifier += 0.01f; } if (root.relationship == Relationship.dating) { modifier += 0.01f; } else if (root.relationship == Relationship.married) { modifier += 0.02f; if (root.wealth == Wealth.wealthy) { modifier += 0.01f; } } if (root.relationship == Relationship.single) { modifier -= 0.02f; } else { if (GenerationHelpers.SABMatch(root, otherMembers[0])) { modifier -= 0.02f; } else { modifier += 0.01f; } if (root.gender != Gender.cisMale && root.gender != Gender.cisFemale) { modifier -= 0.01f; } else if (otherMembers[0].gender != Gender.cisMale && otherMembers[0].gender != Gender.cisFemale) { modifier -= 0.01f; } } float[] output = input; int count = 1; for (int i = input.Length - 1; i >= 0; i--) { output[i] -= modifier * count; count++; } return(output); }
private void GenChild(RootPerson parent1, Person parent2, int remainingChildren) { gender = Generators.ChildGender(parent1, parent2); age = Generators.ChildAge(parent1, parent2, remainingChildren); float det = Random.Range(0.0f, 1.0f); if (GenerationHelpers.SABMatch(parent1, parent2) || det <= 0.1f) { skinColor = Generators.RootSkinColor(); hairColor = Generators.RootHairColor(skinColor); eyeColor = Generators.RootEyeColor(skinColor); } else { } }