As soon as you want to start encoding "rules" for "encoding the allowed transformations of your data," then congratulations, you've invented something called a "function." Functions are rules for expressing what you are allowed to do.
fn wield(Wizard, Wand) // Wizards can wield wands.
fn wield(Warrior, Sword) // Warriors can wield swords.
fn capability(Player, wield_fn=wield(Player, Weapon)) // Players can wield weapons.
Now there's no way to violate these rules unless your users can compile functions and pass them into your code.>There is no need to figure out “which class does the rule about paladins vs werewolves go in?” The rule goes in a rulebook, end of story. Like I said, Inform7 is amazing.
I've never seen someone so impressed by global functions before.