Пример #1
0
        protected bool Cares(SimDescription witness, DisgracefulActionType type, int reportChance, out bool testFriendship)
        {
            if (witness.AssignedRole is RolePaparazzi)
            {
                testFriendship = false;
                return(true);
            }

            testFriendship = true;
            switch (type)
            {
            case DisgracefulActionType.BiteSomeoneInPublic:
                if (witness.IsVampire)
                {
                    return(false);
                }
                break;

            case DisgracefulActionType.Cheating:
            case DisgracefulActionType.WooHooInPublic:
                if (ManagerFlirt.AreRomantic(Sim, witness))
                {
                    testFriendship = false;
                }
                break;

            case DisgracefulActionType.WooHooWithOccult:
                if (witness.IsPlayableGhost)
                {
                    return(false);
                }

                if (witness.OccultManager.HasAnyOccultType())
                {
                    return(false);
                }
                break;
            }

            if (testFriendship)
            {
                if (AddScoring("DisgraceWitness", reportChance, ScoringLookup.OptionType.Chance, witness) >= 0)
                {
                    return(false);
                }
            }

            return(true);
        }
Пример #2
0
        protected override IEnumerable <ulong> GetOptions()
        {
            List <ulong> results = new List <ulong>();

            ManagerFlirt manager = StoryProgression.Main.Flirts;

            SimDescription me = Manager.SimDescription;

            foreach (SimDescription other in StoryProgression.Main.Sims.All)
            {
                if (other.LotHome == null)
                {
                    continue;
                }

                if (other.IsMarried)
                {
                    continue;
                }

                if (string.IsNullOrEmpty(other.FirstName))
                {
                    continue;
                }

                ulong otherArranged = StoryProgression.Main.GetValue <ArrangedMarriageOption, ulong>(other);
                if ((otherArranged != 0) && (otherArranged != me.SimDescriptionId))
                {
                    continue;
                }

                if (!manager.CanHaveAutonomousRomance(manager, other, me, false))
                {
                    continue;
                }

                results.Add(other.SimDescriptionId);
            }

            return(results);
        }