"""
TEXT = None
- GLYPHS = None
+ GLYPHS = (ACTION_GLYPHS.NOTHING,)
+ MSB_GLYPH = None
def __init__(self, required_bits, **data):
self.required_bits = required_bits
class DoNothing(LocationAction):
TEXT = "No effect."
- GLYPHS = (ACTION_GLYPHS.NOTHING,)
def perform_action(self, board, location):
pass
class LoseHealthOrMSB(LocationAction):
TEXT = "Lose {HEALTH} or {MSB}."
- GLYPHS = (ACTION_GLYPHS.MSB, ACTION_GLYPHS.DAMAGE)
+ MSB_GLYPH = ACTION_GLYPHS.DAMAGE
def perform_action(self, board, location):
if not self.check_and_clear_MSB(board.player):
class LoseHealthOrMSBAndSetBits(LocationAction):
TEXT = "Lose {HEALTH} or {MSB}, then set %(location_bits)s."
- GLYPHS = (ACTION_GLYPHS.SET_BITS, ACTION_GLYPHS.MSB, ACTION_GLYPHS.DAMAGE)
+ GLYPHS = (ACTION_GLYPHS.SET_BITS,)
+ MSB_GLYPH = ACTION_GLYPHS.DAMAGE
def perform_action(self, board, location):
if not self.check_and_clear_MSB(board.player):
class GainHealthAndClearBitsOrMSB(LocationAction):
TEXT = "Gain {HEALTH}, then clear %(location_bits)s or {MSB}."
- GLYPHS = (ACTION_GLYPHS.HEAL, ACTION_GLYPHS.MSB, ACTION_GLYPHS.CLEAR_BITS)
+ GLYPHS = (ACTION_GLYPHS.HEAL,)
+ MSB_GLYPH = ACTION_GLYPHS.CLEAR_BITS
def perform_action(self, board, location):
board.gain_health()