We now have physical events being passed in a very understandable format. We have a little bit of work left to do to translate these events (which are still specifically about the physical condition of the device) into commands for the player.
The math in this section is almost as abstract as the previous task, because the design specifies that the ship's acceleration is going to be based on how strongly the device's tilt aligns with the ship's facing direction, and the speed with which it turns will be based on how much the direction of tilt runs across the ship's facing.
Save any other open files and open
pythagoreandistance module is loaded; we'll need ...