louisg Posted October 20, 2015 Share Posted October 20, 2015 I was wondering if someone has already done a commented disassembly of Breakout. There are still some mysteries to me, for example how the paddle reflects the ball. I found this in the manual: "The paddle is divided into five sections. Note that the ball bounces off each section at progressively smaller angles afterthe third, seventh, and eleventh hit. After the twelfth hit,the angle returns to its original size." This makes it sound like it's tracking the number of times the ball has hit one of the paddle sections, and depending on how many hits that section has taken, it'll reflect at a different angle... Anyway, if nobody's disassembled and commented Breakout I may be up to the task! 2 Quote Link to comment Share on other sites More sharing options...
Thomas Jentzsch Posted October 20, 2015 Share Posted October 20, 2015 I haven't full analyzed the code yet, but the manual is not correct here. The algorithm is a bit more complicated. The angle and speed of the ball changes with every 4th hit, up to 12 hits. So far the manual is correct. But It does not wrap around. However, if you hit one of the top 3 rows, it is set to a fixed angle and maximum speed. Also I haven't found those five sections yet. Instead there are only two (left and right), which influence the angle, but not the speed. 2 Quote Link to comment Share on other sites More sharing options...
louisg Posted November 4, 2015 Author Share Posted November 4, 2015 Good info! I was watching a friend play this game this last weekend, and trying to figure out the ball bounce mechanic. I might just video cap it to be sure, but what might make sense is that when the ball hits a brick, it cannot register another collision until it hits blank space. This would explain it going through bricks on its way back down but also being able to oscillate between sets of bricks if they are separated by space. It would also mean they wouldn't have to do logic to reposition the ball at the edge of the brick after a hit. I keep thinking what the simplest possible physics model is for Breakout; what'd require the very least amount of logic. Quote Link to comment Share on other sites More sharing options...
Nukey Shay Posted November 22, 2015 Share Posted November 22, 2015 but what might make sense is that when the ball hits a brick, it cannot register another collision until it hits blank space. This would explain it going through bricks on its way back down but also being able to oscillate between sets of bricks if they are separated by space. That's Super Breakout (which needs this capability for it's "progressive" variation). In the original game, no additional bricks can be hit until the ball collides with a paddle or the top border (when ram $EB is negative, no brick collisions are used). This and direction changes following a hit are ignored for "breakthrough" variations. Simply doing away with the negative check in Breakout creates a problems elsewhere. You can't rely on empty space without adding additional code to the collision routine, or the ball will behave very strangely (like erasing entire horizontal rows). Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.