Search in sources :

Example 16 with GameCharacter

use of com.lilithsthrone.game.character.GameCharacter in project liliths-throne-public by Innoxia.

the class Body method getPregnancyDetails.

public String getPregnancyDetails(GameCharacter owner) {
    descriptionSB = new StringBuilder();
    if (owner.isVisiblyPregnant()) {
        GameCharacter father = owner.getPregnantLitter().getFather();
        if (father.isPlayer()) {
            descriptionSB.append("<p><span style='color:" + Colour.GENERIC_ARCANE.toWebHexString() + ";'>From one of your sexual encounters, you've ended up impregnating [npc.name].</span>");
        } else {
            descriptionSB.append("<p><span style='color:" + Colour.GENERIC_ARCANE.toWebHexString() + ";'>From one of [npc.her] sexual encounters, [npc.name] has ended up getting impregnated by " + father.getName() + ".</span>");
        }
        if (owner.hasStatusEffect(StatusEffect.PREGNANT_1)) {
            descriptionSB.append(" [npc.Her] belly is only a little swollen, as [npc.she]'s only in the first stage of pregnancy.");
        } else if (owner.hasStatusEffect(StatusEffect.PREGNANT_2)) {
            descriptionSB.append(" [npc.Her] belly is noticeably swollen, as [npc.she]'s well into [npc.her] pregnancy.");
        } else {
            descriptionSB.append(" [npc.Her] belly is massively swollen, and although [npc.she]'s clearly ready for it, [npc.she] hasn't decided to give birth just yet.");
        }
        descriptionSB.append("</p>");
    }
    if (!owner.getLittersBirthed().isEmpty()) {
        descriptionSB.append("<p>" + "<span style='color:" + Colour.GENERIC_ARCANE.toWebHexString() + ";'>" + "[npc.Name] has given birth " + Util.intToString(owner.getLittersBirthed().size()) + " " + (owner.getLittersBirthed().size() == 1 ? "time" : "times") + ".</span>");
        for (Litter litter : owner.getLittersBirthed()) {
            int daysSpentPregnant = litter.getDayOfBirth() - litter.getDayOfConception();
            if (litter.getFather().isPlayer()) {
                descriptionSB.append("</br>On day " + litter.getDayOfConception() + ", you impregnated [npc.herHim], and " + Util.intToString(daysSpentPregnant) + " day" + (daysSpentPregnant != 1 ? "s" : "") + " later, [npc.she] gave birth to ");
            } else {
                descriptionSB.append("</br>On day " + litter.getDayOfConception() + ", " + litter.getFather().getName() + " impregnated [npc.her], and " + Util.intToString(daysSpentPregnant) + " day" + (daysSpentPregnant != 1 ? "s" : "") + " later, [npc.she] gave birth to ");
            }
            descriptionSB.append(litter.getBirthedDescriptionList());
            descriptionSB.append(".");
        }
        descriptionSB.append("</p>");
    }
    if (Main.game.getPlayer().isVisiblyPregnant()) {
        for (PregnancyPossibility pp : Main.game.getPlayer().getPotentialPartnersAsMother()) {
            if (pp.getFather() == owner) {
                descriptionSB.append("<p>" + "<span style='color:" + Colour.GENERIC_ARCANE.toWebHexString() + ";'>From one of your sexual encounters, you've been impregnated, and it's possible that [npc.name] is the father.</span>" + "</p>");
                break;
            }
        }
    }
    if (!Main.game.getPlayer().getLittersBirthed().isEmpty()) {
        int fatheredLitters = 0;
        for (Litter litter : Main.game.getPlayer().getLittersBirthed()) {
            if (litter.getFather() == owner) {
                fatheredLitters++;
            }
        }
        if (fatheredLitters != 0) {
            descriptionSB.append("<p>" + "<span style='color:" + Colour.GENERIC_ARCANE.toWebHexString() + ";'>" + "[npc.Name] is the father of some of your children, and has, in total, impregnated you " + Util.intToString(fatheredLitters) + " " + (fatheredLitters == 1 ? "time" : "times") + ".</span>");
            for (Litter litter : Main.game.getPlayer().getLittersBirthed()) {
                int daysSpentPregnant = litter.getDayOfBirth() - litter.getDayOfConception();
                if (litter.getFather() == owner) {
                    descriptionSB.append("</br>On day " + litter.getDayOfConception() + ", [npc.she] impregnated you, and " + Util.intToString(daysSpentPregnant) + " day" + (daysSpentPregnant > 1 ? "s" : "") + " later, you gave birth to " + litter.getBirthedDescriptionList() + ".");
                }
            }
            descriptionSB.append("</p>");
        }
    }
    return UtilText.parse(owner, descriptionSB.toString());
}
Also used : Litter(com.lilithsthrone.game.character.Litter) PregnancyPossibility(com.lilithsthrone.game.character.PregnancyPossibility) GameCharacter(com.lilithsthrone.game.character.GameCharacter)

Aggregations

GameCharacter (com.lilithsthrone.game.character.GameCharacter)16 ArrayList (java.util.ArrayList)8 OrificeType (com.lilithsthrone.game.sex.OrificeType)4 Fetish (com.lilithsthrone.game.character.fetishes.Fetish)3 NPC (com.lilithsthrone.game.character.npc.NPC)3 TestNPC (com.lilithsthrone.game.character.npc.dominion.TestNPC)3 Response (com.lilithsthrone.game.dialogue.responses.Response)3 InventorySelectedItemEventListener (com.lilithsthrone.controller.eventListeners.InventorySelectedItemEventListener)2 InventoryTooltipEventListener (com.lilithsthrone.controller.eventListeners.InventoryTooltipEventListener)2 TooltipInformationEventListener (com.lilithsthrone.controller.eventListeners.TooltipInformationEventListener)2 Attribute (com.lilithsthrone.game.character.attributes.Attribute)2 CoverableArea (com.lilithsthrone.game.character.body.CoverableArea)2 Perk (com.lilithsthrone.game.character.effects.Perk)2 StatusEffect (com.lilithsthrone.game.character.effects.StatusEffect)2 GenericAndrogynousNPC (com.lilithsthrone.game.character.npc.GenericAndrogynousNPC)2 GenericFemaleNPC (com.lilithsthrone.game.character.npc.GenericFemaleNPC)2 GenericMaleNPC (com.lilithsthrone.game.character.npc.GenericMaleNPC)2 SpecialAttack (com.lilithsthrone.game.combat.SpecialAttack)2 Spell (com.lilithsthrone.game.combat.Spell)2 DialogueNodeOld (com.lilithsthrone.game.dialogue.DialogueNodeOld)2