simplified ferris wheel code