diff --git a/context.c b/context.c index 849b753..8efaa81 100644 --- a/context.c +++ b/context.c @@ -88,6 +88,10 @@ void walkContext(int key_press) { current_context = &lookContext; interfacePrint("Look where?"); break; + case 'i': + current_context = &inventoryContext; + interfacePrint("You check out your sack."); + break; } } @@ -149,3 +153,13 @@ void activateContext(int key_press) { } current_context = &walkContext; } + +void inventoryContext(int key_press) { + switch (key_press) { + case KEY_ESC: + case 'q': + interfacePrint("That's enough of that..."); + current_context = &walkContext; + break; + } +} diff --git a/context.h b/context.h index 2463ca8..96338bc 100644 --- a/context.h +++ b/context.h @@ -20,4 +20,5 @@ void consoleContext(int key_press); void walkContext(int key_press); void lookContext(int key_press); void activateContext(int key_press); +void inventoryContext(int key_press); #endif diff --git a/interface/sdl.c b/interface/sdl.c index ff41be4..f9d4e2d 100644 --- a/interface/sdl.c +++ b/interface/sdl.c @@ -225,11 +225,11 @@ int interfaceInit() { if (interfaceVideoSet()) return ERROR; // FIXME: this should be handled differently, but we need to set the window width/height to the surface's reported width/height, as some window managers will resize the SDL window. + SDL_Delay(100); video_width = (SDL_GetVideoSurface())->w; video_height = (SDL_GetVideoSurface())->h; if (interfaceVideoSet()) return ERROR; - SDL_WM_SetCaption(NAME, NULL); consoleAddCommand("quit", interfaceQuit); @@ -240,6 +240,7 @@ int interfaceInit() { /* tile specific stuff */ /* load our surfaces from memory */ font_spritesheet = IMG_Load_RW(SDL_RWFromMem(&font_images, font_images_length), 1); + ui_spritesheet = IMG_Load_RW(SDL_RWFromMem(&ui_images, ui_images_length), 1); player_spritesheet = IMG_Load_RW(SDL_RWFromMem(&player_images, player_images_length), 1); npc_spritesheet = IMG_Load_RW(SDL_RWFromMem(&npc_images, npc_images_length), 1); wall_spritesheet = IMG_Load_RW(SDL_RWFromMem(&wall_images, wall_images_length), 1); @@ -328,6 +329,22 @@ void cameraDraw() { interfaceDrawString(test, screen->w-strlen(test)*g_tile_width, 0); } +void uiDraw() { + int hotbar_count = 4; + // TODO: move the next line to a uiSetAlpha function (so user can customize). + // TODO: create a Surface in interfaceInit() and simply blit that here. + SDL_SetAlpha(ui_spritesheet, SDL_SRCALPHA, 200); + SDL_Rect hotbar_item_rect = { 0, 0, 32, 32 }; + int hotbar_width = hotbar_count*32; + int hotbar_height = 32; + int i = 0; + while (i < hotbar_count) { + SDL_Rect hotbar_target_rect = {(screen->w/2 - hotbar_width/2)+i*32, screen->h-hotbar_height, (screen->w/2 - hotbar_width/2)+32+i*32, screen->h}; + SDL_BlitSurface(ui_spritesheet, &hotbar_item_rect, screen, &hotbar_target_rect); + i++; + } +} + int interfaceLoop() { while (SDL_WaitEvent(&event)) { switch(event.type) { @@ -398,12 +415,24 @@ void interfaceDraw() { // TODO: instead of redrawing whole screen, redraw last positions of tiles //SDL_FillRect(screen, NULL, SDL_MapRGB(screen->format, 0, 0, 0)); cameraDraw(); // draw our current view + uiDraw(); if (current_context == &consoleContext) { interfaceDrawConsole(); + } else if (current_context == &inventoryContext) { + interfaceDrawInventory(); } SDL_Flip(screen); // redraw! } +void interfaceDrawInventory() { + SDL_Surface *new_surface = SDL_CreateRGBSurface(screen->flags, (screen->w/6), screen->h/2, screen->format->BitsPerPixel, screen->format->Rmask, screen->format->Gmask, screen->format->Bmask, screen->format->Amask); + SDL_Rect render_area = { screen->w-(screen->w/6), screen->h/8, screen->w/6, screen->h/2 }; + SDL_FillRect(new_surface, NULL, SDL_MapRGB(new_surface->format, 196, 164, 64)); + SDL_SetAlpha(new_surface, SDL_SRCALPHA, 128); + SDL_BlitSurface(new_surface, NULL, screen, &render_area); + SDL_FreeSurface(new_surface); +} + void interfaceDrawConsole() { int line; struct ConsoleEntry *entry; diff --git a/interface/sdl.h b/interface/sdl.h index cd2e91c..406d96e 100644 --- a/interface/sdl.h +++ b/interface/sdl.h @@ -14,6 +14,7 @@ SDL_Surface* screen; SDL_Surface* font_spritesheet; + SDL_Surface* ui_spritesheet; SDL_Surface* player_spritesheet; SDL_Surface* npc_spritesheet; SDL_Surface* shadow_spritesheet; @@ -38,6 +39,8 @@ float g_tile_height; void interfaceSetScale(float scale_x, float scale_y); +void uiDraw(); + void interfaceDrawString(const char *string, int start_x, int start_y); void interfaceDrawChar(char ch, int start_x, int start_y); diff --git a/pack_tiles.c b/pack_tiles.c index c3c5267..ea198fe 100644 --- a/pack_tiles.c +++ b/pack_tiles.c @@ -31,6 +31,7 @@ int main(int argc, char **argv) { fprintf(tiles_h, "#define TILE_WIDTH 16\n#define TILE_HEIGHT 32\n"); convert("tiles/font.png", "font_images"); + convert("tiles/ui.png", "ui_images"); convert("tiles/players.png", "player_images"); convert("tiles/npcs.png", "npc_images"); convert("tiles/walls.png", "wall_images"); diff --git a/tiles/tiles.c b/tiles/tiles.c index 3ccbc27..eee8e97 100644 --- a/tiles/tiles.c +++ b/tiles/tiles.c @@ -4,6 +4,11 @@ unsigned char font_images[] = { }; unsigned int font_images_length = 3723; +unsigned char ui_images[] = { +0x89,0x50,0x4e,0x47,0x0d,0x0a,0x1a,0x0a,0x00,0x00,0x00,0x0d,0x49,0x48,0x44,0x52,0x00,0x00,0x00,0x80,0x00,0x00,0x00,0x20,0x08,0x03,0x00,0x00,0x00,0xed,0xfc,0x80,0x17,0x00,0x00,0x03,0x00,0x50,0x4c,0x54,0x45,0x00,0x00,0x00,0x00,0x00,0xaa,0x00,0xaa,0x00,0x00,0xaa,0xaa,0xaa,0x00,0x00,0xaa,0x00,0xaa,0xaa,0x55,0x00,0xaa,0xaa,0xaa,0x55,0x55,0x55,0x55,0x55,0xff,0x55,0xff,0x55,0x55,0xff,0xff,0xff,0x55,0x55,0xff,0x55,0xff,0xff,0xff,0x55,0xff,0xff,0xff,0x00,0x00,0x00,0x14,0x14,0x14,0x20,0x20,0x20,0x2c,0x2c,0x2c,0x38,0x38,0x38,0x45,0x45,0x45,0x51,0x51,0x51,0x61,0x61,0x61,0x71,0x71,0x71,0x82,0x82,0x82,0x92,0x92,0x92,0xa2,0xa2,0xa2,0xb6,0xb6,0xb6,0xcb,0xcb,0xcb,0xe3,0xe3,0xe3,0xff,0xff,0xff,0x00,0x00,0xff,0x41,0x00,0xff,0x7d,0x00,0xff,0xbe,0x00,0xff,0xff,0x00,0xff,0xff,0x00,0xbe,0xff,0x00,0x7d,0xff,0x00,0x41,0xff,0x00,0x00,0xff,0x41,0x00,0xff,0x7d,0x00,0xff,0xbe,0x00,0xff,0xff,0x00,0xbe,0xff,0x00,0x7d,0xff,0x00,0x41,0xff,0x00,0x00,0xff,0x00,0x00,0xff,0x41,0x00,0xff,0x7d,0x00,0xff,0xbe,0x00,0xff,0xff,0x00,0xbe,0xff,0x00,0x7d,0xff,0x00,0x41,0xff,0x7d,0x7d,0xff,0x9e,0x7d,0xff,0xbe,0x7d,0xff,0xdf,0x7d,0xff,0xff,0x7d,0xff,0xff,0x7d,0xdf,0xff,0x7d,0xbe,0xff,0x7d,0x9e,0xff,0x7d,0x7d,0xff,0x9e,0x7d,0xff,0xbe,0x7d,0xff,0xdf,0x7d,0xff,0xff,0x7d,0xdf,0xff,0x7d,0xbe,0xff,0x7d,0x9e,0xff,0x7d,0x7d,0xff,0x7d,0x7d,0xff,0x9e,0x7d,0xff,0xbe,0x7d,0xff,0xdf,0x7d,0xff,0xff,0x7d,0xdf,0xff,0x7d,0xbe,0xff,0x7d,0x9e,0xff,0xb6,0xb6,0xff,0xc7,0xb6,0xff,0xdb,0xb6,0xff,0xeb,0xb6,0xff,0xff,0xb6,0xff,0xff,0xb6,0xeb,0xff,0xb6,0xdb,0xff,0xb6,0xc7,0xff,0xb6,0xb6,0xff,0xc7,0xb6,0xff,0xdb,0xb6,0xff,0xeb,0xb6,0xff,0xff,0xb6,0xeb,0xff,0xb6,0xdb,0xff,0xb6,0xc7,0xff,0xb6,0xb6,0xff,0xb6,0xb6,0xff,0xc7,0xb6,0xff,0xdb,0xb6,0xff,0xeb,0xb6,0xff,0xff,0xb6,0xeb,0xff,0xb6,0xdb,0xff,0xb6,0xc7,0xff,0x00,0x00,0x71,0x1c,0x00,0x71,0x38,0x00,0x71,0x55,0x00,0x71,0x71,0x00,0x71,0x71,0x00,0x55,0x71,0x00,0x38,0x71,0x00,0x1c,0x71,0x00,0x00,0x71,0x1c,0x00,0x71,0x38,0x00,0x71,0x55,0x00,0x71,0x71,0x00,0x55,0x71,0x00,0x38,0x71,0x00,0x1c,0x71,0x00,0x00,0x71,0x00,0x00,0x71,0x1c,0x00,0x71,0x38,0x00,0x71,0x55,0x00,0x71,0x71,0x00,0x55,0x71,0x00,0x38,0x71,0x00,0x1c,0x71,0x38,0x38,0x71,0x45,0x38,0x71,0x55,0x38,0x71,0x61,0x38,0x71,0x71,0x38,0x71,0x71,0x38,0x61,0x71,0x38,0x55,0x71,0x38,0x45,0x71,0x38,0x38,0x71,0x45,0x38,0x71,0x55,0x38,0x71,0x61,0x38,0x71,0x71,0x38,0x61,0x71,0x38,0x55,0x71,0x38,0x45,0x71,0x38,0x38,0x71,0x38,0x38,0x71,0x45,0x38,0x71,0x55,0x38,0x71,0x61,0x38,0x71,0x71,0x38,0x61,0x71,0x38,0x55,0x71,0x38,0x45,0x71,0x51,0x51,0x71,0x59,0x51,0x71,0x61,0x51,0x71,0x69,0x51,0x71,0x71,0x51,0x71,0x71,0x51,0x69,0x71,0x51,0x61,0x71,0x51,0x59,0x71,0x51,0x51,0x71,0x59,0x51,0x71,0x61,0x51,0x71,0x69,0x51,0x71,0x71,0x51,0x69,0x71,0x51,0x61,0x71,0x51,0x59,0x71,0x51,0x51,0x71,0x51,0x51,0x71,0x59,0x51,0x71,0x61,0x51,0x71,0x69,0x51,0x71,0x71,0x51,0x69,0x71,0x51,0x61,0x71,0x51,0x59,0x71,0x00,0x00,0x41,0x10,0x00,0x41,0x20,0x00,0x41,0x30,0x00,0x41,0x41,0x00,0x41,0x41,0x00,0x30,0x41,0x00,0x20,0x41,0x00,0x10,0x41,0x00,0x00,0x41,0x10,0x00,0x41,0x20,0x00,0x41,0x30,0x00,0x41,0x41,0x00,0x30,0x41,0x00,0x20,0x41,0x00,0x10,0x41,0x00,0x00,0x41,0x00,0x00,0x41,0x10,0x00,0x41,0x20,0x00,0x41,0x30,0x00,0x41,0x41,0x00,0x30,0x41,0x00,0x20,0x41,0x00,0x10,0x41,0x20,0x20,0x41,0x28,0x20,0x41,0x30,0x20,0x41,0x38,0x20,0x41,0x41,0x20,0x41,0x41,0x20,0x38,0x41,0x20,0x30,0x41,0x20,0x28,0x41,0x20,0x20,0x41,0x28,0x20,0x41,0x30,0x20,0x41,0x38,0x20,0x41,0x41,0x20,0x38,0x41,0x20,0x30,0x41,0x20,0x28,0x41,0x20,0x20,0x41,0x20,0x20,0x41,0x28,0x20,0x41,0x30,0x20,0x41,0x38,0x20,0x41,0x41,0x20,0x38,0x41,0x20,0x30,0x41,0x20,0x28,0x41,0x2c,0x2c,0x41,0x30,0x2c,0x41,0x34,0x2c,0x41,0x3c,0x2c,0x41,0x41,0x2c,0x41,0x41,0x2c,0x3c,0x41,0x2c,0x34,0x41,0x2c,0x30,0x41,0x2c,0x2c,0x41,0x30,0x2c,0x41,0x34,0x2c,0x41,0x3c,0x2c,0x41,0x41,0x2c,0x3c,0x41,0x2c,0x34,0x41,0x2c,0x30,0x41,0x2c,0x2c,0x41,0x2c,0x2c,0x41,0x30,0x2c,0x41,0x34,0x2c,0x41,0x3c,0x2c,0x41,0x41,0x2c,0x3c,0x41,0x2c,0x34,0x41,0x2c,0x30,0x41,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xff,0xff,0xff,0x1f,0x80,0x37,0xd9,0x00,0x00,0x00,0x01,0x74,0x52,0x4e,0x53,0x00,0x40,0xe6,0xd8,0x66,0x00,0x00,0x00,0xc6,0x49,0x44,0x41,0x54,0x58,0x85,0xed,0x97,0xd1,0x0d,0xc3,0x30,0x08,0x44,0xbd,0x27,0x4b,0xb0,0x80,0xb3,0xe3,0x6d,0x54,0xc0,0xb4,0x4e,0xe3,0xe4,0xb3,0x47,0xa4,0x06,0x2b,0xfe,0xe0,0xe7,0x9d,0xcf,0x72,0x74,0xb4,0x76,0x8b,0x42,0xee,0x63,0x7d,0x35,0x39,0xfc,0xed,0x04,0x76,0xda,0xfc,0x19,0xbf,0x43,0x44,0x90,0x2b,0x0a,0x5d,0x59,0x0a,0xb0,0x69,0xd7,0x9e,0xdc,0x59,0x34,0x05,0xce,0x8f,0x6f,0x60,0x05,0x53,0x01,0xe9,0x16,0xdc,0x7f,0x43,0x2d,0x0e,0xb8,0x28,0x06,0xdf,0x14,0xc4,0xc9,0xeb,0xf8,0xed,0xc8,0xfe,0xdc,0x80,0x94,0x0a,0x70,0x53,0x6a,0x05,0x48,0xbd,0x00,0x90,0xfe,0x86,0xff,0xee,0x80,0x51,0xd6,0x47,0x78,0x0b,0x07,0xf0,0x38,0x40,0x74,0xe0,0xaa,0x08,0x78,0xaf,0x4b,0x3e,0x47,0xc0,0xe3,0x80,0x0b,0xa8,0x7e,0x05,0x58,0x03,0x19,0x55,0x40,0xa4,0xbf,0x23,0x3b,0x52,0x4a,0x25,0xdf,0x5a,0xe0,0x44,0xa2,0x77,0x28,0xcf,0x73,0x67,0x36,0x75,0x51,0xd4,0x58,0xbc,0x38,0x60,0x49,0x5d,0x95,0x38,0x18,0x60,0x3a,0x30,0x5c,0xa0,0x85,0xf2,0xa1,0xa0,0x76,0x34,0x6b,0xfb,0x81,0x74,0xce,0xa7,0x44,0x7e,0x65,0xbd,0x00,0xa1,0xaa,0x3a,0xee,0xd3,0x2d,0xe6,0xe4,0x00,0x00,0x00,0x00,0x49,0x45,0x4e,0x44,0xae,0x42,0x60,0x82, +}; +unsigned int ui_images_length = 1048; + unsigned char player_images[] = { 0x89,0x50,0x4e,0x47,0x0d,0x0a,0x1a,0x0a,0x00,0x00,0x00,0x0d,0x49,0x48,0x44,0x52,0x00,0x00,0x00,0x60,0x00,0x00,0x00,0xa0,0x08,0x06,0x00,0x00,0x00,0xf3,0x70,0x69,0x8c,0x00,0x00,0x07,0xfa,0x49,0x44,0x41,0x54,0x78,0x9c,0xed,0x9d,0xbd,0x6b,0xe3,0xd8,0x1a,0xc6,0x1f,0x99,0x34,0x03,0x2e,0x5c,0x64,0xc0,0x86,0x14,0x1a,0xf0,0x14,0x17,0x32,0x70,0xa7,0xd3,0x14,0x29,0xb4,0x70,0x8b,0x2d,0xbd,0xa0,0x74,0xb7,0xc8,0x9f,0xe0,0xf4,0x49,0x91,0xe9,0x27,0x7f,0x42,0xca,0x05,0x1b,0x92,0xf2,0x76,0x4e,0x31,0xc5,0x08,0xa6,0x98,0x0b,0xeb,0x62,0x60,0x02,0x36,0xec,0x40,0x0c,0xbb,0x85,0x8b,0xc0,0x34,0x0b,0xef,0x2d,0xf4,0x91,0x23,0xe9,0x1c,0xc9,0x89,0x8f,0xac,0xbd,0xf6,0xf3,0x83,0x20,0x29,0x92,0x9d,0x93,0xe7,0xfd,0x38,0x1f,0xd2,0x39,0x02,0x08,0x21,0x15,0x04,0x81,0x48,0x10,0x88,0x34,0x5d,0x8e,0x9d,0x24,0x12,0x7e,0x24,0xc0,0x88,0x46,0xd8,0x34,0x81,0x48,0x2a,0x3c,0xc5,0xaf,0x87,0x96,0xe9,0x44,0x20,0x22,0x6f,0xde,0xbf,0x07,0x00,0xbc,0x79,0xf3,0x1e,0xe3,0xb1,0xe3,0x6c,0xac,0x54,0x3b,0x84,0x56,0xd4,0x8b,0x8b,0x0b,0xf9,0xf2,0xe5,0x4b,0x7a,0xfc,0xf6,0xed,0x5b,0x00,0xc0,0xf9,0xf9,0x39,0x8d,0x60,0x99,0x42,0x04,0x5c,0x5c,0x5c,0x64,0x52,0x0d,0xc5,0xaf,0x17,0x63,0x04,0x24,0xfb,0xe7,0xe7,0xe7,0xc6,0xeb,0xc8,0xfa,0x94,0x09,0xab,0x46,0x02,0x0d,0x50,0x13,0xc6,0x4a,0x98,0x6c,0x86,0x32,0x03,0x38,0x43,0x00,0xc3,0x4d,0x95,0x64,0x47,0xd1,0xa6,0x96,0x51,0x10,0xa5,0x9f,0x4f,0xe3,0xe8,0xf8,0x5d,0x10,0x6d,0x8f,0xc7,0x4c,0x45,0xb6,0x29,0x44,0xc0,0x10,0x90,0xaf,0x6f,0x2e,0x30,0x1e,0x09,0xde,0x05,0x91,0xf8,0xbf,0xfe,0x35,0xc0,0xa7,0x71,0x74,0xae,0x89,0x42,0x6e,0x33,0x19,0x8f,0x4e,0x04,0xfe,0x2e,0x82,0xa4,0x13,0x36,0x9b,0xcd,0xb0,0x5c,0x2e,0xe1,0xde,0xdc,0x00,0x00,0x2e,0x59,0x21,0x5b,0x25,0x13,0x01,0x97,0xf1,0x36,0x11,0xff,0xe3,0xc7,0x8f,0x00,0x80,0x4e,0xa7,0xb3,0xd1,0x42,0xed,0x12,0x85,0x14,0x94,0x18,0x61,0x36,0x9b,0xe1,0xe0,0xe0,0x00,0x00,0xf0,0xf9,0xf3,0x67,0x5c,0xc6,0xe7,0x02,0x11,0xc9,0x77,0xd6,0xc8,0xf3,0x49,0x0d,0xe0,0x03,0xe2,0x03,0x18,0x05,0x8f,0x69,0x07,0x88,0xc4,0x8f,0xcf,0x23,0x50,0x52,0xd3,0xc9,0xc9,0x09,0x8d,0x60,0x01,0x6d,0x33,0xf4,0xe7,0x87,0x2b,0x7c,0xfb,0xf6,0x2d,0x15,0x1f,0x00,0x6e,0x01,0x47,0xad,0x17,0x88,0x1d,0x5a,0x00,0x30,0x18,0x0c,0x04,0x00,0x7e,0x78,0x5e,0xda,0xd4,0x7c,0x39,0x9d,0xe2,0xe5,0x74,0x8a,0xdf,0x7e,0xfb,0x07,0x5e,0x4e,0xa7,0x69,0xd3,0x94,0xe2,0xdb,0xa5,0x05,0x00,0x7b,0xd7,0xd7,0xf8,0xe1,0x79,0x08,0xc3,0xb0,0xd0,0xc2,0x39,0xc7,0x38,0xdd,0xa7,0xf8,0xf6,0x71,0x00,0xc0,0xf3,0x3c,0x29,0x8a,0x9f,0xdc,0x80,0x39,0x05,0x00,0x8c,0x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x5a,0x2b,0xfc,0x16,0x51,0x68,0x49,0x6a,0xbc,0x3f,0x63,0x28,0x6d,0x0a,0x0a,0xc3,0x10,0xea,0x8b,0xdc,0xf2,0x9e,0x9f,0x18,0x89,0x54,0x53,0xe6,0xfd,0x80,0x39,0x05,0x39,0x40,0x24,0xbc,0x2a,0xfe,0x7c,0x3e,0x67,0xd3,0x74,0x35,0x32,0x3a,0xfd,0xf0,0x4a,0xc6,0x22,0x80,0xa8,0x27,0x0c,0x20,0xa9,0x58,0xe3,0x48,0x10,0x39,0xc0,0x50,0xd4,0x6d,0x72,0xbd,0xe7,0x79,0xc2,0x4a,0x38,0xc2,0x77,0x21,0x49,0x1f,0x20,0xab,0x5f,0x7c,0x3e,0x6e,0x8e,0xaa,0x4b,0xbd,0xa9,0xfa,0x15,0x22,0xc0,0x4b,0xad,0x75,0x8a,0xef,0xf8,0x80,0x03,0x65,0x4b,0xaa,0xf1,0x72,0xde,0x7e,0xab,0xfc,0x18,0x89,0x23,0x20,0x63,0xbd,0xc1,0x60,0x20,0xae,0xeb,0x8a,0xe7,0x79,0xe2,0xba,0xae,0xb8,0xae,0xab,0x9b,0x05,0xb9,0xf3,0xf8,0xe8,0x24,0x11,0xa0,0xd3,0xc4,0x34,0x43,0x34,0x3d,0xce,0x4f,0xa8,0x48,0x73,0x97,0xeb,0xba,0xd2,0xed,0x76,0xb1,0x58,0x2c,0xd0,0xed,0x76,0x71,0x77,0x77,0x87,0x76,0xbb,0x9d,0xd4,0x03,0x7c,0xec,0x24,0x8b,0x4e,0x0f,0x01,0xa2,0x57,0xbf,0xa8,0xdc,0xe6,0xe6,0xc9,0x19,0xfb,0x01,0x3a,0xf1,0x1f,0x1e,0x1e,0x92,0xd3,0x14,0x7e,0x05,0x74,0xe9,0x28,0x26,0xd5,0xaf,0x05,0x00,0x7e,0x27,0xfb,0x4b,0x95,0x17,0x61,0x88,0x7e,0xbf,0x8f,0x87,0x87,0x87,0x74,0x28,0x82,0x64,0xf1,0xd1,0x81,0x8f,0xec,0x78,0x90,0xe7,0x79,0x69,0x0b,0xf2,0x87,0xe7,0x61,0xe6,0xba,0xda,0xcf,0xee,0x01,0x40,0xfe,0x7e,0xb0,0xe7,0x79,0x92,0x78,0xff,0x1f,0xed,0x36,0x16,0x77,0x77,0x69,0x44,0x28,0x30,0x0a,0x0c,0x24,0xfa,0xcd,0xe7,0x73,0xbc,0x32,0x5f,0xe6,0x00,0x86,0x7e,0xc0,0x62,0xb1,0xc0,0xab,0xf9,0x0c,0x2f,0xc2,0x4f,0x98,0x4e,0xff,0x85,0x7e,0xbf,0x8f,0xc5,0x62,0x81,0x3f,0xff,0xfc,0x77,0x3d,0x25,0xfe,0x3f,0x27,0x3f,0x0c,0x91,0x88,0x1f,0x9d,0x2b,0x77,0xd4,0x82,0x01,0x7c,0x88,0xbc,0x9a,0xcf,0xe2,0x0f,0x9f,0xe2,0x00,0xc0,0x8b,0xf0,0x2b,0x6f,0xc8,0x54,0xa0,0x18,0x41,0x12,0xf1,0x13,0x5e,0x84,0x5f,0x57,0xff,0x22,0x1f,0x22,0x3e,0x44,0xb3,0x82,0xfa,0x50,0xbb,0xaa,0x3a,0x29,0x50,0xd5,0x24,0x7d,0xf2,0x17,0x01,0x00,0xa2,0xde,0x30,0xdb,0xff,0x4f,0xc0,0xd4,0xf6,0x5f,0x59,0x3f,0x2b,0x56,0xdc,0x61,0x56,0xd2,0x4f,0x57,0x41,0x54,0xad,0xf5,0xc6,0x4e,0x58,0x39,0x4f,0xd2,0x2f,0x5f,0x09,0x57,0x7d,0x98,0x94,0x43,0xfd,0x08,0x79,0x1e,0x7c,0x5f,0x7c,0x33,0xb4,0x28,0x7c,0xb3,0xb4,0x00,0x7a,0x7f,0x93,0x38,0x26,0xf1,0x2f,0x59,0x8b,0x6f,0x86,0xd4,0x00,0x13,0xdd,0x6b,0x6d,0xc9,0x66,0x98,0x88,0x0c,0x01,0xa1,0x11,0x1a,0x44,0x97,0x8a,0x44,0x58,0x37,0xd4,0xcd,0xca,0x4b,0x15,0xd0,0x18,0xf5,0x50,0x6a,0x80,0xb1,0x03,0x8c,0x00,0x11,0x81,0x38,0x0e,0x2b,0xe5,0x3a,0x30,0xae,0x98,0x25,0x02,0x71,0x6e,0x23,0xa7,0x1f,0x39,0x4e,0x1a,0x01,0x34,0x84,0x5d,0x8c,0x11,0x90,0x88,0x0f,0x00,0xc7,0x13,0xc1,0xd8,0xa1,0xf8,0x75,0xa0,0x35,0x80,0x29,0xdf,0x8b,0x44,0xe9,0xa8,0xde,0x22,0xed,0x16,0xda,0x14,0x14,0x79,0xba,0x23,0x98,0xc4,0x5a,0xff,0xe4,0x44,0xeb,0xed,0x31,0x02,0xac,0xa3,0x35,0x80,0xc4,0x73,0xc3,0x1c,0xc7,0x49,0x8e,0xa1,0x1e,0x13,0x7b,0x18,0x22,0xc0,0xc9,0xcc,0x6f,0xa5,0xf0,0xf5,0xc1,0x35,0xe3,0x1a,0xe6,0x49,0xf3,0x84,0x47,0x1c,0x35,0xb5,0x8e,0x2e,0x05,0xa5,0x22,0xe7,0x17,0x44,0x3f,0xce,0x9e,0x67,0x5e,0xb2,0x40,0xde,0x00,0x19,0x0f,0x3f,0x46,0x29,0x02,0x1a,0x61,0x6d,0x74,0x0b,0x74,0xac,0xf3,0x1d,0xe4,0x89,0x3c,0x79,0xf1,0xee,0xfc,0x80,0x35,0x1b,0x48,0xeb,0xa1,0xab,0x84,0x2b,0x25,0x1d,0x3b,0xd1,0x0f,0xb1,0x88,0xe6,0x7e,0x40,0x7e,0x7e,0x93,0x20,0x1e,0x19,0x8d,0x3b,0x6a,0x1c,0x96,0xb0,0xc0,0xb3,0xfa,0x01,0x63,0xc7,0xe1,0x2b,0x63,0x2c,0xf1,0xac,0x17,0x38,0x04,0xf4,0x7b,0x6b,0xac,0x14,0x01,0xaa,0xb7,0x3b,0xce,0x63,0x1d,0xc0,0xe1,0xe9,0xf5,0xe1,0x50,0x44,0xc3,0x94,0xdd,0x11,0x03,0x10,0x79,0xfc,0x31,0xe0,0xa8,0x15,0x2e,0x3d,0xdf,0x1e,0x26,0x03,0x48,0xd2,0xbe,0x17,0x89,0x8c,0xc0,0xf6,0x7e,0x3d,0x54,0xa6,0x20,0x0a,0x4f,0x08,0x21,0x84,0x10,0x42,0x08,0x21,0x84,0x10,0x42,0x08,0x21,0xdb,0xce,0xd9,0x19,0x67,0x8d,0x36,0x86,0x00,0x22,0x13,0x88,0xd4,0xfc,0x3c,0x2c,0x6f,0x49,0x6a,0x38,0x3b,0x13,0xc1,0x24,0x39,0x60,0x24,0x6c,0x1c,0x99,0x44,0x5e,0x9f,0x6e,0xcf,0xf8,0xfc,0x53,0x23,0xc8,0x04,0x52,0xb7,0xf8,0x4c,0x41,0x06,0xd4,0x87,0x10,0xea,0x34,0xc2,0xb3,0x1e,0xcc,0xda,0x05,0xd4,0x7b,0xe1,0x72,0x16,0x6d,0x50,0xc3,0x93,0xe0,0x8c,0x00,0x03,0xc9,0xc4,0x44,0xa9,0xb9,0xfe,0xa5,0x01,0x0c,0x24,0x13,0x13,0x95,0x09,0x8a,0xb5,0x3c,0x1f,0xc2,0x87,0x4e,0xca,0xa9,0x7d,0x19,0x4a,0x1a,0xa0,0x48,0x55,0xce,0xb1,0xaa,0x19,0x0d,0x00,0xe0,0xe4,0xe4,0x44,0x00,0x60,0xb9,0x5c,0x1a,0xaf,0x49,0xde,0x9d,0xe6,0x79,0x1e,0xc2,0x30,0xb4,0xa6,0x1b,0x5b,0x41,0x31,0xcb,0xe5,0x32,0x15,0x79,0x30,0x18,0x00,0x40,0xfa,0x3a,0x77,0x00,0x90,0x09,0xe0,0xfc,0xd4,0x58,0xf1,0x76,0x8e,0xec,0xac,0xa0,0xc9,0xd3,0x57,0x3e,0x5f,0x15,0xa6,0x20,0x33,0x3a,0xb1,0xd9,0x0f,0xd8,0x36,0x68,0x80,0x6a,0x6a,0xcd,0x12,0x34,0x80,0x01,0x91,0xa8,0xe2,0xcd,0xef,0xdb,0x86,0x75,0x80,0x9e,0x7c,0x07,0x8c,0xeb,0x63,0x6c,0x2b,0xff,0x03,0x39,0x3f,0x31,0xb7,0xc4,0x4d,0x7b,0x77,0x00,0x00,0x00,0x00,0x49,0x45,0x4e,0x44,0xae,0x42,0x60,0x82, }; diff --git a/tiles/tiles.h b/tiles/tiles.h index bec4a83..0d0a38d 100644 --- a/tiles/tiles.h +++ b/tiles/tiles.h @@ -6,6 +6,9 @@ extern unsigned char font_images[]; extern unsigned int font_images_length; +extern unsigned char ui_images[]; +extern unsigned int ui_images_length; + extern unsigned char player_images[]; extern unsigned int player_images_length; diff --git a/tiles/ui.png b/tiles/ui.png new file mode 100644 index 0000000..f541eb3 Binary files /dev/null and b/tiles/ui.png differ