コード例 #1
0
        public static double GetWetness(Hediff organ)
        {
            double amount = 0;

            // Getting wetness
            CompHediffBodyPart hediffComp = organ.TryGetComp <CompHediffBodyPart>();

            if (hediffComp != null && hediffComp.FluidAmmount > 0)
            {
                Dyspareunia.Log("Fluid: " + hediffComp.FluidType + ". Amount: " + hediffComp.FluidAmmount + ". Modifier: " + hediffComp.FluidModifier);
                amount = hediffComp.FluidAmmount * hediffComp.FluidModifier / organ.pawn.BodySize;
            }

            // Adding s***n to the amount of fluids
            foreach (Hediff_Semen hediff in organ.pawn.health.hediffSet.GetHediffs <Hediff_Semen>())
            {
                if (hediff.Part == organ.Part)
                {
                    Dyspareunia.Log("Found " + hediff.Severity + " s***n in " + hediff.Part.Label);
                    amount += hediff.Severity;
                }
            }

            return(amount / organ.pawn.BodySize * 0.1);
        }
コード例 #2
0
ファイル: Utility.cs プロジェクト: ALEXALIGHT/newcode
        public static float GetCumVolume(this Pawn pawn, CompHediffBodyPart part)
        {
            float res;

            try
            {
                res = part.FluidAmmount * part.FluidModifier * pawn.BodySize / pawn.RaceProps.baseBodySize * Rand.Range(0.8f, 1.2f) * RJWSettings.cum_on_body_amount_adjust * 0.3f;
            }
            catch (NullReferenceException)
            {
                res = 0.0f;
            }
            if (pawn.Has(Quirk.Messy))
            {
                res *= Rand.Range(4.0f, 8.0f);
            }

            return(res);
        }
コード例 #3
0
ファイル: Utility.cs プロジェクト: ALEXALIGHT/newcode
        public static float GetCumVolume(this Pawn pawn, List <Hediff> hediffs)
        {
            CompHediffBodyPart part = hediffs?.FindAll((Hediff hed) => hed.def.defName.ToLower().Contains("penis")).InRandomOrder().FirstOrDefault()?.TryGetComp <CompHediffBodyPart>();

            if (part == null)
            {
                part = hediffs?.FindAll((Hediff hed) => hed.def.defName.ToLower().Contains("ovipositorf")).InRandomOrder().FirstOrDefault()?.TryGetComp <CompHediffBodyPart>();
            }
            if (part == null)
            {
                part = hediffs?.FindAll((Hediff hed) => hed.def.defName.ToLower().Contains("ovipositorm")).InRandomOrder().FirstOrDefault()?.TryGetComp <CompHediffBodyPart>();
            }
            if (part == null)
            {
                part = hediffs?.FindAll((Hediff hed) => hed.def.defName.ToLower().Contains("tentacle")).InRandomOrder().FirstOrDefault()?.TryGetComp <CompHediffBodyPart>();
            }


            return(pawn.GetCumVolume(part));
        }