Need help with Brick Breaker game
I making this brick breaker game, but sometimes the ball moves either straight up and down or horizontally. This causes the player to be messed up. How do I make a rule that when this happens the ball changes directions?
Comments
Rule:
if Self.Motion.Linear Velocity.X = 0
Change Attribute Self.Motion.Linear Velocity.X to [something else not 0]
For the [something else not 0] you could use the random function to pick a random number so it does not always do the same thing.
Hope that helps.
Simple debugging, but usually helps find the problem quickly.
Please don't create multiple threads for the same question.
To make this work in a pong game you'd want to use the rules I have set up that are triggered by the space bar, to be triggered when the ball hits a wall or a paddle.
Hope this helps.