1
0
Fork 0
forked from len0rd/rockbox

Brickmania update for the Gigabeat: fixed menu and smaller game area to make the gameplay closer to targets

with landscape oriented displays (and more challenging too).


git-svn-id: svn://svn.rockbox.org/rockbox/trunk@12310 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
Nicolas Pennequin 2007-02-14 22:59:36 +00:00
parent 7a395a23bf
commit 5a29fe18d4
3 changed files with 22 additions and 5 deletions

View file

@ -9,7 +9,11 @@ brickmania_pads.320x240x16.bmp
brickmania_break.320x240x16.bmp brickmania_break.320x240x16.bmp
brickmania_powerups.320x240x16.bmp brickmania_powerups.320x240x16.bmp
#else #else
#if (LCD_WIDTH == 240) && (LCD_HEIGHT == 320)
brickmania_menu_bg.240x320x16.bmp
#else
brickmania_menu_bg.220x176x16.bmp brickmania_menu_bg.220x176x16.bmp
#endif
brickmania_bricks.220x176x16.bmp brickmania_bricks.220x176x16.bmp
brickmania_pads.220x176x16.bmp brickmania_pads.220x176x16.bmp
brickmania_break.220x176x16.bmp brickmania_break.220x176x16.bmp

Binary file not shown.

After

Width:  |  Height:  |  Size: 225 KiB

View file

@ -183,6 +183,8 @@ extern const fb_data brickmania_bricks[];
*/ */
#define CYCLETIME 30 #define CYCLETIME 30
#define GAMESCREEN_HEIGHT LCD_HEIGHT
#define PAD_WIDTH 56 #define PAD_WIDTH 56
#define PAD_HEIGHT 7 #define PAD_HEIGHT 7
#define PAD_POS_Y LCD_HEIGHT - 7 #define PAD_POS_Y LCD_HEIGHT - 7
@ -227,19 +229,22 @@ extern const fb_data brickmania_bricks[];
#define CYCLETIME 30 #define CYCLETIME 30
/* Offsets for LCDS > 220x176 */ /* Offsets for LCDS > 220x176 */
#define XOFS ((LCD_WIDTH-220)/2)
#define YOFS ((LCD_HEIGHT-176)/2) #define GAMESCREEN_HEIGHT 176
#define PAD_WIDTH 40 #define PAD_WIDTH 40
#define PAD_HEIGHT 5 #define PAD_HEIGHT 5
#define PAD_POS_Y LCD_HEIGHT - 7 #define PAD_POS_Y GAMESCREEN_HEIGHT - 7
#define BRICK_HEIGHT 8 #define BRICK_HEIGHT 8
#define BRICK_WIDTH 21 #define BRICK_WIDTH 21
#define BALL 5 #define BALL 5
#define HALFBALL 3 #define HALFBALL 3
#define LEFTMARGIN 5 #define LEFTMARGIN (LCD_WIDTH-220)/2 + 5
#define TOPMARGIN 30 #define TOPMARGIN 30
#define XOFS ((LCD_WIDTH-220)/BRICK_WIDTH/2)*BRICK_WIDTH
#define YOFS ((LCD_HEIGHT-176)/BRICK_HEIGHT/2)*BRICK_HEIGHT
#define MENU_BMPHEIGHT 20 #define MENU_BMPHEIGHT 20
#define MENU_BMPWIDTH 112 #define MENU_BMPWIDTH 112
@ -272,6 +277,8 @@ extern const fb_data brickmania_bricks[];
*/ */
#define CYCLETIME 50 #define CYCLETIME 50
#define GAMESCREEN_HEIGHT LCD_HEIGHT
#define PAD_WIDTH 30 #define PAD_WIDTH 30
#define PAD_HEIGHT 5 #define PAD_HEIGHT 5
#define PAD_POS_Y LCD_HEIGHT - 7 #define PAD_POS_Y LCD_HEIGHT - 7
@ -330,6 +337,8 @@ extern const fb_data brickmania_bricks[];
*/ */
#define CYCLETIME 50 #define CYCLETIME 50
#define GAMESCREEN_HEIGHT LCD_HEIGHT
#define PAD_WIDTH 30 #define PAD_WIDTH 30
#define PAD_HEIGHT 5 #define PAD_HEIGHT 5
#define PAD_POS_Y LCD_HEIGHT - 5 #define PAD_POS_Y LCD_HEIGHT - 5
@ -373,6 +382,8 @@ extern const fb_data brickmania_bricks[];
*/ */
#define CYCLETIME 75 #define CYCLETIME 75
#define GAMESCREEN_HEIGHT LCD_HEIGHT
#define PAD_WIDTH 30 #define PAD_WIDTH 30
#define PAD_HEIGHT 3 #define PAD_HEIGHT 3
#define PAD_POS_Y LCD_HEIGHT - 5 #define PAD_POS_Y LCD_HEIGHT - 5
@ -412,6 +423,8 @@ extern const fb_data brickmania_bricks[];
*/ */
#define CYCLETIME 30 #define CYCLETIME 30
#define GAMESCREEN_HEIGHT LCD_HEIGHT
#define PAD_WIDTH 40 #define PAD_WIDTH 40
#define PAD_HEIGHT 5 #define PAD_HEIGHT 5
#define PAD_POS_Y LCD_HEIGHT - 7 #define PAD_POS_Y LCD_HEIGHT - 7
@ -1634,7 +1647,7 @@ int game_loop(void)
if (ball[k].pos_y<= 0) if (ball[k].pos_y<= 0)
ball[k].y = ball[k].y*-1; ball[k].y = ball[k].y*-1;
/* bottom line */ /* bottom line */
else if (ball[k].pos_y+BALL >= LCD_HEIGHT) { else if (ball[k].pos_y+BALL >= GAMESCREEN_HEIGHT) {
if (used_balls>1) { if (used_balls>1) {
used_balls--; used_balls--;
ball[k].pos_x = ball[used_balls].pos_x; ball[k].pos_x = ball[used_balls].pos_x;