예제 #1
0
            public override bool Test(Sim a, BotMakingStation target, bool isAutonomous, ref GreyedOutTooltipCallback greyedOutTooltipCallback)
            {
                /*
                 * if (!a.Household.CanAddSpeciesToHousehold(CASAgeGenderFlags.Human, 0x1, true))
                 * {
                 *  string localizedString = BotMakingStation.LocalizeString(a.IsFemale, "HouseholdIsFull", new object[0x0]);
                 *  greyedOutTooltipCallback = InteractionInstance.CreateTooltipCallback(localizedString);
                 *  return false;
                 * }
                 */
                if ((a != null) && (a.SkillManager != null))
                {
                    BotBuildingSkill element = a.SkillManager.GetElement(SkillNames.BotBuilding) as BotBuildingSkill;
                    if ((element != null) && (element.SkillLevel > BotMakingStation.kMinSkillToCreateServoBot))
                    {
                        if (a.FamilyFunds >= BotMakingStation.kCostToBuildServoBot)
                        {
                            if (target.InUse && !target.mActorsUsingMe.Contains(a))
                            {
                                greyedOutTooltipCallback = InteractionInstance.CreateTooltipCallback(BotMakingStation.LocalizeString("StationInUse", new object[0x0]));
                                return(false);
                            }
                            return(true);
                        }

                        greyedOutTooltipCallback = InteractionInstance.CreateTooltipCallback(BotMakingStation.LocalizeString(a.IsFemale, "LackTheSimoleansToCreateServobot", new object[0x0]));
                    }
                    else
                    {
                        greyedOutTooltipCallback = InteractionInstance.CreateTooltipCallback(BotMakingStation.LocalizeString(a.IsFemale, "LackTheRequiredSkillLevelToCreateAServobot", new object[0x0]));
                    }
                }
                return(false);
            }
예제 #2
0
            public bool TestUse(BotMakingStation obj)
            {
                if (!TestRepaired(obj))
                {
                    return(false);
                }

                return(obj.UseCount == 0 && obj.InWorld);
            }
예제 #3
0
            protected override bool Satisfies(Sim actor, Sim target, BotMakingStation obj, bool isAutonomous, ref GreyedOutTooltipCallback callback)
            {
                if (!base.Satisfies(actor, target, obj, isAutonomous, ref callback))
                {
                    return(false);
                }

                return(CommonPregnancy.SatisfiesTryForBaby(actor, target, "BotMakerTryForBaby", isAutonomous, true, ref callback));
            }
예제 #4
0
            protected override bool Satisfies(Sim actor, Sim target, BotMakingStation obj, bool isAutonomous, ref GreyedOutTooltipCallback callback)
            {
                if (!base.Satisfies(actor, target, obj, isAutonomous, ref callback))
                {
                    return(false);
                }

                return(CommonWoohoo.SatisfiesWoohoo(actor, target, "BotMakerWoohoo", isAutonomous, true, true, ref callback));
            }
예제 #5
0
 public override string GetInteractionName(Sim actor, BotMakingStation target, InteractionObjectPair iop)
 {
     return(Common.LocalizeEAString(actor.IsFemale, "Gameplay/Excel/Socializing/Action:NRaasTryForBaby", new object[0]));
 }
예제 #6
0
 public override string GetInteractionName(Sim actor, BotMakingStation target, InteractionObjectPair iop)
 {
     return(Common.LocalizeEAString(actor.IsFemale, "Gameplay/Excel/Socializing/Action:NRaasRiskyWooHoo", new object[0]) + Common.LocalizeEAString(false, "NRaas.Woohooer:RiskyChance", new object[] { Woohooer.Settings.GetRiskyBabyMadeChance(actor) }));
 }
예제 #7
0
            public override bool Test(Sim a, BotMakingStation target, bool isAutonomous, ref GreyedOutTooltipCallback greyedOutTooltipCallback)
            {
                /*
                if (!a.Household.CanAddSpeciesToHousehold(CASAgeGenderFlags.Human, 0x1, true))
                {
                    string localizedString = BotMakingStation.LocalizeString(a.IsFemale, "HouseholdIsFull", new object[0x0]);
                    greyedOutTooltipCallback = InteractionInstance.CreateTooltipCallback(localizedString);
                    return false;
                }
                */
                if ((a != null) && (a.SkillManager != null))
                {
                    BotBuildingSkill element = a.SkillManager.GetElement(SkillNames.BotBuilding) as BotBuildingSkill;
                    if ((element != null) && (element.SkillLevel > BotMakingStation.kMinSkillToCreateServoBot))
                    {
                        if (a.FamilyFunds >= BotMakingStation.kCostToBuildServoBot)
                        {
                            if (target.InUse && !target.mActorsUsingMe.Contains(a))
                            {
                                greyedOutTooltipCallback = InteractionInstance.CreateTooltipCallback(BotMakingStation.LocalizeString("StationInUse", new object[0x0]));
                                return false;
                            }
                            return true;
                        }

                        greyedOutTooltipCallback = InteractionInstance.CreateTooltipCallback(BotMakingStation.LocalizeString(a.IsFemale, "LackTheSimoleansToCreateServobot", new object[0x0]));
                    }
                    else
                    {
                        greyedOutTooltipCallback = InteractionInstance.CreateTooltipCallback(BotMakingStation.LocalizeString(a.IsFemale, "LackTheRequiredSkillLevelToCreateAServobot", new object[0x0]));
                    }
                }
                return false;
            }
예제 #8
0
 public override string GetInteractionName(Sim actor, BotMakingStation target, InteractionObjectPair iop)
 {
     return base.GetInteractionName(actor, target, new InteractionObjectPair(sOldSingleton, target));
 }
예제 #9
0
 public override string GetInteractionName(Sim actor, BotMakingStation target, InteractionObjectPair iop)
 {
     return(base.GetInteractionName(actor, target, new InteractionObjectPair(sOldSingleton, target)));
 }