@Mathgirl made this project where there's a ball that goes on a wavy line, without objects. the color of the line is black.
I didn't use any "touching colour" code.
It's kind of hard to explain...
I'm trying to come up with an explanation, I'll reply when I come up with one.
This isn't the best explanation/tutorial, but I guess it'll have to do. Also, sorry it took so long.
This is the code I used for the wavy line (sorry if you're confused by sin and cos):
To make the ball appear to bounce on this line, I basically used the code in the Set Position block shown above, except replacing the "Value" value with the ball's X position:
Again, I'm sorry if you're confused. I'll try to come up with a better tutorial. (Can anyone help me explain?)
@Mathgirl, AMAZING PROJECT!!! Could I potentially use some of the code in a future project? I would of course give credit! Amazing work, (I think it deserves a feature!)
Yes, it would. :D
Also, thanks! :D I forgot to put it in the project, but all of the code is free to use! :D
Sorry for the late reply, I was asleep.
I forgot to mention an important part of the ball's code. Whoops!
You don't need to use the first two blocks, I just used them to make the ball small and grey.
Also, to make the ball respond to tilting, add this rule:
i added the gravity and touching ground code. also the set value to 0 blocks are useless.
I know, but I added them anyway. It's a weird habit I have. (Most programming languages need you to set a value to something (like 0, for example) at first.)
I don't know why that's happening...