'When initialized from cache (after a server reboot), set up
the AI state.'

def at_init(self):

    self.ndb.is_patrolling = (self.db.patrolling and (not self.db.is_dead))
    self.ndb.is_attacking = False
    self.ndb.is_hunting = False
    self.ndb.is_immortal = (self.db.immortal or self.db.is_dead)
