diff --git a/data/levels/level614.dat b/data/levels/level614.dat new file mode 100644 index 0000000..57e422a --- /dev/null +++ b/data/levels/level614.dat @@ -0,0 +1,88 @@ +bgfile snow2.png +bg 0 +hurryup 30 +help +endhelp +monsters +0 14 18 +134 25 18 +23 25 13 +7 19 5 +18 2 3 +18 35 7 +18 4 27 +18 33 23 +6 31 10 +133 35 25 +133 5 22 +16 11 19 +16 10 19 +16 9 19 +16 28 19 +16 29 19 +16 30 19 +15 32 11 +15 31 11 +15 8 11 +15 7 11 +15 6 11 +6 7 10 +17 35 27 +17 4 27 +17 4 7 +17 35 7 +endmonsters +exitdir 1 +33,87,87,87,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,87,87,87,32, +33,87,87,87,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,87,87,87,33, +33,32,87,87,87,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,87,87,87,32,33, +33,33,87,87,87,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,87,87,87,33,33, +33,33,32,87,87,87,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,87,87,87,32,33,33, +33,33,33,87,87,87,33,33,33,33,33,33,33,33,33,33,33,33,87,87,87,87,33,33,33,33,33,33,33,33,33,33,33,33,87,87,87,33,33,33, +33,33,33,32,87,87,87,33,33,33,33,33,33,33,33,33,33,33,87,87,87,87,33,33,33,33,33,33,33,33,33,33,33,87,87,87,32,33,33,33, +33,33,33,33,87,87,87,33,33,33,33,33,33,33,33,33,33,33,87,87,87,87,33,33,33,33,33,33,33,33,33,33,33,87,87,87,33,33,33,33, +33,33,33,33,32,87,87,87,87,33,33,33,33,33,33,33,33,33,87,87,87,87,33,33,33,33,33,33,33,33,33,87,87,87,87,32,33,33,33,33, +33,33,33,33,33,87,87,87,87,87,33,33,33,33,33,33,33,33,87,87,87,87,33,33,33,33,33,33,33,33,87,87,87,87,87,33,33,33,33,33, +33,33,33,33,33,32,87,87,87,87,87,87,33,33,33,33,33,33,87,87,87,87,33,33,33,33,33,33,87,87,87,87,87,87,32,33,33,33,33,33, +33,33,33,33,33,33,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,33,33,33,33,33,33, +33,33,33,33,33,33,32,32,32,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,32,32,32,33,33,33,33,33,33, +33,33,33,33,33,33,33,33,33,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,33,33,33,33,33,33,33,33,33, +33,33,33,33,33,33,33,33,33,87,32,33,32,32,32,32,32,32,87,87,87,87,32,32,32,32,32,32,33,32,87,33,33,33,33,33,33,33,33,33, +33,33,33,33,33,33,33,33,33,87,87,33,33,33,33,33,33,33,87,87,87,87,33,33,33,33,33,33,33,87,87,33,33,33,33,33,33,33,33,33, +33,33,33,33,33,33,33,33,33,87,87,33,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,33,87,87,33,33,33,33,33,33,33,33,33, +33,33,33,33,33,33,33,33,33,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,33,33,33,33,33,33,33, +33,33,33,33,33,33,33,33,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,33,33,33,33,33,33,33, +33,33,33,33,33,33,87,87,87,87,87,87,32,32,32,32,32,32,87,87,87,87,32,32,32,32,32,32,87,87,87,87,87,87,33,33,33,33,33,33, +33,33,33,33,33,87,87,87,87,32,32,32,33,33,33,33,33,33,87,87,87,87,33,33,33,33,33,33,32,32,32,87,87,87,87,33,33,33,33,33, +33,33,33,33,33,87,87,87,87,33,33,33,33,33,33,33,33,33,87,87,87,87,33,33,33,33,33,33,33,33,33,87,87,87,87,33,33,33,33,33, +33,33,33,33,87,87,87,32,32,33,33,33,33,33,33,33,33,33,87,87,87,87,33,33,33,33,33,33,33,33,33,32,32,87,87,87,33,33,33,33, +33,33,33,33,87,87,87,33,33,33,33,33,33,33,33,33,33,33,87,87,87,87,33,33,33,33,33,33,33,33,33,33,33,87,87,87,33,33,33,33, +33,33,33,87,87,87,32,33,33,33,33,33,33,33,33,33,33,33,87,87,87,87,33,33,33,33,33,33,33,33,33,33,33,32,87,87,87,33,33,33, +33,33,33,87,87,87,33,33,33,33,33,33,33,33,33,33,33,33,87,87,87,87,33,33,33,33,33,33,33,33,33,33,33,33,87,87,87,33,33,33, +33,33,87,87,87,32,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,87,87,87,33,33, +33,33,87,87,87,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,87,87,87,33,33, +33,87,87,87,32,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,32,87,87,87,33, +33,87,87,87,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,33,87,87,87,33, +layer2 +35,2,86 +8,8,86 +29,10,86 +17,11,95,layer3 +22,11,95,layer3 +17,12,95,layer3 +22,12,95,layer3 +17,13,95,layer3 +22,13,95,layer3 +17,16,95,layer3 +22,16,95,layer3 +17,17,95,layer3 +22,17,95,layer3 +17,18,95,layer3 +22,18,95,layer3 +6,19,86 +7,19,86 +36,24,86 +18,25,11 +19,25,11 +20,25,11 +21,25,11 diff --git a/data/map.dat b/data/map.dat index 4719b88..5876169 100644 --- a/data/map.dat +++ b/data/map.dat @@ -76,6 +76,7 @@ 615,level615.dat,Raaa! 618,level618.dat,Secret Exit 619,level619.dat,Slow and steady... +614,level614.dat,...marks the spot 620,level620.dat,King Ant 109,level109.dat,THE END SO FAR 99,level99.dat,TEST LEVEL diff --git a/data/sprites/bighelmet.png b/data/sprites/bighelmet.png new file mode 100644 index 0000000..4c33991 Binary files /dev/null and b/data/sprites/bighelmet.png differ diff --git a/data/sprites/egg.png b/data/sprites/egg.png new file mode 100644 index 0000000..f2561bb Binary files /dev/null and b/data/sprites/egg.png differ diff --git a/defs.h b/defs.h index ab25504..f25d795 100644 --- a/defs.h +++ b/defs.h @@ -27,8 +27,8 @@ #define MAXREGROW 200 // time a tile takes to regrow -#define REGROWTIMER_SHORT 200 -#define REGROWTIMER_LONG 400 +#define REGROWTIMER_SHORT 350 +#define REGROWTIMER_LONG 500 #define MAXCREDITS 5 @@ -278,7 +278,7 @@ // king ant #define KA_WALKTIME 400 -#define KA_SHOOTTIME 100 +#define KA_SHOOTTIME 50 // king ant stats #define KAS_WALK1 0 #define KAS_JUMP1 1 @@ -443,7 +443,7 @@ #define S_SLOPE 2 // Sprite types -#define MAXPTYPES 166 +#define MAXPTYPES 168 #define P_PLAYER 0 #define P_RAT 1 #define P_CHEESE 2 @@ -615,6 +615,8 @@ #define P_KINGANT 163 #define P_FLAME 164 // like mace smash but harmless #define P_BIGFIREBALL 165 +#define P_EGG 166 +#define P_BIGHELMET 167 #define FLY_FLYTIME 150 diff --git a/rc.c b/rc.c index 8a57a1c..a0b83bd 100644 --- a/rc.c +++ b/rc.c @@ -1840,6 +1840,9 @@ void die(sprite_t *s) { case P_KINGFLY: addsprite(P_SUPERUMBRELLA, (640/2), 0, "bigumbrella"); break; + case P_KINGANT: + addsprite(P_BIGHELMET, (640/2), 0, "bighelmet"); + break; } } else if ((s->id == P_SNAIL) && (s->lives > 0)) { // snails can't die but turn into slugs instead sprite_t *newsp; @@ -2362,6 +2365,9 @@ void checkcollide(sprite_t *s) { fruitamt = 1; break; } + // override for ant egg.. + if (s2->id == P_EGG) fruitamt = 5; + s->timer1 += fruitamt; // huw much fruit is needed to grow? if (s->id == P_ANT3) { @@ -2885,6 +2891,7 @@ int movesprite(sprite_t *s) { case P_KINGRAT: case P_KINGSNAIL: case P_KINGFLY: + case P_KINGANT: boss = newsp; } @@ -4516,8 +4523,9 @@ printf("setting target to y = %d\n",ss->timer2); if (s->timer1 == KAS_WALK1) { // shoot an ant out - if (countmonsters(-1) < 6) { // max 5 ants + king ant + if (countmonsters(-1) < 7) { // max 6 ants + king ant sprite_t *newsp; + puffin(-1, s->x, s->y - (s->img->h/2), "nothing", 0); newsp = addsprite(P_ANT1, s->x, s->y-(s->img->h/2),"babant"); // make it shoot upwards newsp->jumping = 1; @@ -4527,7 +4535,17 @@ printf("setting target to y = %d\n",ss->timer2); else newsp->dir = -1; playfx(FX_WHOOSH); } else { - // TODO enough monsters, shoot food instead + // enough monsters, shoot food instead + sprite_t *newsp; + puffin(-1, s->x, s->y - (s->img->h/2), "nothing", 0); + newsp = addsprite(P_EGG, s->x, s->y-(s->img->h/2),"antegg"); + // make it shoot upwards + newsp->jumping = 1; + newsp->jumpspeed = (rand() % 7) + 7; // 7 - 13 + newsp->jumpdir = (((double)(rand() % 110) - 50) / 10); // -5 to 5 + if (rand() % 2) newsp->dir = 1; + else newsp->dir = -1; + playfx(FX_WHOOSH); } } @@ -7674,11 +7692,7 @@ void dogravity(sprite_t *s) { } else { // not jumping int ontheground; - if ((s->id == P_BIGSPEED) && (s->y < 480/2)) { - ontheground = B_FALSE; - } else if ((s->id == P_BIGSCUBA) && (s->y < 480/2)) { - ontheground = B_FALSE; - } else if ((s->id == P_SUPERUMBRELLA) && (s->y < 480/2)) { + if ((isfruit(s->id) == FT_SUPER) && (s->y < 480/2)) { ontheground = B_FALSE; } else { ontheground = isonground(s); @@ -8442,6 +8456,39 @@ int dofruiteffect(sprite_t *pp, sprite_t *s) { } } return B_TRUE; + } else if (s->id == P_BIGHELMET) { + // both players + playfx(FX_POWERUP); + if (player) { + player->permarmour = B_TRUE; + player->armour = B_TRUE; + if ((player->lives > 0) && !player->dead) { + int xx,yy; + addoutlinetext(player->x,player->y - player->img->h/2, TEXTSIZE_LIFE, "SUPER ARMOUR!", &cyan,&black,POINTSDELAY, TT_NORM); + for (xx = player->x - TILEW; xx <= player->x + TILEW; xx += TILEW) { + for (yy = player->y - TILEW*2; yy <= player->y; yy += TILEH) { + puffin(-1, xx, yy, "nothing", 0); + } + } + } + player->id = P_ARMOUR; // change how the player looks + } + if (player2) { + player2->permarmour = B_TRUE; + player2->armour = B_TRUE; + if ((player2->lives > 0) && !player2->dead) { + int xx,yy; + addoutlinetext(player2->x,player2->y - player2->img->h/2, TEXTSIZE_LIFE, "SUPER ARMOUR!", &cyan,&black,POINTSDELAY, TT_NORM); + // add puffs + for (xx = player2->x - TILEW; xx <= player2->x + TILEW; xx += TILEW) { + for (yy = player2->y - TILEW*2; yy <= player2->y; yy += TILEH) { + puffin(-1, xx, yy, "nothing", 0); + } + } + } + player2->id = P_ARMOUR; // change how the player looks + } + return B_TRUE; } else if (s->id == P_NUMNETS) { playfx(FX_POWERUP); if (pp->netmax < 4) { diff --git a/shared.c b/shared.c index 98bced2..1d79fc6 100644 --- a/shared.c +++ b/shared.c @@ -1714,6 +1714,9 @@ int loadimagesets(void) { loadspriteimage(P_UMBRELLA,F_WALK1, "sprites/umbrella.png"); imageset[P_UMBRELLA].numimages = 1; + loadspriteimage(P_EGG,F_WALK1, "sprites/egg.png"); + imageset[P_EGG].numimages = 1; + loadspriteimage(P_BIGUMBRELLA,F_WALK1, "sprites/bigumbrella.png"); imageset[P_BIGUMBRELLA].numimages = 1; @@ -1767,6 +1770,9 @@ int loadimagesets(void) { loadspriteimage(P_BIGSCUBA,F_WALK1, "sprites/bigscuba.png"); imageset[P_BIGSCUBA].numimages = 1; + loadspriteimage(P_BIGHELMET,F_WALK1, "sprites/bighelmet.png"); + imageset[P_BIGHELMET].numimages = 1; + // puffs and mace smashes for (i = 0; i < PUFFFRAMES; i++) { char name[SMALLBUFLEN]; @@ -1857,6 +1863,7 @@ int loadimagesets(void) { loadspriteimage(P_BUBBLE,F_WALK1, "sprites/bubble.png"); imageset[P_BUBBLE].numimages = 1; + /* ray gun bullet */ loadspriteimage(P_RAYGUNBULLET,F_WALK1, "sprites/raygunbullet.png"); imageset[P_RAYGUNBULLET].numimages = 1; @@ -2674,6 +2681,7 @@ int isfruit(int id) { case P_BIGSPEED: case P_BIGSCUBA: case P_SUPERUMBRELLA: + case P_BIGHELMET: return FT_SUPER; /* permenant powerups */ case P_SPEED: @@ -2737,6 +2745,7 @@ int isfruit(int id) { return FT_GEM; /* misc */ case P_POWERUPPOS: + case P_EGG: return FT_OTHER; } @@ -3334,6 +3343,7 @@ int getpoints(int id) { case P_GEMPURPLE: points = 100; break; + case P_EGG: default: points = 0; break; @@ -3658,6 +3668,7 @@ void setfruitinfo(void) { setinfo(P_BIGSPEED, "Big Speed Up", "Makes you walk faster, permenantly!", "bigspeed.png"); setinfo(P_BIGSCUBA, "Big Scuba Mask", "Permenantly gives you fast underwater movement.", "bigscuba.png"); setinfo(P_SUPERUMBRELLA, "Big Umbrella", "Bestows you with an umbrella which can survive death!", "superumbrella.png"); + setinfo(P_BIGSPEED, "Big Helmet", "Endows you with a permenant suit of armour!", "bighelmet.png"); setinfo(P_MASKPOWERUP, "Scuba Mask", "Allows you to move fast underwater.", "maskpowerup.png"); setinfo(P_WINGBOOTS, "Winged Boots", "These magical boots cause you to grow wings, allowing to you jump again while in mid-air!", "wingboots.png"); diff --git a/website/img/bighelmet.png b/website/img/bighelmet.png new file mode 100644 index 0000000..40e8cc8 Binary files /dev/null and b/website/img/bighelmet.png differ diff --git a/website/info.html b/website/info.html index b243614..b739327 100644 --- a/website/info.html +++ b/website/info.html @@ -108,8 +108,9 @@
Top HatPlayers wearing the top hat will find that every item which appears will now be a power-up! ?
RandomGives you a random effect...  Super Powerups -
Big Speed UpMakes you walk faster, permenantly! +
Big HelmetEndows you with a permenant suit of armour!
Big Scuba MaskPermenantly gives you fast underwater movement.
Big UmbrellaBestows you with an umbrella which can survive death! -  +
(null)(null) + diff --git a/website/levels/level_3_20.png b/website/levels/level_3_20.png index 44e6c06..2372c44 100644 Binary files a/website/levels/level_3_20.png and b/website/levels/level_3_20.png differ diff --git a/website/levels/level_4_1.png b/website/levels/level_4_1.png index f2891c8..9528fd4 100644 Binary files a/website/levels/level_4_1.png and b/website/levels/level_4_1.png differ diff --git a/website/levels/level_4_10.png b/website/levels/level_4_10.png index b0f39f8..72fe9a4 100644 Binary files a/website/levels/level_4_10.png and b/website/levels/level_4_10.png differ diff --git a/website/levels/level_4_11.png b/website/levels/level_4_11.png index 3870fe1..06ab274 100644 Binary files a/website/levels/level_4_11.png and b/website/levels/level_4_11.png differ diff --git a/website/levels/level_4_12.png b/website/levels/level_4_12.png index 15738be..b92ffd3 100644 Binary files a/website/levels/level_4_12.png and b/website/levels/level_4_12.png differ diff --git a/website/levels/level_4_13.png b/website/levels/level_4_13.png index d40ec94..e09f608 100644 Binary files a/website/levels/level_4_13.png and b/website/levels/level_4_13.png differ diff --git a/website/levels/level_4_14.png b/website/levels/level_4_14.png index a225a4e..2910c97 100644 Binary files a/website/levels/level_4_14.png and b/website/levels/level_4_14.png differ diff --git a/website/levels/level_4_2.png b/website/levels/level_4_2.png index 8d04761..d15470b 100644 Binary files a/website/levels/level_4_2.png and b/website/levels/level_4_2.png differ diff --git a/website/levels/level_4_3.png b/website/levels/level_4_3.png index ee0d615..97a47c7 100644 Binary files a/website/levels/level_4_3.png and b/website/levels/level_4_3.png differ diff --git a/website/levels/level_4_4.png b/website/levels/level_4_4.png index b90d9c3..f9be9e8 100644 Binary files a/website/levels/level_4_4.png and b/website/levels/level_4_4.png differ diff --git a/website/levels/level_4_5.png b/website/levels/level_4_5.png index 51feeb7..444ff65 100644 Binary files a/website/levels/level_4_5.png and b/website/levels/level_4_5.png differ diff --git a/website/levels/level_4_6.png b/website/levels/level_4_6.png index 1d659e4..5d35e2e 100644 Binary files a/website/levels/level_4_6.png and b/website/levels/level_4_6.png differ diff --git a/website/levels/level_4_7.png b/website/levels/level_4_7.png index 7496a04..6a59927 100644 Binary files a/website/levels/level_4_7.png and b/website/levels/level_4_7.png differ diff --git a/website/levels/level_4_8.png b/website/levels/level_4_8.png index a107dca..1eb328c 100644 Binary files a/website/levels/level_4_8.png and b/website/levels/level_4_8.png differ diff --git a/website/levels/level_4_9.png b/website/levels/level_4_9.png index 7a52756..51eeeb9 100644 Binary files a/website/levels/level_4_9.png and b/website/levels/level_4_9.png differ