def __init__(self, robot, actions): Action.__init__(self, robot) self._actions = actions self._cursor = 0 for ac in self._actions: ac.event_done = SequenceAction.FinishNormal
def __init__(self, robot, stype, strike): Action.__init__(self, robot) self._stype = stype self._strike = strike self._state = self.NOT_CHARGED
def __init__(self, robot, dest, stype, strike): Action.__init__(self, robot) aturn = AcTurn(robot, dest-robot['k.position']) ashoot = AcShoot(robot, stype, strike) self._action = SequenceAction(robot, [aturn, ashoot])