yasuki_core.ruleset.Ruleset#
- class Ruleset(clan_alignments, clan_aliases=<factory>, off_clan_surcharge=2)[source]#
The arc-specific rules constants the engine reads. Bundling them behind one object lets a later arc’s ruleset be swapped in wholesale rather than editing scattered literals.
- Attributes:
- clan_alignments
frozensetofstr The legal Clan Alignments, as canonical
normalize_clan()slugs. A card’s clan counts toward alignment only if it resolves into this set; every other clan name is unaligned.- clan_aliases
dictmappingstrtostr Alternate clan slugs that resolve to a canonical member of
clan_alignments(e.g. Naga is the same alignment as Akasha in this arc). Applied before the membership test. Default empty.- off_clan_surcharge
int Extra Gold a Recruit costs when the card has a Clan Alignment the recruiting seat does not share. Default 2.
- clan_alignments
Methods
Ruleset.__init__(clan_alignments[, ...])Ruleset.alignment(clan_name)The canonical Clan Alignment slug
clan_namedenotes, or None when it is not a legal alignment in this ruleset.Attributes
clan_alignmentsclan_aliasesoff_clan_surcharge