intention.py 514B

12345678910111213141516171819202122
  1. # coding: utf-8
  2. import typing
  3. from synergine2.simulation import Intention
  4. class MoveToIntention(Intention):
  5. def __init__(
  6. self,
  7. to: typing.Tuple[int, int],
  8. gui_action: typing.Any,
  9. ) -> None:
  10. self.to = to
  11. self.gui_action = gui_action
  12. self.path = None # type: typing.List[typing.Tuple[int, int]]
  13. def get_data(self) -> dict:
  14. return {
  15. 'to': self.to,
  16. 'gui_action': self.gui_action,
  17. 'path': self.path,
  18. }