def __init__(self, character): State.__init__(self, "retreat", character) self.old_state_name = None self.collected_distance = 0 self.distance_to_move = 40 # rest after the real action self.rest_time = .5 self.collected_rest_time = 0
def __init__(self, character): State.__init__(self, "hitten", character) self.collected_distance = 0 self.distance_to_move = None self.old_state_name = None # stun after the blow self.rest_time = character.rest_time_needed self.collected_rest_time = 0
def __init__(self, character): State.__init__(self, "exploring", character)
def __init__(self, character): State.__init__(self, "hunting", character)
def __init__(self, character): State.__init__(self, "waiting", character) self.waiting_time = cbrandom.randint(0, 20)
def __init__(self, character): State.__init__(self, "attacking", character)
def __init__(self, character): State.__init__(self, "controlled", character)