i am trying to make a simple pong game where if you miss, you lose. I am trying to find a way of making the sprite hit the paddle so it bounces off. when i do it it just gets stuck on the paddle vibrating.
Please help!!!!!!!!!!
Offline
I had trouble with this. Here is what I would do.
<blocks>
<when green flag clicked>
<forever if> <touching[paddle]
<point in direction(((180<-><direction> ))
<move(5 )steps>
</blocks>
The point in direction blocks make the ball bounce.
The move 5 steps stops it from getting stuck on the paddle.
Offline
also, u need to add this block:
<if on edge, bounce>
Offline
daydreamgirl wrote:
I had trouble with this. Here is what I would do.
<blocks>
<when green flag clicked>
<forever if> <touching[paddle]
<point in direction(((180<-><direction> ))
<move(5 )steps>
</blocks>
The point in direction blocks make the ball bounce.
The move 5 steps stops it from getting stuck on the paddle.
Not so simple. It depends where the paddle is located. Use this project to help you: http://scratch.mit.edu/projects/yambanshee/371970/download
Offline