Пример #1
0
        public static WooHooConfig GetWooHooConfig()
        {
            WooHooConfig whc = new WooHooConfig();

            XmlDbData xdb = XmlDbData.ReadData("WooHooForMoneyConfig");

            if ((xdb != null) && (xdb.Tables != null))
            {
                XmlDbTable table;

                if (xdb.Tables.TryGetValue("WooHooConfig", out table) && (table != null))
                {
                    foreach (XmlDbRow row in table.Rows)
                    {
                        whc.pay           = row.GetInt("pay");
                        whc.skill         = (WooHooSkill)row.GetInt("skill");
                        whc.pregnancy     = row.GetInt("preg");
                        whc.TeenPregnancy = row.GetBool("tpreg");
                        whc.STD           = row.GetInt("std");
                        whc.Moodlets      = row.GetBool("moodlets");
                    }
                }
            }
            return(whc);
        }
Пример #2
0
        public static void HandlePostWoohoo(Sim client, Sim solicitor, ObjectGuid bedId)
        {
            //Get paid once
            if (client == WooHooBedList.listWP[bedId].client)
            {
                WooHooConfig whc = GetWooHooConfig();

                GetPaid(client, solicitor, whc.pay, whc.skill);

                if (whc.Moodlets)
                {
                    SetMoodlets(client, solicitor);
                }

                Consequence(client, solicitor, whc.STD);
            }
        }
Пример #3
0
            // Methods
            public override bool BabyMade()
            {
                WooHooConfig whc = CommonMethods.GetWooHooConfig();

                Boolean tryForBaby = whc.pregnancy > 0 ? true : false;

                //If teen pregnacnies are not allowed, check both participants are ya/adults
                if (tryForBaby && !whc.TeenPregnancy)
                {
                    Boolean actorOk = false;
                    if (base.Actor.SimDescription.Gender == Sims3.SimIFace.CAS.CASAgeGenderFlags.Male || (base.Actor.SimDescription.Gender == Sims3.SimIFace.CAS.CASAgeGenderFlags.Female && base.Actor.SimDescription.YoungAdultOrAdult))
                    {
                        actorOk = true;
                    }

                    Boolean targetOk = false;
                    if (base.Target.SimDescription.Gender == Sims3.SimIFace.CAS.CASAgeGenderFlags.Male || (base.Target.SimDescription.Gender == Sims3.SimIFace.CAS.CASAgeGenderFlags.Female && base.Target.SimDescription.YoungAdultOrAdult))
                    {
                        targetOk = true;
                    }

                    if (!actorOk || !targetOk)
                    {
                        tryForBaby = false;
                    }
                }
                //Check sims are of different gender
                if (base.Actor.SimDescription.Gender == base.Target.SimDescription.Gender)
                {
                    tryForBaby = false;
                }
                //StyledNotification.Show(new StyledNotification.Format("tryForBaby: " + tryForBaby + " " + whc.pregnancy + "%", StyledNotification.NotificationStyle.kGameMessagePositive));
                if (CommonMethods.FuckMeUp(whc.pregnancy) && tryForBaby)
                {
                    float babyMadeChance = ((Bed)base.Actor.Posture.Container).BabyMadeChance;
                    return(Pregnancy.ShouldImpregnate(base.Actor, base.Target, babyMadeChance));
                }
                else
                {
                    return(false);
                }
            }