top of page
Search
  • mziegen

Matthew's Coding Blog: Brick Breaker Interactivity

For the unfinished project, recreating my own brick breaker game was my focal point. As previously mentioned, I have not yet finished the project, but am moving along just fine in the matter. I've created a paddle for my ball to hit off of (keyboard), a ball, 36 bricks (as template examples), a game over screen if one fails to keep the ball from hitting the ground, and a reset button (mouse code). All rectangles are set to 50x50, the ball is 30x30, and our paddle is 70x8. On a 600x600 canvas, on function setup I have set my ball to start at 300 on the x-scale and 200 on the y-scale because it gives the player more time to react and place the paddle under the incoming ball. The paddle is set at 300 on the x-scale and 580 on the y-scale. The ball moves at a speed of 4, both along the x and y scales. Since I have not found a way to make blocks disappear once hitting them, I have set the ball to contact the lowest layer and bounce back by setting the high point to 160. The only way the game can end is if the ball goes above 600 on y-axis in which the reset button is set to restart the game.


The code:


The game:




10 views0 comments

Recent Posts

See All

Matthew's Coding Blog: Final

Unfortunately, I am mere inches away from finishing the product. This month has set my life into what feels like an irreversible tailspin. With that being said, I did my best to get the point across a

Matthew's Coding Blog: Final Brainstorm

For the final project, I would like to create a basketball game. It will be viewed from a first person's point of view. Not sure how I will go about it, coding-wise; However I have certain ideas I wou

Matthew's Coding Blog: Algorithmic Bias

There is biasness in the online recruitment tools used there is a discovery made in Amazon that more than half of the percentage were male workers and that they held over more than 70% of the company

Post: Blog2_Post
bottom of page