From 93ae59c563af121e043746ef3703cdee24a9884a Mon Sep 17 00:00:00 2001 From: Daniel Parra Date: Tue, 20 Feb 2024 17:17:24 -0500 Subject: [PATCH] added self to buoy_positions --- .../subjugator_missions/start_signal.py | 24 ++++++++++++------- 1 file changed, 15 insertions(+), 9 deletions(-) diff --git a/SubjuGator/command/subjugator_missions/subjugator_missions/start_signal.py b/SubjuGator/command/subjugator_missions/subjugator_missions/start_signal.py index 7efa7539f..029545edc 100644 --- a/SubjuGator/command/subjugator_missions/subjugator_missions/start_signal.py +++ b/SubjuGator/command/subjugator_missions/subjugator_missions/start_signal.py @@ -3,13 +3,19 @@ class StartSignal(SubjuGatorMission): - buoy_positions = [[5, 10, 3], [6, 8, 5], [3, 12, 10]] # x, y, z displacements - async def run(self, args): - for i in len(buoy_positions): - self.send_feedback(f'Travelling to Buoy {i}') - await self.go(self.move().right(buoy_positions[i][0]).up(buoy_positions[i][1].forward(buoy_positions[i][2]))) - self.send_feedback(f'Back to Origin') - await self.go(self.move().right(-buoy_positions[i][0]).up(-buoy_positions[i][1].forward(-buoy_positions[i][2]))) - - + buoy_positions = [[5, 10, 3], [6, 8, 5], [3, 12, 10]] # x, y, z displacements + async def run(self, args): + for i in len(self.buoy_positions): + self.send_feedback(f"Travelling to Buoy {i}") + await self.go( + self.move() + .right(self.buoy_positions[i][0]) + .up(self.buoy_positions[i][1].forward(self.buoy_positions[i][2])), + ) + self.send_feedback("Back to Origin") + await self.go( + self.move() + .right(-self.buoy_positions[i][0]) + .up(-self.buoy_positions[i][1].forward(-self.buoy_positions[i][2])), + )