class UniversesBeyondClassTemplate(ClassVectorTemplate):
"""Saga Vector template with Universes Beyond frame treatment."""
template_suffix = 'Universes Beyond'
# Color Maps
pinlines_color_map = {
**pinlines_color_map.copy(),
'W': [246, 247, 241],
'U': [0, 131, 193],
'B': [44, 40, 33],
'R': [237, 66, 31],
'G': [5, 129, 64],
'Gold': [239, 209, 107],
'Land': [165, 150, 132],
'Artifact': [227, 228, 230],
'Colorless': [227, 228, 230]
}
"""
* Colors
"""
@auto_prop_cached
def textbox_colors(self) -> list[str]:
"""list[str]: Support identity by color limit, fallback to pinline colors."""
if self.is_within_color_limit:
return [n for n in self.identity]
return [self.pinlines]
@auto_prop_cached
def twins_colors(self) -> str:
"""str: Universes Beyond variant texture name."""
return f'{self.twins} Beyond'
"""
* Groups
"""
@auto_prop_cached
def background_group(self) -> LayerSet:
"""LayerSet: Universes Beyond variant group."""
return psd.getLayerSet(f'{LAYERS.BACKGROUND} Beyond')
@auto_prop_cached
def textbox_group(self) -> LayerSet:
"""LayerSet: Universes Beyond variant group. Must be enabled."""
group = psd.getLayerSet(f"{LAYERS.TEXTBOX} Beyond")
group.visible = True
return group