diff --git a/data/sprites/dwarfhead5.png b/data/sprites/dwarfhead5.png new file mode 100644 index 0000000..b4b3ee4 Binary files /dev/null and b/data/sprites/dwarfhead5.png differ diff --git a/defs.h b/defs.h index af1c7f4..e63ff88 100644 --- a/defs.h +++ b/defs.h @@ -754,7 +754,7 @@ imageset_t imageset[MAXPTYPES]; /* external globals */ extern SDL_Color black; -extern SDL_Surface *screen, *temps, *levelbg, *head, *icecube; +extern SDL_Surface *screen, *temps, *levelbg, *head, *head5, *icecube; extern SDL_Surface *healthbar[]; extern SDL_Surface *greenbox; extern sprite_t *sprite, *lastsprite, *player, *boss, *mask; diff --git a/globals.h b/globals.h index a8e110f..140db6d 100644 --- a/globals.h +++ b/globals.h @@ -22,7 +22,7 @@ int nextforcegoodcard; SDL_Surface *levelbg; // level background image SDL_Surface *temps; // temporary surface SDL_Surface *screen; // the actual video screen -SDL_Surface *head; // img in corner showing number of lives +SDL_Surface *head,*head5; // imgs in corner showing number of lives SDL_Surface *icecube; // overlaid on frozen monsters SDL_Surface *greenbox; // for fly spray effect SDL_Surface *healthbar[HEALTHFRAMES]; // for boss health diff --git a/rc.c b/rc.c index 0cfccac..d872595 100644 --- a/rc.c +++ b/rc.c @@ -2962,7 +2962,7 @@ void drawlevel(void) { int x,y; int dstx,dsty,xdis,ydis; double turns; - double pxspeed,pyspeed,pspeed; + double pspeed; double dist; SDL_Rect area,dst; int speed = 16; @@ -3508,6 +3508,7 @@ void drawscore(void) { SDL_Rect area; SDL_Color scorecol; int i; + int numtoshow; if (forcegoodcard) { if ((timer / LUCKYFLASH) % 2 == 0) { @@ -3539,13 +3540,22 @@ void drawscore(void) { SDL_FreeSurface(score); // lives - - // lives - show 1 less than lives + + // show 1 less than lives + numtoshow = player->lives-1; area.x = 20; area.y = 25; area.w = 0; area.h = 0; - for (i = 1; i < player->lives; i++) { + + // show "x5" for lots of lives + while (numtoshow >= 5) { + SDL_BlitSurface(head5, NULL, screen, &area); + area.x += (head->w + 3); + numtoshow -= 5; + } + + for (i = 0; i < numtoshow; i++) { SDL_BlitSurface(head, NULL, screen, &area); area.x += (head->w + 3); } @@ -6613,7 +6623,7 @@ void handleinput(void) { if (keydown(SDLK_l)) { if (toggletimer == 0) { addscore(player, 100001); - toggletimer = 80; + toggletimer = 30; } } if (keydown(SDLK_n)) { diff --git a/shared.c b/shared.c index 6367058..b89e679 100644 --- a/shared.c +++ b/shared.c @@ -991,6 +991,8 @@ int loadimagesets(void) { sprintf(tempfile, "%s/sprites/dwarfhead.png",datadir); head = IMG_Load(tempfile); + sprintf(tempfile, "%s/sprites/dwarfhead5.png",datadir); + head5 = IMG_Load(tempfile); sprintf(tempfile, "%s/sprites/icecube.png",datadir); icecube = IMG_Load(tempfile);