@@ -0,0 +1,1060 @@
+from crispy.localevents import LocalEvent%0Afrom crispy.dice import Dice, Check%0A%0A%0Aclass EventCheck(LocalEvent):%0A  %0A  bonus = dict()%0A  dc = dict()%0A  %0A  def __init__(self, **kwargs):%0A    bonus = 0%0A    for name in self.bonus:%0A      bonus += getattr(kwargs%5Bname%5D, self.bonus%5Bname%5D)%0A    dc = 10%0A    for name in self.dc:%0A      dc += getattr(kwargs%5Bname%5D, self.dc%5Bname%5D)%0A    self.check = Check(bonus=bonus, dc=dc)%0A%0A  def finalize(self):%0A    check = self.check%0A    if check.is_critical():%0A      self.on_critical()%0A    elif check.is_fumble():%0A      self.on_fumble()%0A    elif check.is_success():%0A      self.on_success()%0A    else:%0A      self.on_failure()%0A%0A  def on_success(self):%0A    pass%0A%0A  def on_failure(self):%0A    pass%0A  %0A  def on_critical(self):%0A    self.on_success()%0A    %0A  def on_fumble(self):%0A    self.on_failure()%0A%0A%0Aclass EventRoll(LocalEvent):%0A  %0A  die = dict()%0A%0A  def __init__(self, **kwargs):%0A    self.dice = Dice()%0A    die = list()%0A    for name in self.die:%0A      die.append(getattr(kwargs%5Bname%5D, self.die%5Bname%5D))%0A    for d in die:%0A      self.dice.add_die(d)%0A%0A

Create core.py