コード例 #1
0
        protected override ThoughtState CurrentSocialStateInternal(Pawn pawn, Pawn other)
        {
            ThoughtState result;

            if (!other.RaceProps.Humanlike || other.Dead)
            {
                result = false;
            }
            else if (!RelationsUtility.PawnsKnowEachOther(pawn, other))
            {
                result = false;
            }
            else if (!RelationsUtility.IsDisfigured(other))
            {
                result = false;
            }
            else if (!pawn.health.capacities.CapableOf(PawnCapacityDefOf.Sight))
            {
                result = false;
            }
            else
            {
                result = true;
            }
            return(result);
        }
コード例 #2
0
        protected override ThoughtState CurrentSocialStateInternal(Pawn pawn, Pawn other)
        {
            if (!other.RaceProps.Humanlike || !RelationsUtility.PawnsKnowEachOther(pawn, other))
            {
                return(false);
            }
            if (RelationsUtility.IsDisfigured(other))
            {
                return(false);
            }
            if (!pawn.health.capacities.CapableOf(PawnCapacityDefOf.Sight))
            {
                return(false);
            }
            int num = other.story.traits.DegreeOfTrait(TraitDefOf.Beauty);

            if (num == 1)
            {
                return(ThoughtState.ActiveAtStage(0));
            }
            if (num == 2)
            {
                return(ThoughtState.ActiveAtStage(1));
            }
            return(false);
        }
コード例 #3
0
        protected override ThoughtState CurrentSocialStateInternal(Pawn pawn, Pawn other)
        {
            if (!other.RaceProps.Humanlike || !RelationsUtility.PawnsKnowEachOther(pawn, other))
            {
                return(false);
            }
            if (RelationsUtility.IsDisfigured(other))
            {
                return(false);
            }
            if (!pawn.health.capacities.CapableOf(PawnCapacityDefOf.Sight))
            {
                return(false);
            }
            float statValue = other.GetStatValue(StatDefOf.PawnBeauty);

            if (statValue >= 2f)
            {
                return(ThoughtState.ActiveAtStage(1));
            }
            if (statValue >= 1f)
            {
                return(ThoughtState.ActiveAtStage(0));
            }
            return(false);
        }