Discuss Scratch

Sirveyor
Scratcher
2 posts

Touch sensing works moving right to left but not left to right

I have a table tennis game with two paddle sprites and a ball sprite. Paddles have a fixed x coordinate and only move in the y direction on opposite ends of the stage. When the ball sprite moves from right to left and touches the left paddle sprite it bounces off as expected. However when the ball sprite moves left to right it will pass through the right paddle sprite and bounce off the stage edged and then senses the right paddle and starts bouncing from the back of the paddle to the stage edge repeatedly. The touch detection seems to be working only if the ball sprite is moving right to left. Is this a limitation of the sensing scripts?
Sirveyor
Scratcher
2 posts

Touch sensing works moving right to left but not left to right

After posting I tried a random direction bounce instead of a computed deflection and it all works.
Problem solved.

Powered by DjangoBB