For our exercise, we’re going to use a simple but powerful idea; if we instruct a sprite to turn a little and move a little, we create a curved line. To create a circle, the sprite needs to keep turning and moving until it makes a complete turn. Repeating the circle in a controlled way creates patterns.
Scratch has long been able to connect to the physical world by way of a PicoBoard, which is an external device that plugs into the USB port of a computer or a Raspberry Pi. The PicoBoard (available from SparkFun–www.sparkfun.com/products/10311)measures resistance, sound, button clicks, and includes a slider control. In this project, I’ll show you how to use a PicoBoard’s alligator clips to measure resistance and just to kick up the experiment a bit, we’ll use a thermistor to measure the resistance of water as it warms or cools.
In the space maze game, the rocket will have the ability to fly up, right, down, and left at varying speeds. The player must navigate the rocket through a field of UFOs to land on the head. The maze, however, is randomly generated, requiring the player to carefully pick a path from the home base to the head.