Unit 6, Lesson 6 Stage 16


I cannot figure out how to make the slider work with the motorcycle. Here is what I created: https://studio.code.org/projects/applab/30zwFzB4q3nFL-fgBQu7K-AbKSXgNe7meG6tZdAh40Q

I do not know how to get it to move with the slider


So you have the onEvent for when you change the slider and you are changing the value of variable speed when this happens but you only are setting the “y” property of the motorcycle on the button events. If you want to set a property when the slider changes you can either put the setProperty call in the function updateSpeed or into the onEvent for the slider change.

Now this will not make the motorcycle move, just change y position when the slider is changed.

[solution removed]