public static CoverageMask GetCoverageMask(CombatBodyPart bodyPart) { switch (bodyPart) { case CombatBodyPart.Abdomen: return(CoverageMask.OuterwearAbdomen | CoverageMask.UnderwearAbdomen); case CombatBodyPart.Chest: return(CoverageMask.OuterwearChest | CoverageMask.UnderwearChest); case CombatBodyPart.Foot: return(CoverageMask.Feet); case CombatBodyPart.Hand: return(CoverageMask.Hands); case CombatBodyPart.Head: return(CoverageMask.Head); case CombatBodyPart.LowerArm: return(CoverageMask.OuterwearLowerArms | CoverageMask.UnderwearLowerArms); case CombatBodyPart.LowerLeg: return(CoverageMask.OuterwearLowerLegs | CoverageMask.UnderwearLowerLegs); case CombatBodyPart.UpperArm: return(CoverageMask.OuterwearUpperArms | CoverageMask.UnderwearUpperArms); case CombatBodyPart.UpperLeg: return(CoverageMask.OuterwearUpperLegs | CoverageMask.UnderwearUpperLegs); default: return(CoverageMask.Unknown); } }
public List <WorldObject> GetArmorLayers(CombatBodyPart bodyPart) { var coverageMask = BodyParts.GetCoverageMask(bodyPart); var equipped = Creature.EquippedObjects.Values.Where(e => e is Clothing && (e.ClothingPriority & coverageMask) != 0).ToList(); return(equipped); }
public BodyPartProbability(CombatBodyPart bodyPart, float probability) { BodyPart = bodyPart; Probability = probability; }