Thread: Please help!!
View Single Post
Super Moderator
Status: Offline
Posts: 250
Join Date: Dec 2012
Location: Frosno, Ca
Default 05-02-2018, 08:54 PM

Originally Posted by elc317 View Post
I am looking for a way to start and stop ferris wheel for a class project using the color of the bump and a 2 button switch. I have attached project, Please help.
Events is the right way to do this but you are making it too complex.
  1. Create a Boolean in the world. (I called mine "fRun" and initialze it to false.
  2. Use the "when the mouse is clicked on the green switch" event to set fRun to true.
  3. Create a "when the mouse is clicked on the red button" event and use is to set fRun to false.
  4. Change the While event to "while fRun is true"
  5. In the While event clear out the begin setting and set the During section to ferriswheelSpin.
  6. Take out everything in ferriswheel Spin except the instructions to make the wheels spin.
  7. Put all the wheel spin statements within a "Do Together" block.

The fRun Boolean is now controlled by the push buttons on the switch and the event will cause the wheel to spin as long as fRun is true and the world is running.
Attached Files
File Type: a2w Proj7_V1.a2w (158.1 KB, 26 views)

Mark Henwood
Reply With Quote