Search in sources :

Example 6 with OrificeModifier

use of com.lilithsthrone.game.character.body.valueEnums.OrificeModifier in project liliths-throne-public by Innoxia.

the class CharacterUtils method generateBody.

public static Body generateBody(Gender startingGender, GameCharacter mother, GameCharacter father) {
    RacialBody startingBodyType = RacialBody.HUMAN;
    RacialBody motherBody = RacialBody.valueOfRace(mother.getSubspecies().getOffspringSubspecies().getRace());
    RacialBody fatherBody = RacialBody.valueOfRace(father.getSubspecies().getOffspringSubspecies().getRace());
    Subspecies raceTakesAfter = mother.getSubspecies();
    RaceStage stage = RaceStage.HUMAN;
    boolean takesAfterMother = true;
    boolean raceFromMother = true;
    boolean feminineGender = startingGender.isFeminine();
    NPC blankNPC = Main.game.getGenericAndrogynousNPC();
    GameCharacter parentTakesAfter = mother;
    // Core body type is random:
    if (Math.random() <= 0.5) {
        startingBodyType = motherBody;
        stage = mother.getRaceStage();
    } else {
        startingBodyType = fatherBody;
        stage = father.getRaceStage();
        raceTakesAfter = father.getSubspecies();
        raceFromMother = false;
    }
    switch(startingGender.isFeminine() ? Main.getProperties().subspeciesFeminineFurryPreferencesMap.get(raceTakesAfter) : Main.getProperties().subspeciesMasculineFurryPreferencesMap.get(raceTakesAfter)) {
        case HUMAN:
            stage = RaceStage.HUMAN;
            break;
        case MINIMUM:
            if (stage != RaceStage.HUMAN || stage != RaceStage.PARTIAL) {
                stage = RaceStage.PARTIAL;
            }
            break;
        case REDUCED:
            if (stage != RaceStage.HUMAN || stage != RaceStage.PARTIAL || stage != RaceStage.LESSER) {
                stage = RaceStage.LESSER;
            }
            break;
        case NORMAL:
            break;
        case MAXIMUM:
            stage = RaceStage.GREATER;
            break;
    }
    Body body = generateBody(startingGender, startingBodyType, stage);
    if (mother.getBodyMaterial() == BodyMaterial.SLIME) {
        body.setBodyMaterial(BodyMaterial.SLIME);
    }
    // Takes other features from the parent closest to their femininity:
    if (Math.abs(mother.getFemininityValue() - body.getFemininity()) > Math.abs(father.getFemininityValue() - body.getFemininity())) {
        takesAfterMother = false;
        parentTakesAfter = father;
    }
    float takesAfterMotherChance = takesAfterMother ? 0.75f : 0.25f;
    List<BodyCoveringType> typesToInfluence = new ArrayList<>();
    // Skin & fur colours:
    for (BodyPartInterface bp : body.getAllBodyParts()) {
        if (bp.getType().getBodyCoveringType(body) != null && bp.getType().getBodyCoveringType(body).getRace() != null && !(bp instanceof Eye)) {
            typesToInfluence.add(bp.getType().getBodyCoveringType(body));
        }
    }
    typesToInfluence.add(BodyCoveringType.ANUS);
    typesToInfluence.add(BodyCoveringType.NIPPLES);
    typesToInfluence.add(BodyCoveringType.MOUTH);
    typesToInfluence.add(BodyCoveringType.TONGUE);
    if (raceFromMother) {
        typesToInfluence = setCoveringColours(body, mother, typesToInfluence);
        setCoveringColours(body, father, typesToInfluence);
    } else {
        typesToInfluence = setCoveringColours(body, father, typesToInfluence);
        setCoveringColours(body, mother, typesToInfluence);
    }
    body.updateCoverings(false, false, true, false);
    // Iris colour:
    if (Math.random() >= 0.9f) {
        if (Math.random() >= takesAfterMotherChance) {
            body.getCoverings().put(body.getEye().getType().getBodyCoveringType(body), new Covering(body.getEye().getType().getBodyCoveringType(body), mother.getCovering(mother.getEyeType().getBodyCoveringType(mother)).getPattern(), mother.getCovering(mother.getEyeType().getBodyCoveringType(mother)).getPrimaryColour(), mother.getCovering(mother.getEyeType().getBodyCoveringType(mother)).isPrimaryGlowing(), mother.getCovering(mother.getEyeType().getBodyCoveringType(mother)).getPrimaryColour(), mother.getCovering(mother.getEyeType().getBodyCoveringType(mother)).isPrimaryGlowing()));
        } else {
            body.getCoverings().put(body.getEye().getType().getBodyCoveringType(body), new Covering(body.getEye().getType().getBodyCoveringType(body), father.getCovering(father.getEyeType().getBodyCoveringType(father)).getPattern(), father.getCovering(father.getEyeType().getBodyCoveringType(father)).getPrimaryColour(), father.getCovering(father.getEyeType().getBodyCoveringType(father)).isPrimaryGlowing(), father.getCovering(father.getEyeType().getBodyCoveringType(father)).getPrimaryColour(), father.getCovering(father.getEyeType().getBodyCoveringType(father)).isPrimaryGlowing()));
        }
    }
    // Pupil colour:
    if (Math.random() >= 0.4f) {
        if (Math.random() >= takesAfterMotherChance) {
            body.getCoverings().put(BodyCoveringType.EYE_PUPILS, new Covering(body.getEye().getType().getBodyCoveringType(body), mother.getCovering(BodyCoveringType.EYE_PUPILS).getPattern(), mother.getCovering(BodyCoveringType.EYE_PUPILS).getPrimaryColour(), mother.getCovering(BodyCoveringType.EYE_PUPILS).isPrimaryGlowing(), mother.getCovering(BodyCoveringType.EYE_PUPILS).getPrimaryColour(), mother.getCovering(BodyCoveringType.EYE_PUPILS).isPrimaryGlowing()));
        } else {
            body.getCoverings().put(BodyCoveringType.EYE_PUPILS, new Covering(body.getEye().getType().getBodyCoveringType(body), father.getCovering(BodyCoveringType.EYE_PUPILS).getPattern(), father.getCovering(BodyCoveringType.EYE_PUPILS).getPrimaryColour(), father.getCovering(BodyCoveringType.EYE_PUPILS).isPrimaryGlowing(), father.getCovering(BodyCoveringType.EYE_PUPILS).getPrimaryColour(), father.getCovering(BodyCoveringType.EYE_PUPILS).isPrimaryGlowing()));
        }
    }
    // Body core:
    // Height:
    body.setHeight(getSizeFromGenetics(body.getHeightValue(), (body.isFeminine() ? mother.isFeminine() : !mother.isFeminine()), mother.getHeightValue(), (body.isFeminine() ? father.isFeminine() : !father.isFeminine()), father.getHeightValue()));
    // Femininity:
    switch(startingGender.getType()) {
        case FEMININE:
            if (takesAfterMother) {
                if (mother.getFemininityValue() >= Femininity.FEMININE.getMinimumFemininity()) {
                    body.setFemininity(mother.getFemininityValue());
                }
            } else {
                if (father.getFemininityValue() >= Femininity.FEMININE.getMinimumFemininity()) {
                    body.setFemininity(father.getFemininityValue());
                }
            }
            break;
        case NEUTRAL:
            if (takesAfterMother) {
                if (mother.getFemininity() == Femininity.ANDROGYNOUS) {
                    body.setFemininity(mother.getFemininityValue());
                }
            } else {
                if (father.getFemininity() == Femininity.ANDROGYNOUS) {
                    body.setFemininity(father.getFemininityValue());
                }
            }
            break;
        case MASCULINE:
            if (takesAfterMother) {
                if (mother.getFemininityValue() < Femininity.ANDROGYNOUS.getMinimumFemininity()) {
                    body.setFemininity(mother.getFemininityValue());
                }
            } else {
                if (father.getFemininityValue() < Femininity.ANDROGYNOUS.getMinimumFemininity()) {
                    body.setFemininity(father.getFemininityValue());
                }
            }
            break;
    }
    // Body size:
    int minimumSize = Math.min(mother.getBodySizeValue(), father.getBodySizeValue()) - Util.random.nextInt(5);
    int maximumSize = Math.min(mother.getBodySizeValue(), father.getBodySizeValue()) + Util.random.nextInt(5);
    if (takesAfterMother) {
        minimumSize = Math.max(minimumSize, (feminineGender ? motherBody.getFemaleBodySize() - 30 : motherBody.getMaleBodySize() - 30));
        maximumSize = Math.max(maximumSize, (feminineGender ? motherBody.getFemaleBodySize() + 30 : motherBody.getMaleBodySize() + 30));
    } else {
        minimumSize = Math.max(minimumSize, (feminineGender ? fatherBody.getFemaleBodySize() - 30 : fatherBody.getMaleBodySize() - 30));
        maximumSize = Math.max(maximumSize, (feminineGender ? fatherBody.getFemaleBodySize() + 30 : fatherBody.getMaleBodySize() + 30));
    }
    int variance = (maximumSize == minimumSize ? 0 : Util.random.nextInt(maximumSize - minimumSize));
    body.setBodySize(minimumSize + variance);
    // Muscle:
    int minimumMuscle = Math.min(mother.getMuscleValue(), father.getMuscleValue()) - Util.random.nextInt(5);
    int maximumMuscle = Math.min(mother.getMuscleValue(), father.getMuscleValue()) + Util.random.nextInt(5);
    if (takesAfterMother) {
        minimumMuscle = Math.max(minimumMuscle, (feminineGender ? motherBody.getFemaleMuscle() - 30 : motherBody.getMaleMuscle() - 30));
        maximumMuscle = Math.max(maximumMuscle, (feminineGender ? motherBody.getFemaleMuscle() + 30 : motherBody.getMaleMuscle() + 30));
    } else {
        minimumMuscle = Math.max(minimumMuscle, (feminineGender ? fatherBody.getFemaleMuscle() - 30 : fatherBody.getMaleMuscle() - 30));
        maximumMuscle = Math.max(maximumMuscle, (feminineGender ? fatherBody.getFemaleMuscle() + 30 : fatherBody.getMaleMuscle() + 30));
    }
    variance = (maximumMuscle == minimumMuscle ? 0 : Util.random.nextInt(maximumMuscle - minimumMuscle));
    body.setMuscle(minimumMuscle + variance);
    // Body parts:
    boolean inheritsFromMotherFemininity = mother.isFeminine() == body.isFeminine();
    boolean inheritsFromFatherFemininity = father.isFeminine() == body.isFeminine();
    // Arm:
    if (Math.random() > 0.75) {
        body.getArm().setArmRows(blankNPC, parentTakesAfter.getArmRows());
    }
    // Ass:
    // Ass size:
    body.getAss().setAssSize(blankNPC, getSizeFromGenetics(body.getAss().getAssSize().getValue(), inheritsFromMotherFemininity, mother.getAssSize().getValue(), inheritsFromFatherFemininity, father.getAssSize().getValue()));
    // Hip size:
    body.getAss().setHipSize(blankNPC, getSizeFromGenetics(body.getAss().getHipSize().getValue(), inheritsFromMotherFemininity, mother.getHipSize().getValue(), inheritsFromFatherFemininity, father.getHipSize().getValue()));
    // Breasts:
    boolean inheritsFromMotherBreasts = mother.hasBreasts();
    boolean inheritsFromFatherBreasts = father.hasBreasts();
    if (body.getBreast().getRawSizeValue() > 0) {
        // Breast shape:
        if (Math.random() >= 0.8f) {
            if (inheritsFromMotherBreasts && inheritsFromFatherBreasts) {
                if (Math.random() >= takesAfterMotherChance) {
                    body.getBreast().setShape(blankNPC, mother.getBreastShape());
                } else {
                    body.getBreast().setShape(blankNPC, father.getBreastShape());
                }
            } else if (inheritsFromMotherBreasts) {
                body.getBreast().setShape(blankNPC, mother.getBreastShape());
            } else if (inheritsFromFatherBreasts) {
                body.getBreast().setShape(blankNPC, father.getBreastShape());
            }
        }
        // Breast size:
        body.getBreast().setSize(blankNPC, getSizeFromGenetics(body.getBreast().getSize().getMeasurement(), inheritsFromMotherBreasts, mother.getBreastSize().getMeasurement(), inheritsFromFatherBreasts, father.getBreastSize().getMeasurement()));
        // Breast rows:
        if (Math.random() >= 0.75) {
            if (Math.random() >= takesAfterMotherChance) {
                body.getBreast().setRows(blankNPC, mother.getBreastRows());
            } else {
                body.getBreast().setRows(blankNPC, father.getBreastRows());
            }
        }
        // Modifiers:
        for (OrificeModifier om : OrificeModifier.values()) {
            if (Math.random() >= 0.5) {
                if (inheritsFromMotherBreasts && inheritsFromFatherBreasts) {
                    if (Math.random() >= takesAfterMotherChance) {
                        if (mother.hasNippleOrificeModifier(om)) {
                            body.getBreast().getNipples().getOrificeNipples().addOrificeModifier(blankNPC, om);
                        }
                    } else {
                        if (father.hasNippleOrificeModifier(om)) {
                            body.getBreast().getNipples().getOrificeNipples().addOrificeModifier(blankNPC, om);
                        }
                    }
                } else if (inheritsFromMotherBreasts) {
                    if (mother.hasNippleOrificeModifier(om)) {
                        body.getBreast().getNipples().getOrificeNipples().addOrificeModifier(blankNPC, om);
                    }
                } else if (inheritsFromFatherBreasts) {
                    if (father.hasNippleOrificeModifier(om)) {
                        body.getBreast().getNipples().getOrificeNipples().addOrificeModifier(blankNPC, om);
                    }
                }
            }
        }
    }
    // Nipple count:
    if (Math.random() > 0.75f) {
        if (Math.random() >= takesAfterMotherChance) {
            body.getBreast().setNippleCountPerBreast(blankNPC, mother.getNippleCountPerBreast());
        } else {
            body.getBreast().setNippleCountPerBreast(blankNPC, father.getNippleCountPerBreast());
        }
    }
    // Nipple shape:
    if (Math.random() >= 0.75f) {
        if (Math.random() >= takesAfterMotherChance) {
            body.getBreast().getNipples().setNippleShape(blankNPC, mother.getNippleShape());
        } else {
            body.getBreast().getNipples().setNippleShape(blankNPC, father.getNippleShape());
        }
    }
    // Areolae shape:
    if (Math.random() >= 0.75f) {
        if (Math.random() >= takesAfterMotherChance) {
            body.getBreast().getNipples().setAreolaeShape(blankNPC, mother.getAreolaeShape());
        } else {
            body.getBreast().getNipples().setAreolaeShape(blankNPC, father.getAreolaeShape());
        }
    }
    // Nipple size:
    body.getBreast().getNipples().setNippleSize(blankNPC, getSizeFromGenetics(body.getBreast().getNipples().getNippleSizeValue(), inheritsFromMotherBreasts, mother.getNippleSize().getValue(), inheritsFromFatherBreasts, father.getNippleSize().getValue()));
    // Areolae size:
    body.getBreast().getNipples().setAreolaeSize(blankNPC, getSizeFromGenetics(body.getBreast().getNipples().getAreolaeSizeValue(), inheritsFromMotherBreasts, mother.getAreolaeSize().getValue(), inheritsFromFatherBreasts, father.getAreolaeSize().getValue()));
    // Face:
    // Lip size:
    body.getFace().getMouth().setLipSize(blankNPC, getSizeFromGenetics(body.getFace().getMouth().getLipSizeValue(), inheritsFromMotherFemininity, mother.getLipSizeValue(), inheritsFromFatherFemininity, father.getLipSizeValue()));
    // Mouth modifiers:
    for (OrificeModifier om : OrificeModifier.values()) {
        if (Math.random() >= 0.5) {
            if (Math.random() >= takesAfterMotherChance) {
                if (mother.hasFaceOrificeModifier(om)) {
                    body.getFace().getMouth().getOrificeMouth().addOrificeModifier(blankNPC, om);
                }
            } else {
                if (father.hasFaceOrificeModifier(om)) {
                    body.getFace().getMouth().getOrificeMouth().addOrificeModifier(blankNPC, om);
                }
            }
        }
    }
    // Tongue modifiers:
    for (TongueModifier tm : TongueModifier.values()) {
        if (Math.random() >= 0.5) {
            if (Math.random() >= takesAfterMotherChance) {
                if (mother.hasTongueModifier(tm)) {
                    body.getFace().getTongue().addTongueModifier(blankNPC, tm);
                }
            } else {
                if (father.hasTongueModifier(tm)) {
                    body.getFace().getTongue().addTongueModifier(blankNPC, tm);
                }
            }
        }
    }
    // Eye pairs:
    if (Math.random() >= 0.75) {
        if (Math.random() >= takesAfterMotherChance) {
            body.getEye().setEyePairs(blankNPC, mother.getEyePairs());
        } else {
            body.getEye().setEyePairs(blankNPC, father.getEyePairs());
        }
    }
    // Iris shape:
    if (Math.random() >= 0.75) {
        if (Math.random() >= takesAfterMotherChance) {
            body.getEye().setIrisShape(blankNPC, mother.getIrisShape());
        } else {
            body.getEye().setIrisShape(blankNPC, father.getIrisShape());
        }
    }
    // Pupil shape:
    if (Math.random() >= 0.75) {
        if (Math.random() >= takesAfterMotherChance) {
            body.getEye().setPupilShape(blankNPC, mother.getPupilShape());
        } else {
            body.getEye().setPupilShape(blankNPC, father.getPupilShape());
        }
    }
    // Horn rows:
    if (Math.random() >= 0.75) {
        if (Math.random() >= takesAfterMotherChance) {
            body.getHorn().setHornRows(blankNPC, mother.getHornRows());
        } else {
            body.getHorn().setHornRows(blankNPC, father.getHornRows());
        }
    }
    // Penis:
    boolean inheritsFromMotherPenis = mother.hasPenis();
    boolean inheritsFromFatherPenis = father.hasPenis();
    if (body.getPenis().getType() != PenisType.NONE) {
        // Penis size:
        body.getPenis().setPenisSize(blankNPC, getSizeFromGenetics(body.getPenis().getRawSizeValue(), inheritsFromMotherPenis, mother.getPenisRawSizeValue(), inheritsFromFatherPenis, father.getPenisRawSizeValue()));
        // Penis modifiers:
        for (PenisModifier pm : PenisModifier.values()) {
            if (Math.random() >= 0.5) {
                if (inheritsFromMotherPenis && inheritsFromFatherPenis) {
                    if (Math.random() >= takesAfterMotherChance) {
                        if (mother.hasPenisModifier(pm)) {
                            body.getPenis().addPenisModifier(blankNPC, pm);
                        }
                    } else {
                        if (father.hasPenisModifier(pm)) {
                            body.getPenis().addPenisModifier(blankNPC, pm);
                        }
                    }
                } else if (inheritsFromMotherPenis) {
                    if (mother.hasPenisModifier(pm)) {
                        body.getPenis().addPenisModifier(blankNPC, pm);
                    }
                } else if (inheritsFromFatherPenis) {
                    if (father.hasPenisModifier(pm)) {
                        body.getPenis().addPenisModifier(blankNPC, pm);
                    }
                }
            }
        }
        // Urethra modifiers:
        for (OrificeModifier om : OrificeModifier.values()) {
            if (Math.random() >= 0.5) {
                if (inheritsFromMotherPenis && inheritsFromFatherPenis) {
                    if (Math.random() >= takesAfterMotherChance) {
                        if (mother.hasUrethraOrificeModifier(om)) {
                            body.getPenis().getOrificeUrethra().addOrificeModifier(blankNPC, om);
                        }
                    } else {
                        if (father.hasUrethraOrificeModifier(om)) {
                            body.getPenis().getOrificeUrethra().addOrificeModifier(blankNPC, om);
                        }
                    }
                } else if (inheritsFromMotherPenis) {
                    if (mother.hasUrethraOrificeModifier(om)) {
                        body.getPenis().getOrificeUrethra().addOrificeModifier(blankNPC, om);
                    }
                } else if (inheritsFromFatherPenis) {
                    if (father.hasUrethraOrificeModifier(om)) {
                        body.getPenis().getOrificeUrethra().addOrificeModifier(blankNPC, om);
                    }
                }
            }
        }
        // Testicles:
        // Testicle size:
        body.getPenis().getTesticle().setTesticleSize(blankNPC, getSizeFromGenetics(body.getPenis().getTesticle().getTesticleSize().getValue(), inheritsFromMotherPenis, mother.getTesticleSize().getValue(), inheritsFromFatherPenis, father.getTesticleSize().getValue()));
        // Testicle count:
        if (Math.random() >= 0.75) {
            if (inheritsFromMotherPenis && inheritsFromFatherPenis) {
                if (Math.random() >= takesAfterMotherChance) {
                    body.getPenis().getTesticle().setTesticleCount(blankNPC, mother.getTesticleCount());
                } else {
                    body.getPenis().getTesticle().setTesticleCount(blankNPC, father.getTesticleCount());
                }
            } else if (inheritsFromMotherPenis) {
                body.getPenis().getTesticle().setTesticleCount(blankNPC, mother.getTesticleCount());
            } else if (inheritsFromFatherPenis) {
                body.getPenis().getTesticle().setTesticleCount(blankNPC, father.getTesticleCount());
            }
        }
        // Internal testicles:
        if (Math.random() >= 0.75) {
            if (inheritsFromMotherPenis && inheritsFromFatherPenis) {
                if (Math.random() >= takesAfterMotherChance) {
                    if (mother.isInternalTesticles()) {
                        body.getPenis().getTesticle().setInternal(blankNPC, true);
                    }
                } else {
                    if (father.isInternalTesticles()) {
                        body.getPenis().getTesticle().setInternal(blankNPC, true);
                    }
                }
            } else if (inheritsFromMotherPenis) {
                if (mother.isInternalTesticles()) {
                    body.getPenis().getTesticle().setInternal(blankNPC, true);
                }
            } else if (inheritsFromFatherPenis) {
                if (father.isInternalTesticles()) {
                    body.getPenis().getTesticle().setInternal(blankNPC, true);
                }
            }
        }
        // Cum Production:
        body.getPenis().getTesticle().setCumProduction(blankNPC, getSizeFromGenetics(body.getPenis().getTesticle().getRawCumProductionValue(), inheritsFromMotherPenis, mother.getPenisRawCumProductionValue(), inheritsFromFatherPenis, father.getPenisRawCumProductionValue()));
    }
    // Tail:
    if (Math.random() > 0.75) {
        if (Math.random() >= takesAfterMotherChance) {
            body.getTail().setTailCount(blankNPC, mother.getTailCount());
        } else {
            body.getTail().setTailCount(blankNPC, father.getTailCount());
        }
    }
    // Vagina:
    boolean inheritsFromMotherVagina = mother.hasVagina();
    boolean inheritsFromFatherVagina = father.hasVagina();
    if (body.getVagina().getType() != VaginaType.NONE) {
        // Clitoris size:
        body.getVagina().setClitorisSize(blankNPC, getSizeFromGenetics(body.getVagina().getRawClitorisSizeValue(), inheritsFromMotherVagina, mother.getVaginaRawClitorisSizeValue(), inheritsFromFatherVagina, father.getVaginaRawClitorisSizeValue()));
        // Labia size:
        body.getVagina().setLabiaSize(blankNPC, getSizeFromGenetics(body.getVagina().getRawLabiaSizeValue(), inheritsFromMotherVagina, mother.getVaginaRawLabiaSizeValue(), inheritsFromFatherVagina, father.getVaginaRawLabiaSizeValue()));
        // // Capacity:
        // body.getVagina().getOrificeVagina().setCapacity(blankNPC, getSizeFromGenetics(
        // (int) body.getVagina().getOrificeVagina().getRawCapacityValue(),
        // inheritsFromMotherVagina, (int) mother.getVaginaRawCapacityValue(),
        // inheritsFromFatherVagina, (int) father.getVaginaRawCapacityValue()));
        // Wetness:
        body.getVagina().getOrificeVagina().setWetness(blankNPC, getSizeFromGenetics(body.getVagina().getOrificeVagina().getWetness(blankNPC).getValue(), inheritsFromMotherVagina, mother.getVaginaWetness().getValue(), inheritsFromFatherVagina, father.getVaginaWetness().getValue()));
        // Modifiers:
        for (OrificeModifier om : OrificeModifier.values()) {
            if (Math.random() >= 0.5) {
                if (inheritsFromMotherVagina && inheritsFromFatherVagina) {
                    if (Math.random() >= takesAfterMotherChance) {
                        if (mother.hasVaginaOrificeModifier(om)) {
                            body.getVagina().getOrificeVagina().addOrificeModifier(blankNPC, om);
                        }
                    } else {
                        if (father.hasVaginaOrificeModifier(om)) {
                            body.getVagina().getOrificeVagina().addOrificeModifier(blankNPC, om);
                        }
                    }
                } else if (inheritsFromMotherVagina) {
                    if (mother.hasVaginaOrificeModifier(om)) {
                        body.getVagina().getOrificeVagina().addOrificeModifier(blankNPC, om);
                    }
                } else if (inheritsFromFatherVagina) {
                    if (father.hasVaginaOrificeModifier(om)) {
                        body.getVagina().getOrificeVagina().addOrificeModifier(blankNPC, om);
                    }
                }
            }
        }
    }
    return body;
}
Also used : NPC(com.lilithsthrone.game.character.npc.NPC) ArrayList(java.util.ArrayList) Covering(com.lilithsthrone.game.character.body.Covering) RaceStage(com.lilithsthrone.game.character.race.RaceStage) BodyCoveringType(com.lilithsthrone.game.character.body.types.BodyCoveringType) RacialBody(com.lilithsthrone.game.character.race.RacialBody) Subspecies(com.lilithsthrone.game.character.race.Subspecies) PenisModifier(com.lilithsthrone.game.character.body.valueEnums.PenisModifier) Eye(com.lilithsthrone.game.character.body.Eye) TongueModifier(com.lilithsthrone.game.character.body.valueEnums.TongueModifier) BodyPartInterface(com.lilithsthrone.game.character.body.BodyPartInterface) Body(com.lilithsthrone.game.character.body.Body) RacialBody(com.lilithsthrone.game.character.race.RacialBody) OrificeModifier(com.lilithsthrone.game.character.body.valueEnums.OrificeModifier)

Example 7 with OrificeModifier

use of com.lilithsthrone.game.character.body.valueEnums.OrificeModifier in project liliths-throne-public by Innoxia.

the class Vagina method getDescriptor.

@Override
public String getDescriptor(GameCharacter owner) {
    List<String> descriptorList = new ArrayList<>();
    for (OrificeModifier om : orificeVagina.getOrificeModifiers()) {
        descriptorList.add(om.getName());
    }
    String wetnessDescriptor = orificeVagina.getWetness(owner).getDescriptor();
    if (Main.game.isInSex()) {
        if (!Sex.getWetOrificeTypes(owner).get(OrificeType.VAGINA).isEmpty()) {
            wetnessDescriptor = "wet";
        }
    }
    descriptorList.add(wetnessDescriptor);
    if ((owner.getPubicHair() == BodyHair.SIX_BUSHY || owner.getPubicHair() == BodyHair.FIVE_UNKEMPT) && Main.game.isBodyHairEnabled()) {
        descriptorList.add("hairy");
    }
    descriptorList.add(type.getDescriptor(owner));
    descriptorList.add(orificeVagina.getCapacity().getDescriptor());
    return UtilText.returnStringAtRandom(descriptorList.toArray(new String[] {}));
}
Also used : ArrayList(java.util.ArrayList) OrificeModifier(com.lilithsthrone.game.character.body.valueEnums.OrificeModifier)

Example 8 with OrificeModifier

use of com.lilithsthrone.game.character.body.valueEnums.OrificeModifier in project liliths-throne-public by Innoxia.

the class Anus method getDescriptor.

@Override
public String getDescriptor(GameCharacter owner) {
    List<String> descriptorList = new ArrayList<String>();
    for (OrificeModifier om : orificeAnus.getOrificeModifiers()) {
        descriptorList.add(om.getName());
    }
    String wetnessDescriptor = orificeAnus.getWetness(owner).getDescriptor();
    if (Main.game.isInSex()) {
        if (!Sex.getWetOrificeTypes(owner).get(OrificeType.ANUS).isEmpty()) {
            wetnessDescriptor = "wet";
        }
    }
    descriptorList.add(wetnessDescriptor);
    if ((owner.getAssHair() == BodyHair.SIX_BUSHY || owner.getAssHair() == BodyHair.THREE_TRIMMED) && Main.game.isBodyHairEnabled()) {
        descriptorList.add("hairy");
    }
    descriptorList.add(type.getDescriptor(owner));
    descriptorList.add(orificeAnus.getCapacity().getDescriptor());
    return UtilText.returnStringAtRandom(descriptorList.toArray(new String[] {}));
}
Also used : ArrayList(java.util.ArrayList) OrificeModifier(com.lilithsthrone.game.character.body.valueEnums.OrificeModifier)

Example 9 with OrificeModifier

use of com.lilithsthrone.game.character.body.valueEnums.OrificeModifier in project liliths-throne-public by Innoxia.

the class Body method getAssDescription.

public String getAssDescription(GameCharacter owner) {
    descriptionSB = new StringBuilder();
    boolean isPlayer = owner.isPlayer();
    switch(ass.getType()) {
        case HUMAN:
            if (isPlayer) {
                descriptionSB.append("You have a human, [pc.anusFullDescription(true)]");
            } else {
                descriptionSB.append("[npc.She] has a human, [npc.anusFullDescription(true)]");
            }
            break;
        case ANGEL:
            if (isPlayer) {
                descriptionSB.append("You have an angelic, [pc.anusFullDescription(true)]");
            } else {
                descriptionSB.append("[npc.She] has an angelic, [npc.anusFullDescription(true)]");
            }
            break;
        case DEMON_COMMON:
            if (isPlayer) {
                descriptionSB.append("You have a demonic, [pc.anusFullDescription(true)]");
            } else {
                descriptionSB.append("[npc.She] has a demonic, [npc.anusFullDescription(true)]");
            }
            break;
        case IMP:
            if (isPlayer) {
                descriptionSB.append("You have an impish, [pc.anusFullDescription(true)]");
            } else {
                descriptionSB.append("[npc.She] has an impish, [npc.anusFullDescription(true)]");
            }
            break;
        case DOG_MORPH:
            if (isPlayer) {
                descriptionSB.append("You have a canine, [pc.anusFullDescription(true)]");
            } else {
                descriptionSB.append("[npc.She] has a canine, [npc.anusFullDescription(true)]");
            }
            break;
        case WOLF_MORPH:
            if (isPlayer) {
                descriptionSB.append("You have a lupine, [pc.anusFullDescription(true)]");
            } else {
                descriptionSB.append("[npc.She] has a lupine, [npc.anusFullDescription(true)]");
            }
            break;
        case CAT_MORPH:
            if (isPlayer) {
                descriptionSB.append("You have a feline, [pc.anusFullDescription(true)]");
            } else {
                descriptionSB.append("[npc.She] has a feline, [npc.anusFullDescription(true)]");
            }
            break;
        case SQUIRREL_MORPH:
            if (isPlayer) {
                descriptionSB.append("You have a rodent, [pc.anusFullDescription(true)]");
            } else {
                descriptionSB.append("[npc.She] has a rodent, [npc.anusFullDescription(true)]");
            }
            break;
        case ALLIGATOR_MORPH:
            if (isPlayer) {
                descriptionSB.append("You have a reptilian, [pc.anusFullDescription(true)]");
            } else {
                descriptionSB.append("[npc.She] has a reptilian, [npc.anusFullDescription(true)]");
            }
            break;
        case HORSE_MORPH:
            if (isPlayer) {
                descriptionSB.append("You have an equine, [pc.anusFullDescription(true)]");
            } else {
                descriptionSB.append("[npc.She] has an equine, [npc.anusFullDescription(true)]");
            }
            break;
        case REINDEER_MORPH:
            if (isPlayer) {
                descriptionSB.append("You have a rangiferine, [pc.anusFullDescription(true)]");
            } else {
                descriptionSB.append("[npc.She] has a rangiferine, [npc.anusFullDescription(true)]");
            }
            break;
        case COW_MORPH:
            if (isPlayer) {
                descriptionSB.append("You have a bovine, [pc.anusFullDescription(true)]");
            } else {
                descriptionSB.append("[npc.She] has a bovine, [npc.anusFullDescription(true)]");
            }
            break;
        case HARPY:
            if (isPlayer) {
                descriptionSB.append("You have an avian, [pc.anusFullDescription(true)]");
            } else {
                descriptionSB.append("[npc.She] has an avian, [npc.anusFullDescription(true)]");
            }
            break;
    }
    // Colour:
    if (ass.getAnus().isBleached()) {
        if (isPlayer) {
            descriptionSB.append(", which has been bleached so that the rim is no darker than the [pc.assSkin] around it.");
        } else {
            descriptionSB.append(", which has been bleached so that the rim is no darker than the [npc.assSkin] around it.");
        }
    } else {
        if (isPlayer) {
            descriptionSB.append(", the rim being slightly darker than the [pc.assSkin] around it.");
        } else {
            descriptionSB.append(", the rim being slightly darker than the [npc.assSkin] around it.");
        }
    }
    descriptionSB.append(" <span style='color:" + Colour.GENERIC_SEX.toWebHexString() + ";'>It is " + Capacity.getCapacityFromValue(ass.getAnus().getOrificeAnus().getStretchedCapacity()).getDescriptor() + ", and can comfortably take " + Capacity.getCapacityFromValue(ass.getAnus().getOrificeAnus().getStretchedCapacity()).getMaximumSizeComfortableWithLube().getDescriptor() + " cocks with enough lube.</span>");
    if (isPlayer) {
        if (ass.getAnus().getOrificeAnus().isVirgin()) {
            descriptionSB.append(" <span style='color:" + Colour.GENERIC_GOOD.toWebHexString() + ";'>You have retained your anal virginity.</span>");
        } else {
            for (PenetrationType pt : PenetrationType.values()) {
                if (Main.game.getPlayer().getVirginityLoss(new SexType(SexParticipantType.CATCHER, pt, OrificeType.ANUS)) != null && !Main.game.getPlayer().getVirginityLoss(new SexType(SexParticipantType.CATCHER, pt, OrificeType.ANUS)).isEmpty()) {
                    descriptionSB.append(" <span style='color:" + Colour.GENERIC_ARCANE.toWebHexString() + ";'>You lost your anal virginity to " + Main.game.getPlayer().getVirginityLoss(new SexType(SexParticipantType.CATCHER, pt, OrificeType.ANUS)) + ".</span>");
                    break;
                }
            }
        }
    }
    // Ass wetness:
    switch(ass.getAnus().getOrificeAnus().getWetness(owner)) {
        case ZERO_DRY:
            descriptionSB.append(" <span style='color:" + Colour.GENERIC_SEX.toWebHexString() + ";'>It is completely dry, and would need lubricating before sex.</span>");
            break;
        case ONE_SLIGHTLY_MOIST:
            descriptionSB.append(" <span style='color:" + Colour.GENERIC_SEX.toWebHexString() + ";'>It is slightly moist, but would still need lubricating before sex.</span>");
            break;
        case TWO_MOIST:
            descriptionSB.append(" <span style='color:" + Colour.GENERIC_SEX.toWebHexString() + ";'>It is moist, but would still need lubricating before sex.</span>");
            break;
        case THREE_WET:
            descriptionSB.append(" <span style='color:" + Colour.GENERIC_SEX.toWebHexString() + ";'>Its surface constantly beads with wet droplets, which provides enough natural lubrication for sex.</span>");
            break;
        case FOUR_SLIMY:
            descriptionSB.append(" <span style='color:" + Colour.GENERIC_SEX.toWebHexString() + ";'>Its surface is always slimy and ready for penetration.</span>");
            break;
        case FIVE_SLOPPY:
            descriptionSB.append(" <span style='color:" + Colour.GENERIC_SEX.toWebHexString() + ";'>Its surface is always slimy, and the interior is constantly sloppy and ready for sex.</span>");
            break;
        case SIX_SOPPING_WET:
            descriptionSB.append(" <span style='color:" + Colour.GENERIC_SEX.toWebHexString() + ";'>It's constantly sopping wet from natural lubrication and ready for penetration.</span>");
            break;
        case SEVEN_DROOLING:
            descriptionSB.append(" <span style='color:" + Colour.GENERIC_SEX.toWebHexString() + ";'>It constantly drools with natural lubrication, and its sopping wet entrance is always ready for penetration.</span>");
            break;
        default:
            break;
    }
    // Ass elasticity & plasticity:
    switch(ass.getAnus().getOrificeAnus().getElasticity()) {
        case ZERO_UNYIELDING:
            descriptionSB.append(" <span style='color:" + Colour.GENERIC_SEX.toWebHexString() + ";'>It is extremely unyielding,");
            break;
        case ONE_RIGID:
            descriptionSB.append(" <span style='color:" + Colour.GENERIC_SEX.toWebHexString() + ";'>It takes a huge amount of effort to stretch it out,");
            break;
        case TWO_FIRM:
            descriptionSB.append(" <span style='color:" + Colour.GENERIC_SEX.toWebHexString() + ";'>It does not stretch very easily,");
            break;
        case THREE_FLEXIBLE:
            descriptionSB.append(" <span style='color:" + Colour.GENERIC_SEX.toWebHexString() + ";'>It reluctantly stretches out when used as a sexual orifice,");
            break;
        case FOUR_LIMBER:
            descriptionSB.append(" <span style='color:" + Colour.GENERIC_SEX.toWebHexString() + ";'>It is somewhat resistant to being stretched out,");
            break;
        case FIVE_STRETCHY:
            descriptionSB.append(" <span style='color:" + Colour.GENERIC_SEX.toWebHexString() + ";'>It stretches out fairly easily,");
            break;
        case SIX_SUPPLE:
            descriptionSB.append(" <span style='color:" + Colour.GENERIC_SEX.toWebHexString() + ";'>It stretches out very easily,");
            break;
        case SEVEN_ELASTIC:
            descriptionSB.append(" <span style='color:" + Colour.GENERIC_SEX.toWebHexString() + ";'>It is extremely elastic,");
            break;
        default:
            break;
    }
    switch(ass.getAnus().getOrificeAnus().getPlasticity()) {
        case ZERO_RUBBERY:
            descriptionSB.append(" and will instantly return to its original size.</span>");
            break;
        case ONE_SPRINGY:
            descriptionSB.append(" and returns to its original size within a matter of hours.</span>");
            break;
        case TWO_TENSILE:
            descriptionSB.append(" and returns to its original size within a day or so.</span>");
            break;
        case THREE_RESILIENT:
            descriptionSB.append(" and will return to its original size after a couple of days.</span>");
            break;
        case FOUR_ACCOMMODATING:
            descriptionSB.append(" and takes a while to return to its original size.</span>");
            break;
        case FIVE_YIELDING:
            descriptionSB.append(" and struggles to return to its original size.</span>");
            break;
        case SIX_MALLEABLE:
            descriptionSB.append(" and loses a good portion of its original tightness.</span>");
            break;
        case SEVEN_MOULDABLE:
            descriptionSB.append(" and once stretched out, it stays that way.</span>");
            break;
        default:
            break;
    }
    if (Main.game.isBodyHairEnabled()) {
        if (owner.isPlayer()) {
            switch(ass.getAnus().getAssHair()) {
                case ZERO_NONE:
                    descriptionSB.append(" There is no trace of any " + owner.getAssHairType().getName(owner) + " around your asshole.");
                    break;
                case ONE_STUBBLE:
                    descriptionSB.append(" You have a few strands of " + owner.getAssHairType().getFullDescription(owner, true) + " around your asshole.");
                    break;
                case TWO_MANICURED:
                    descriptionSB.append(" You have a very small amount of " + owner.getAssHairType().getFullDescription(owner, true) + " around your asshole.");
                    break;
                case THREE_TRIMMED:
                    descriptionSB.append(" You have a small amount of " + owner.getAssHairType().getFullDescription(owner, true) + " around your asshole.");
                    break;
                case FOUR_NATURAL:
                    descriptionSB.append(" You have a natural amount of " + owner.getAssHairType().getFullDescription(owner, true) + " around your asshole.");
                    break;
                case FIVE_UNKEMPT:
                    descriptionSB.append(" You have an unkempt mass of " + owner.getAssHairType().getFullDescription(owner, true) + " around your asshole.");
                    break;
                case SIX_BUSHY:
                    descriptionSB.append(" You have a thick, bushy mass of " + owner.getAssHairType().getFullDescription(owner, true) + " around your asshole.");
                    break;
                case SEVEN_WILD:
                    descriptionSB.append(" You have a wild, bushy mass of " + owner.getAssHairType().getFullDescription(owner, true) + " around your asshole.");
                    break;
            }
        } else {
            switch(ass.getAnus().getAssHair()) {
                case ZERO_NONE:
                    descriptionSB.append(" There is no trace of any " + owner.getAssHairType().getName(owner) + " around [npc.her] asshole.");
                    break;
                case ONE_STUBBLE:
                    descriptionSB.append(" [npc.She] has a few strands of " + owner.getAssHairType().getFullDescription(owner, true) + " around [npc.her] asshole.");
                    break;
                case TWO_MANICURED:
                    descriptionSB.append(" [npc.She] has a very small amount of " + owner.getAssHairType().getFullDescription(owner, true) + " around [npc.her] asshole.");
                    break;
                case THREE_TRIMMED:
                    descriptionSB.append(" [npc.She] has a small amount of " + owner.getAssHairType().getFullDescription(owner, true) + " around [npc.her] asshole.");
                    break;
                case FOUR_NATURAL:
                    descriptionSB.append(" [npc.She] has a natural amount of " + owner.getAssHairType().getFullDescription(owner, true) + " around [npc.her] asshole.");
                    break;
                case FIVE_UNKEMPT:
                    descriptionSB.append(" [npc.She] has an unkempt mass of " + owner.getAssHairType().getFullDescription(owner, true) + " around [npc.her] asshole.");
                    break;
                case SIX_BUSHY:
                    descriptionSB.append(" [npc.She] has a thick, bushy mass of " + owner.getAssHairType().getFullDescription(owner, true) + " around [npc.her] asshole.");
                    break;
                case SEVEN_WILD:
                    descriptionSB.append(" [npc.She] has a wild, bushy mass of " + owner.getAssHairType().getFullDescription(owner, true) + " around [npc.her] asshole.");
                    break;
            }
        }
    }
    for (OrificeModifier om : OrificeModifier.values()) {
        if (owner.hasAssOrificeModifier(om)) {
            if (owner.isPlayer()) {
                switch(om) {
                    case MUSCLE_CONTROL:
                        descriptionSB.append(" You have a series of internal muscles lining the inside of your [pc.asshole], allowing you to expertly squeeze and grip down on any intruding object.");
                        break;
                    case PUFFY:
                        descriptionSB.append(" The rim of your [pc.asshole] has swollen up into a puffy, doughnut-like ring.");
                        break;
                    case RIBBED:
                        descriptionSB.append(" The inside of your [pc.asshole] is lined with sensitive, fleshy ribs, which grant you extra pleasure when stimulated.");
                        break;
                    case TENTACLED:
                        descriptionSB.append(" Your [pc.asshole] is filled with tiny little tentacles, which wriggle and squirm with a mind of their own.");
                        break;
                }
            } else {
                switch(om) {
                    case MUSCLE_CONTROL:
                        descriptionSB.append(" [npc.She] has a series of internal muscles lining the inside of [npc.her] [npc.asshole], allowing [npc.herHim] to expertly squeeze and grip down on any intruding object.");
                        break;
                    case PUFFY:
                        descriptionSB.append(" The rim of [npc.her] [npc.asshole] has swollen up into a puffy, doughnut-like ring.");
                        break;
                    case RIBBED:
                        descriptionSB.append(" The inside of [npc.her] [npc.asshole] is lined with sensitive, fleshy ribs, which grant [npc.herHim] extra pleasure when stimulated.");
                        break;
                    case TENTACLED:
                        descriptionSB.append(" [npc.Her] [npc.asshole] is filled with tiny little tentacles, which wriggle and squirm with a mind of their own.");
                        break;
                }
            }
        }
    }
    return UtilText.parse(owner, descriptionSB.toString());
}
Also used : SexType(com.lilithsthrone.game.sex.SexType) PenetrationType(com.lilithsthrone.game.sex.PenetrationType) OrificeModifier(com.lilithsthrone.game.character.body.valueEnums.OrificeModifier)

Example 10 with OrificeModifier

use of com.lilithsthrone.game.character.body.valueEnums.OrificeModifier in project liliths-throne-public by Innoxia.

the class Body method saveAsXML.

@Override
public Element saveAsXML(Element parentElement, Document doc) {
    // Core:
    Element bodyCore = doc.createElement("bodyCore");
    parentElement.appendChild(bodyCore);
    CharacterUtils.addAttribute(doc, bodyCore, "piercedStomach", String.valueOf(this.isPiercedStomach()));
    CharacterUtils.addAttribute(doc, bodyCore, "height", String.valueOf(this.getHeightValue()));
    CharacterUtils.addAttribute(doc, bodyCore, "femininity", String.valueOf(this.getFemininity()));
    CharacterUtils.addAttribute(doc, bodyCore, "bodySize", String.valueOf(this.getBodySize()));
    CharacterUtils.addAttribute(doc, bodyCore, "muscle", String.valueOf(this.getMuscle()));
    CharacterUtils.addAttribute(doc, bodyCore, "pubicHair", String.valueOf(this.getPubicHair()));
    CharacterUtils.addAttribute(doc, bodyCore, "bodyMaterial", String.valueOf(this.getBodyMaterial()));
    CharacterUtils.addAttribute(doc, bodyCore, "genitalArrangement", String.valueOf(this.getGenitalArrangement()));
    for (BodyCoveringType bct : BodyCoveringType.values()) {
        Element element = doc.createElement("bodyCovering");
        bodyCore.appendChild(element);
        CharacterUtils.addAttribute(doc, element, "type", bct.toString());
        CharacterUtils.addAttribute(doc, element, "pattern", this.coverings.get(bct).getPattern().toString());
        CharacterUtils.addAttribute(doc, element, "modifier", this.coverings.get(bct).getModifier().toString());
        CharacterUtils.addAttribute(doc, element, "colourPrimary", this.coverings.get(bct).getPrimaryColour().toString());
        if (this.coverings.get(bct).isPrimaryGlowing()) {
            CharacterUtils.addAttribute(doc, element, "glowPrimary", String.valueOf(this.coverings.get(bct).isPrimaryGlowing()));
        }
        CharacterUtils.addAttribute(doc, element, "colourSecondary", this.coverings.get(bct).getSecondaryColour().toString());
        if (this.coverings.get(bct).isSecondaryGlowing()) {
            CharacterUtils.addAttribute(doc, element, "glowSecondary", String.valueOf(this.coverings.get(bct).isSecondaryGlowing()));
        }
        if (this.getBodyCoveringTypesDiscovered().contains(bct)) {
            CharacterUtils.addAttribute(doc, element, "discovered", String.valueOf(this.getBodyCoveringTypesDiscovered().contains(bct)));
        }
    }
    // Antennae:
    Element bodyAntennae = doc.createElement("antennae");
    parentElement.appendChild(bodyAntennae);
    CharacterUtils.addAttribute(doc, bodyAntennae, "type", this.antenna.getType().toString());
    CharacterUtils.addAttribute(doc, bodyAntennae, "rows", String.valueOf(this.antenna.getAntennaRows()));
    // Arm:
    Element bodyArm = doc.createElement("arm");
    parentElement.appendChild(bodyArm);
    CharacterUtils.addAttribute(doc, bodyArm, "type", this.arm.getType().toString());
    CharacterUtils.addAttribute(doc, bodyArm, "rows", String.valueOf(this.arm.getArmRows()));
    CharacterUtils.addAttribute(doc, bodyArm, "underarmHair", this.arm.getUnderarmHair().toString());
    // Ass:
    Element bodyAss = doc.createElement("ass");
    parentElement.appendChild(bodyAss);
    CharacterUtils.addAttribute(doc, bodyAss, "type", this.ass.getType().toString());
    CharacterUtils.addAttribute(doc, bodyAss, "assSize", String.valueOf(this.ass.getAssSize().getValue()));
    CharacterUtils.addAttribute(doc, bodyAss, "hipSize", String.valueOf(this.ass.getHipSize().getValue()));
    Element bodyAnus = doc.createElement("anus");
    parentElement.appendChild(bodyAnus);
    CharacterUtils.addAttribute(doc, bodyAnus, "wetness", String.valueOf(this.ass.anus.orificeAnus.wetness));
    CharacterUtils.addAttribute(doc, bodyAnus, "elasticity", String.valueOf(this.ass.anus.orificeAnus.elasticity));
    CharacterUtils.addAttribute(doc, bodyAnus, "plasticity", String.valueOf(this.ass.anus.orificeAnus.plasticity));
    CharacterUtils.addAttribute(doc, bodyAnus, "capacity", String.valueOf(this.ass.anus.orificeAnus.capacity));
    CharacterUtils.addAttribute(doc, bodyAnus, "stretchedCapacity", String.valueOf(this.ass.anus.orificeAnus.stretchedCapacity));
    CharacterUtils.addAttribute(doc, bodyAnus, "virgin", String.valueOf(this.ass.anus.orificeAnus.virgin));
    CharacterUtils.addAttribute(doc, bodyAnus, "bleached", String.valueOf(this.ass.anus.bleached));
    CharacterUtils.addAttribute(doc, bodyAnus, "assHair", this.ass.anus.assHair.toString());
    Element anusModifiers = doc.createElement("anusModifiers");
    bodyAnus.appendChild(anusModifiers);
    for (OrificeModifier om : OrificeModifier.values()) {
        CharacterUtils.addAttribute(doc, anusModifiers, om.toString(), String.valueOf(this.ass.anus.orificeAnus.hasOrificeModifier(om)));
    }
    // Breasts:
    Element bodyBreast = doc.createElement("breasts");
    parentElement.appendChild(bodyBreast);
    CharacterUtils.addAttribute(doc, bodyBreast, "type", this.breast.type.toString());
    CharacterUtils.addAttribute(doc, bodyBreast, "shape", this.breast.shape.toString());
    CharacterUtils.addAttribute(doc, bodyBreast, "size", String.valueOf(this.breast.size));
    CharacterUtils.addAttribute(doc, bodyBreast, "rows", String.valueOf(this.breast.rows));
    CharacterUtils.addAttribute(doc, bodyBreast, "milkStorage", String.valueOf(this.breast.milkStorage));
    CharacterUtils.addAttribute(doc, bodyBreast, "storedMilk", String.valueOf(this.breast.milkStored));
    CharacterUtils.addAttribute(doc, bodyBreast, "milkRegeneration", String.valueOf(this.breast.milkRegeneration));
    CharacterUtils.addAttribute(doc, bodyBreast, "nippleCountPerBreast", String.valueOf(this.breast.nippleCountPerBreast));
    Element bodyNipple = doc.createElement("nipples");
    parentElement.appendChild(bodyNipple);
    CharacterUtils.addAttribute(doc, bodyNipple, "elasticity", String.valueOf(this.breast.nipples.orificeNipples.elasticity));
    CharacterUtils.addAttribute(doc, bodyNipple, "plasticity", String.valueOf(this.breast.nipples.orificeNipples.plasticity));
    CharacterUtils.addAttribute(doc, bodyNipple, "capacity", String.valueOf(this.breast.nipples.orificeNipples.capacity));
    CharacterUtils.addAttribute(doc, bodyNipple, "stretchedCapacity", String.valueOf(this.breast.nipples.orificeNipples.stretchedCapacity));
    CharacterUtils.addAttribute(doc, bodyNipple, "virgin", String.valueOf(this.breast.nipples.orificeNipples.virgin));
    CharacterUtils.addAttribute(doc, bodyNipple, "pierced", String.valueOf(this.breast.nipples.pierced));
    CharacterUtils.addAttribute(doc, bodyNipple, "nippleSize", String.valueOf(this.breast.nipples.nippleSize));
    CharacterUtils.addAttribute(doc, bodyNipple, "nippleShape", this.breast.nipples.nippleShape.toString());
    CharacterUtils.addAttribute(doc, bodyNipple, "areolaeSize", String.valueOf(this.breast.nipples.areolaeSize));
    CharacterUtils.addAttribute(doc, bodyNipple, "areolaeShape", this.breast.nipples.areolaeShape.toString());
    Element nippleModifiers = doc.createElement("nippleModifiers");
    bodyNipple.appendChild(nippleModifiers);
    for (OrificeModifier om : OrificeModifier.values()) {
        CharacterUtils.addAttribute(doc, nippleModifiers, om.toString(), String.valueOf(this.breast.nipples.orificeNipples.hasOrificeModifier(om)));
    }
    Element bodyMilk = doc.createElement("milk");
    parentElement.appendChild(bodyMilk);
    CharacterUtils.addAttribute(doc, bodyMilk, "flavour", this.breast.milk.getFlavour().toString());
    Element milkModifiers = doc.createElement("milkModifiers");
    bodyMilk.appendChild(milkModifiers);
    for (FluidModifier fm : FluidModifier.values()) {
        CharacterUtils.addAttribute(doc, milkModifiers, fm.toString(), String.valueOf(this.breast.milk.hasFluidModifier(fm)));
    }
    // TODO transformativeEffects;
    // Ear:
    Element bodyEar = doc.createElement("ear");
    parentElement.appendChild(bodyEar);
    CharacterUtils.addAttribute(doc, bodyEar, "type", this.ear.type.toString());
    CharacterUtils.addAttribute(doc, bodyEar, "pierced", String.valueOf(this.ear.pierced));
    // Eye:
    Element bodyEye = doc.createElement("eye");
    parentElement.appendChild(bodyEye);
    CharacterUtils.addAttribute(doc, bodyEye, "type", this.eye.type.toString());
    CharacterUtils.addAttribute(doc, bodyEye, "eyePairs", String.valueOf(this.eye.eyePairs));
    CharacterUtils.addAttribute(doc, bodyEye, "irisShape", this.eye.irisShape.toString());
    CharacterUtils.addAttribute(doc, bodyEye, "pupilShape", this.eye.pupilShape.toString());
    // Face:
    Element bodyFace = doc.createElement("face");
    parentElement.appendChild(bodyFace);
    CharacterUtils.addAttribute(doc, bodyFace, "type", this.face.type.toString());
    CharacterUtils.addAttribute(doc, bodyFace, "piercedNose", String.valueOf(this.face.piercedNose));
    CharacterUtils.addAttribute(doc, bodyFace, "facialHair", this.face.facialHair.toString());
    Element bodyMouth = doc.createElement("mouth");
    parentElement.appendChild(bodyMouth);
    CharacterUtils.addAttribute(doc, bodyMouth, "elasticity", String.valueOf(this.face.mouth.orificeMouth.elasticity));
    CharacterUtils.addAttribute(doc, bodyMouth, "plasticity", String.valueOf(this.face.mouth.orificeMouth.plasticity));
    CharacterUtils.addAttribute(doc, bodyMouth, "capacity", String.valueOf(this.face.mouth.orificeMouth.capacity));
    CharacterUtils.addAttribute(doc, bodyMouth, "stretchedCapacity", String.valueOf(this.face.mouth.orificeMouth.stretchedCapacity));
    CharacterUtils.addAttribute(doc, bodyMouth, "virgin", String.valueOf(this.face.mouth.orificeMouth.virgin));
    CharacterUtils.addAttribute(doc, bodyMouth, "piercedLip", String.valueOf(this.face.mouth.piercedLip));
    CharacterUtils.addAttribute(doc, bodyMouth, "lipSize", String.valueOf(this.face.mouth.lipSize));
    Element mouthModifiers = doc.createElement("mouthModifiers");
    bodyMouth.appendChild(mouthModifiers);
    for (OrificeModifier om : OrificeModifier.values()) {
        CharacterUtils.addAttribute(doc, mouthModifiers, om.toString(), String.valueOf(this.face.mouth.orificeMouth.hasOrificeModifier(om)));
    }
    Element bodyTongue = doc.createElement("tongue");
    parentElement.appendChild(bodyTongue);
    CharacterUtils.addAttribute(doc, bodyTongue, "piercedTongue", String.valueOf(this.face.tongue.pierced));
    CharacterUtils.addAttribute(doc, bodyTongue, "tongueLength", String.valueOf(this.face.tongue.tongueLength));
    Element tongueModifiers = doc.createElement("tongueModifiers");
    bodyTongue.appendChild(tongueModifiers);
    for (TongueModifier tm : TongueModifier.values()) {
        CharacterUtils.addAttribute(doc, tongueModifiers, tm.toString(), String.valueOf(this.face.tongue.hasTongueModifier(tm)));
    }
    // Hair:
    Element bodyHair = doc.createElement("hair");
    parentElement.appendChild(bodyHair);
    CharacterUtils.addAttribute(doc, bodyHair, "type", this.hair.type.toString());
    CharacterUtils.addAttribute(doc, bodyHair, "length", String.valueOf(this.hair.length));
    CharacterUtils.addAttribute(doc, bodyHair, "hairStyle", this.hair.style.toString());
    // Horn:
    Element bodyHorn = doc.createElement("horn");
    parentElement.appendChild(bodyHorn);
    CharacterUtils.addAttribute(doc, bodyHorn, "type", this.horn.type.toString());
    CharacterUtils.addAttribute(doc, bodyHorn, "length", String.valueOf(this.horn.length));
    CharacterUtils.addAttribute(doc, bodyHorn, "rows", String.valueOf(this.horn.rows));
    // Leg:
    Element bodyLeg = doc.createElement("leg");
    parentElement.appendChild(bodyLeg);
    CharacterUtils.addAttribute(doc, bodyLeg, "type", this.leg.type.toString());
    // Penis:
    Element bodyPenis = doc.createElement("penis");
    parentElement.appendChild(bodyPenis);
    CharacterUtils.addAttribute(doc, bodyPenis, "type", this.penis.type.toString());
    CharacterUtils.addAttribute(doc, bodyPenis, "size", String.valueOf(this.penis.size));
    CharacterUtils.addAttribute(doc, bodyPenis, "girth", String.valueOf(this.penis.girth));
    CharacterUtils.addAttribute(doc, bodyPenis, "pierced", String.valueOf(this.penis.pierced));
    CharacterUtils.addAttribute(doc, bodyPenis, "virgin", String.valueOf(this.penis.virgin));
    Element penisModifiers = doc.createElement("penisModifiers");
    bodyPenis.appendChild(penisModifiers);
    for (PenisModifier pm : PenisModifier.values()) {
        CharacterUtils.addAttribute(doc, penisModifiers, pm.toString(), String.valueOf(this.penis.hasPenisModifier(pm)));
    }
    CharacterUtils.addAttribute(doc, bodyPenis, "elasticity", String.valueOf(this.penis.orificeUrethra.elasticity));
    CharacterUtils.addAttribute(doc, bodyPenis, "plasticity", String.valueOf(this.penis.orificeUrethra.plasticity));
    CharacterUtils.addAttribute(doc, bodyPenis, "capacity", String.valueOf(this.penis.orificeUrethra.capacity));
    CharacterUtils.addAttribute(doc, bodyPenis, "stretchedCapacity", String.valueOf(this.penis.orificeUrethra.stretchedCapacity));
    CharacterUtils.addAttribute(doc, bodyPenis, "urethraVirgin", String.valueOf(this.penis.orificeUrethra.virgin));
    Element urethraModifiers = doc.createElement("urethraModifiers");
    bodyPenis.appendChild(urethraModifiers);
    for (OrificeModifier om : OrificeModifier.values()) {
        CharacterUtils.addAttribute(doc, urethraModifiers, om.toString(), String.valueOf(this.penis.orificeUrethra.hasOrificeModifier(om)));
    }
    Element bodyTesticle = doc.createElement("testicles");
    parentElement.appendChild(bodyTesticle);
    CharacterUtils.addAttribute(doc, bodyTesticle, "testicleSize", String.valueOf(this.penis.testicle.testicleSize));
    CharacterUtils.addAttribute(doc, bodyTesticle, "cumProduction", String.valueOf(this.penis.testicle.cumStorage));
    CharacterUtils.addAttribute(doc, bodyTesticle, "numberOfTesticles", String.valueOf(this.penis.testicle.testicleCount));
    CharacterUtils.addAttribute(doc, bodyTesticle, "internal", String.valueOf(this.penis.testicle.internal));
    Element bodyCum = doc.createElement("cum");
    parentElement.appendChild(bodyCum);
    CharacterUtils.addAttribute(doc, bodyCum, "flavour", this.penis.testicle.cum.flavour.toString());
    Element cumModifiers = doc.createElement("cumModifiers");
    bodyCum.appendChild(cumModifiers);
    for (FluidModifier fm : FluidModifier.values()) {
        CharacterUtils.addAttribute(doc, cumModifiers, fm.toString(), String.valueOf(this.penis.testicle.cum.hasFluidModifier(fm)));
    }
    // TODO transformativeEffects;
    // Skin:
    Element bodySkin = doc.createElement("skin");
    parentElement.appendChild(bodySkin);
    CharacterUtils.addAttribute(doc, bodySkin, "type", this.skin.type.toString());
    // Tail:
    Element bodyTail = doc.createElement("tail");
    parentElement.appendChild(bodyTail);
    CharacterUtils.addAttribute(doc, bodyTail, "type", this.tail.type.toString());
    CharacterUtils.addAttribute(doc, bodyTail, "count", String.valueOf(this.tail.tailCount));
    // Vagina
    Element bodyVagina = doc.createElement("vagina");
    parentElement.appendChild(bodyVagina);
    CharacterUtils.addAttribute(doc, bodyVagina, "type", this.vagina.type.toString());
    CharacterUtils.addAttribute(doc, bodyVagina, "labiaSize", String.valueOf(this.vagina.labiaSize));
    CharacterUtils.addAttribute(doc, bodyVagina, "clitSize", String.valueOf(this.vagina.clitSize));
    CharacterUtils.addAttribute(doc, bodyVagina, "pierced", String.valueOf(this.vagina.pierced));
    CharacterUtils.addAttribute(doc, bodyVagina, "wetness", String.valueOf(this.vagina.orificeVagina.wetness));
    CharacterUtils.addAttribute(doc, bodyVagina, "elasticity", String.valueOf(this.vagina.orificeVagina.elasticity));
    CharacterUtils.addAttribute(doc, bodyVagina, "plasticity", String.valueOf(this.vagina.orificeVagina.plasticity));
    CharacterUtils.addAttribute(doc, bodyVagina, "capacity", String.valueOf(this.vagina.orificeVagina.capacity));
    CharacterUtils.addAttribute(doc, bodyVagina, "stretchedCapacity", String.valueOf(this.vagina.orificeVagina.stretchedCapacity));
    CharacterUtils.addAttribute(doc, bodyVagina, "virgin", String.valueOf(this.vagina.orificeVagina.virgin));
    CharacterUtils.addAttribute(doc, bodyVagina, "squirter", String.valueOf(this.vagina.orificeVagina.squirter));
    Element vaginaModifiers = doc.createElement("vaginaModifiers");
    bodyVagina.appendChild(vaginaModifiers);
    for (OrificeModifier om : OrificeModifier.values()) {
        CharacterUtils.addAttribute(doc, vaginaModifiers, om.toString(), String.valueOf(this.vagina.orificeVagina.hasOrificeModifier(om)));
    }
    Element bodyGirlcum = doc.createElement("girlcum");
    parentElement.appendChild(bodyGirlcum);
    CharacterUtils.addAttribute(doc, bodyGirlcum, "flavour", this.vagina.girlcum.flavour.toString());
    Element girlcumModifiers = doc.createElement("girlcumModifiers");
    bodyGirlcum.appendChild(girlcumModifiers);
    for (FluidModifier fm : FluidModifier.values()) {
        CharacterUtils.addAttribute(doc, girlcumModifiers, fm.toString(), String.valueOf(this.vagina.girlcum.hasFluidModifier(fm)));
    }
    // TODO transformativeEffects;
    // Wing:
    Element bodyWing = doc.createElement("wing");
    parentElement.appendChild(bodyWing);
    CharacterUtils.addAttribute(doc, bodyWing, "type", this.wing.type.toString());
    CharacterUtils.addAttribute(doc, bodyWing, "size", String.valueOf(this.wing.size));
    return parentElement;
}
Also used : FluidModifier(com.lilithsthrone.game.character.body.valueEnums.FluidModifier) TongueModifier(com.lilithsthrone.game.character.body.valueEnums.TongueModifier) Element(org.w3c.dom.Element) BodyCoveringType(com.lilithsthrone.game.character.body.types.BodyCoveringType) PenisModifier(com.lilithsthrone.game.character.body.valueEnums.PenisModifier) OrificeModifier(com.lilithsthrone.game.character.body.valueEnums.OrificeModifier)

Aggregations

OrificeModifier (com.lilithsthrone.game.character.body.valueEnums.OrificeModifier)14 PenetrationType (com.lilithsthrone.game.sex.PenetrationType)6 SexType (com.lilithsthrone.game.sex.SexType)6 ArrayList (java.util.ArrayList)6 PenisModifier (com.lilithsthrone.game.character.body.valueEnums.PenisModifier)5 TongueModifier (com.lilithsthrone.game.character.body.valueEnums.TongueModifier)5 BodyCoveringType (com.lilithsthrone.game.character.body.types.BodyCoveringType)4 FluidModifier (com.lilithsthrone.game.character.body.valueEnums.FluidModifier)4 Covering (com.lilithsthrone.game.character.body.Covering)2 BodyHair (com.lilithsthrone.game.character.body.valueEnums.BodyHair)2 BreastShape (com.lilithsthrone.game.character.body.valueEnums.BreastShape)2 CoveringModifier (com.lilithsthrone.game.character.body.valueEnums.CoveringModifier)2 NPC (com.lilithsthrone.game.character.npc.NPC)2 Subspecies (com.lilithsthrone.game.character.race.Subspecies)2 OrificeType (com.lilithsthrone.game.sex.OrificeType)2 HashMap (java.util.HashMap)2 EnchantmentEventListener (com.lilithsthrone.controller.eventListeners.EnchantmentEventListener)1 InventorySelectedItemEventListener (com.lilithsthrone.controller.eventListeners.InventorySelectedItemEventListener)1 InventoryTooltipEventListener (com.lilithsthrone.controller.eventListeners.InventoryTooltipEventListener)1 SetContentEventListener (com.lilithsthrone.controller.eventListeners.SetContentEventListener)1