def create_minion(self, player): def poisonous(amount, target): if type(target) is Minion and not target.dead: target.die(self) minion = Minion(2, 3, MINION_TYPE.BEAST) minion.bind("did_damage", poisonous) minion.bind_once("silenced", lambda: minion.unbind("did_damage", poisonous)) return minion
def create_minion(self, player): def poisonous(amount, target): if type(target) is Minion and not target.dead: target.die(self) minion = Minion(1, 1) minion.stealth = True minion.bind("did_damage", poisonous) minion.bind_once("silenced", lambda: minion.unbind("did_damage", poisonous)) return minion