1
0
Fork 0
forked from len0rd/rockbox

Brickmania: Correct a bug in the ball/brick collision (large screens (640x480) did not collide with the bottom row of bricks)

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@21944 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
Karl Kurbjun 2009-07-18 01:57:06 +00:00
parent 1c746e5b9e
commit 8a1cda66f0

View file

@ -1309,8 +1309,11 @@ int game_loop(void)
#endif #endif
} }
/* Somewhere in here collision checking is done b/w ball and
* brick.
*/
for(k=0;k<used_balls;k++) { for(k=0;k<used_balls;k++) {
if (ball[k].pos_y <160) { if (ball[k].pos_y < PAD_POS_Y) {
if (brick[i*10+j].used==1) { if (brick[i*10+j].used==1) {
if ((ball[k].pos_x+ball[k].x+HALFBALL >= if ((ball[k].pos_x+ball[k].x+HALFBALL >=
brickx && brickx &&