Collect the rocks. 1. Use the arrow keys to load the instructions. 2. Press space bar to broadcast them to the rover. How many broadcasts did it take you?
The prompt was broadcasting, which made me think of transmission towers, semaphores and how the internet sometimes feels like sending messages into a silent void with little feedback. This is literally true for Mars Rovers, where there's a 3-30 min speed of light delay between us sending data from Earth, and a machine receiving it on Mars. I decided to make a small emulation of that, where you, the Earthling, directs the rover to pick up samples. It's so far away that you must prepare instructions in advance, and send them off with no way of correcting a mistake! A more dedicated coder would have perfected the perspective, making the rover move in a more predictable way. As it is, it shrinks as it moves into the distance, but doesn't converge to a point like it should. My dodgy method of shrinking/shortening its movements as it moves further away means that if you move it in a square it won't return to the exact same location. If anyone asks that was deliberate. ;) (Makes it a challenge) Future improvements: * Calculate perspective properly so it moves the same distance going up/down. * Add a left/right component when moving further away (again, for perspective) * Gamification (scoreboard, winner celebration etc..) Learned: * Preplan maths to avoid cumbersome nested blocks * The broadcast and wait block is useful for de-bouncing key presses * Used custom blocks for the first time * Used lists for the first time * Broadcast messages can be stored in lists