diff options
| author | Karl Kurbjun <kkurbjun@gmail.com> | 2009-10-04 05:29:40 +0000 |
|---|---|---|
| committer | Karl Kurbjun <kkurbjun@gmail.com> | 2009-10-04 05:29:40 +0000 |
| commit | 5d0ac8db6f26624d259e94873f0c27a0533d0815 (patch) | |
| tree | d8501c58adeee81ddd1d1eafaf596c237e35d9a2 /apps/plugins | |
| parent | 9c881f712e69ac08886a1c7527abf45954e3501e (diff) | |
| download | rockbox-5d0ac8db6f26624d259e94873f0c27a0533d0815.zip rockbox-5d0ac8db6f26624d259e94873f0c27a0533d0815.tar.gz rockbox-5d0ac8db6f26624d259e94873f0c27a0533d0815.tar.bz2 rockbox-5d0ac8db6f26624d259e94873f0c27a0533d0815.tar.xz | |
Brickmania: Fix paddle position jumps when an N powerup is picked up.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@22909 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/plugins')
| -rw-r--r-- | apps/plugins/brickmania.c | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/apps/plugins/brickmania.c b/apps/plugins/brickmania.c index 5e0f7fd..059d3c3 100644 --- a/apps/plugins/brickmania.c +++ b/apps/plugins/brickmania.c @@ -276,9 +276,9 @@ CONFIG_KEYPAD == SANSA_M200_PAD #endif /* The time (in ms) for one iteration through the game loop - decrease this - to speed up the game - note that current_tick is (currently) only accurate - to 10ms. -*/ + * to speed up the game - note that current_tick is (currently) only accurate + * to 10ms. + */ #define CYCLETIME 30 #define TOPMARGIN MAX(BRICK_HEIGHT, FIXED3(8)) @@ -291,10 +291,8 @@ CONFIG_KEYPAD == SANSA_M200_PAD /* Brickmania was originally designed for the H300, other targets should scale * the speed up/down as needed based on the screen height. */ -#define SPEED_SCALE_H(y) \ - FIXED3_DIV(GAMESCREEN_HEIGHT, FIXED3(176)/(y) ) -#define SPEED_SCALE_W(x) \ - FIXED3_DIV(GAMESCREEN_WIDTH, FIXED3(220)/(x) ) +#define SPEED_SCALE_H(y) FIXED3_DIV(GAMESCREEN_HEIGHT, FIXED3(176)/(y) ) +#define SPEED_SCALE_W(x) FIXED3_DIV(GAMESCREEN_WIDTH, FIXED3(220)/(x) ) /* These are all used as ball speeds depending on where the ball hit the * paddle. @@ -1368,7 +1366,8 @@ static int brickmania_game_loop(void) for(k=0;k<used_balls;k++) ball[k].glue=false; flip_sides=false; - pad_pos_x += pad_width - (PAD_WIDTH/2); + + pad_pos_x += (pad_width-PAD_WIDTH)/2; pad_width = PAD_WIDTH; break; case 5: /* Flip the paddle */ |