Esempio n. 1
0
        private static IEnumerable <BodyPartRecord> cacheValueRace_BodyPartRecords(Pawn pawn)
        {
            IEnumerable <BodyPartDef>    hairyParts = BodyHairHelper.WhatSkinCanGetHairy(pawn);
            IEnumerable <BodyPartRecord> validParts = pawn.RaceProps.body.AllParts.Where(x => hairyParts.Contains(x.def));

            return(validParts);
        }
Esempio n. 2
0
 public static BodyPartRecord Where(this Pawn pawn, BodyPartDef where)
 {
     if (where == BodyPartDefOf.Chest)
     {
         return(BodyCache.Chest(pawn));
     }
     else if (where == BodyPartDefOf.Groin)
     {
         return(BodyCache.Groin(pawn));
     }
     else if (where == BodyPartDefOf.LifeStages_ReproductiveOrgans)
     {
         return(BodyCache.LifeStages_ReproductiveOrgans(pawn));
     }
     else
     {
         return(BodyHairHelper.WhatPart(pawn));
     }
 }