Tweak to include human-readable rig sizes, and more tweaks to the attribute grouping definitions

This commit is contained in:
blitzmann
2018-10-14 03:42:33 -04:00
parent d21ccef269
commit 46ece5da0c
3 changed files with 75 additions and 32 deletions

View File

@@ -562,6 +562,15 @@ class Unit(EqBase):
self.name = None
self.displayName = None
@property
def rigSizes(self):
return {
1: "Small",
2: "Medium",
3: "Large",
4: "X-Large"
}
@property
def translations(self):
""" This is a mapping of various tweaks that we have to do between the internal representation of an attribute
@@ -585,8 +594,8 @@ class Unit(EqBase):
lambda d: d,
lambda u: ""),
"Sizeclass": (
lambda v: v,
lambda d: d,
lambda v: self.rigSizes[v],
lambda d: next(i for i in self.rigSizes.keys() if self.rigSizes[i] == 'Medium'),
lambda u: ""),
"Absolute Percent": (
lambda v: (v * 100),