Skip to content
Eric Veilleux edited this page Nov 7, 2020 · 5 revisions

utils/tools.py

find_shot(agent, target, cap_=6, can_aerial=True, can_double_jump=True, can_jump=True, can_ground=True)

Returns an instance of ground_shot, jump_shot, double_jump, or Aerial if it could find one. If not, it will return None.

  • agent - An instance of VirxERLU. If you're running this from an instance of VirxERLU, pass in self.
  • target - A tuple of Vectors like (left, right)
  • cap_ - The max number of seconds into the future that the method should go. Default & max is 6.
  • can_aerial - Whether or not to returns instances of Aerial. Default is True.
  • can_double_jump - Whether or not to returns instances of double_jump. Default is True.
  • can_jump - Whether or not to returns instances of jump_shot. Default is True.
  • can_ground - Whether or not to returns instances of ground_shot. Default is True.

find_any_shot(agent, cap_=6, can_aerial=True, can_double_jump=True, can_jump=True, can_ground=True)

Returns an instance of ground_shot, jump_shot, double_jump, or Aerial if it could find one. If not, it will return None.

  • agent - An instance of VirxERLU. If you're running this from an instance of VirxERLU, pass in self.
  • cap_ - The max number of seconds into the future that the method should go. Default & max is 6.
  • can_aerial - Whether or not to returns instances of Aerial. Default is True.
  • can_double_jump - Whether or not to returns instances of double_jump. Default is True.
  • can_jump - Whether or not to returns instances of jump_shot. Default is True.
  • can_ground - Whether or not to returns instances of ground_shot. Default is True.

find_ground_shot(agent, target, cap_=6)

Returns an instance of ground_shot (see utils/routines.py) if it could find one. If not, it will return None.

  • agent - An instance of VirxERLU. If you're running this from an instance of VirxERLU, pass in self.
  • target - A tuple of Vectors like (left, right)
  • cap_ - The max number of seconds into the future that the method should go. Default & max is 6.

find_any_ground_shot(agent, cap_=6)

Returns an instance of ground_shot (see utils/routines.py) if it could find one. If not, it will return None.

  • agent - An instance of VirxERLU. If you're running this from an instance of VirxERLU, pass in self.
  • cap_ - The max number of seconds into the future that the method should go. Default & max is 6.

find_jump_shot(agent, target, cap_=6)

Returns an instance of jump_shot (see utils/routines.py) if it could find one. If not, it will return None.

  • agent - An instance of VirxERLU. If you're running this from an instance of VirxERLU, pass in self.
  • target - A tuple of Vectors like (left, right)
  • cap_ - The max number of seconds into the future that the method should go. Default & max is 6.

find_any_jump_shot(agent, cap_=6)

Returns an instance of jump_shot (see utils/routines.py) if it could find one. If not, it will return None.

  • agent - An instance of VirxERLU. If you're running this from an instance of VirxERLU, pass in self.
  • cap_ - The max number of seconds into the future that the method should go. Default & max is 6.

find_double_jump(agent, target, cap_=6)

Returns an instance of double_jump (see utils/routines.py) if it could find one. If not, it will return None.

  • agent - An instance of VirxERLU. If you're running this from an instance of VirxERLU, pass in self.
  • target - A tuple of Vectors like (left, right)
  • cap_ - The max number of seconds into the future that the method should go. Default & max is 6.

find_any_double_jump(agent, cap_=6)

Returns an instance of double_jump (see utils/routines.py) if it could find one. If not, it will return None.

  • agent - An instance of VirxERLU. If you're running this from an instance of VirxERLU, pass in self.
  • cap_ - The max number of seconds into the future that the method should go. Default & max is 6.

find_aerial(agent, target, cap_=6)

Returns an instance of Aerial (see utils/routines.py) if it could find one. If not, it will return None.

  • agent - An instance of VirxERLU. If you're running this from an instance of VirxERLU, pass in self.
  • target - A tuple of Vectors like (left, right)
  • cap_ - The max number of seconds into the future that the method should go. Default & max is 6.

find_any_aerial(agent, cap_=6)

Returns an instance of Aerial (see utils/routines.py) if it could find one. If not, it will return None.

  • agent - An instance of VirxERLU. If you're running this from an instance of VirxERLU, pass in self.
  • cap_ - The max number of seconds into the future that the method should go. Default & max is 6.