diff --git a/defs.h b/defs.h index e12ebd0..02cd149 100644 --- a/defs.h +++ b/defs.h @@ -42,6 +42,7 @@ #define MAXLETTERHEIGHT 100 #define MAXFRAMES 10 #define MAXHELP 5 +#define MAXTILEFRAMES 5 // max number of frames for animated tiles // Fixed text buffer sizes #define BUFLEN 512 @@ -65,7 +66,7 @@ #define S_SLOPE 2 // Sprite types -#define MAXPTYPES 15 +#define MAXPTYPES 16 #define P_PLAYER 0 #define P_RAT 1 #define P_CHEESE 2 @@ -81,6 +82,7 @@ #define P_SNAKE 12 #define P_SPIT 13 #define P_HELP 14 +#define P_FLOWERRED 15 // Frame names #define F_WALK1 0 @@ -146,7 +148,9 @@ typedef struct tiletype_s { int solid; int water; int spikes; - SDL_Surface *img; + SDL_Surface *img[MAXTILEFRAMES]; + int numframes; + int animspeed; struct tiletype_s *next; struct tiletype_s *prev; } tiletype_t; @@ -177,8 +181,11 @@ typedef struct text_s { typedef struct level_s { int id; int bgtileid; + char *tileset; char name[SMALLBUFLEN]; int map[LEVELW*LEVELH]; + int tileframe[LEVELW*LEVELH]; // tracks frame numbers for tiles + int *animtiles; // array of offsets to map positions which are animated struct level_s *next; struct level_s *prev; int p1x; /* player 1 start pos */ @@ -231,7 +238,7 @@ typedef struct sprite_s { int falling; // are we falling? int fallspeed; // how fast are we falling? int jumping; // are we jumping? - int jumpdir; //which way are we jumping? (monsters only) + int jumpdir; //which way are we jumping? int jumpspeed; // how fast we are moving upwards int teleporting;// are we inside a teleporter? >0 is entering, <0 is exitting int dead; // is this sprite dead? if so, what dying state? diff --git a/doco/adding_a_sprite.txt b/doco/adding_a_sprite.txt new file mode 100644 index 0000000..3e5dd16 --- /dev/null +++ b/doco/adding_a_sprite.txt @@ -0,0 +1,6 @@ +- in defs.h: increment MAXPTYPES +- in defs.h: add P_ entry +- in shared.c: add score value in setdefaults if applicable +- in shared.c: add loadspriteimage() line(s) in loadimagesets() +- in shared.c: add entry to monstertochar +- in shared.c: add entry to chartomonster diff --git a/edit.c b/edit.c index 7a53194..a9449cb 100644 --- a/edit.c +++ b/edit.c @@ -89,7 +89,8 @@ int main (int argc, char **argv) { fakeblock.lowness[i] = 0; } fakeblock.solid = S_SOLID; - fakeblock.img = IMG_Load("land.bmp"); + fakeblock.img[0] = IMG_Load("land.bmp"); + fakeblock.numframes = 1; fakeblock.next = NULL; fakeblock.prev = NULL; @@ -194,6 +195,7 @@ int main (int argc, char **argv) { x = (mx / TILEW); y = (my / TILEH); curlevel->map[y*LEVELW+x] = seltile->uniqid; + curlevel->tileframe[y*LEVELW+x] = 0; // redraw tile and sprites drawtile(screen,x,y); drawsprites(); @@ -404,9 +406,9 @@ void drawpalette(void) { area.h = TILEH; for (tt = tiletype; tt != NULL; tt = tt->next) { /* draw background */ - SDL_BlitSurface(bg->img, NULL, screen, &area); + SDL_BlitSurface(bg->img[0], NULL, screen, &area); /* draw tile */ - SDL_BlitSurface(tt->img, NULL, screen, &area); + SDL_BlitSurface(tt->img[0], NULL, screen, &area); /* draw selector box */ if (seltile == tt) { drawbox16(screen,area.x,area.y,area.x+area.w-1,area.y+area.h-1,&red,NULL); @@ -475,8 +477,7 @@ int savelevel(int wnum, int lnum) { return B_TRUE; } - /* TODO: don't hardcode */ - fprintf(f, "tileset green\n"); + fprintf(f, "tileset %s\n",level->tileset); fprintf(f, "bg %d\n",level->bgtileid); fprintf(f, "hurryup %d\n",level->hurryuptime); diff --git a/newtiles/ORIG.cloudleft b/newtiles/ORIG.cloudleft new file mode 100644 index 0000000..41804b2 Binary files /dev/null and b/newtiles/ORIG.cloudleft differ diff --git a/newtiles/ORIG.full.png b/newtiles/ORIG.full.png new file mode 100644 index 0000000..2a967a8 Binary files /dev/null and b/newtiles/ORIG.full.png differ diff --git a/newtiles/bridge.png b/newtiles/bridge.png new file mode 100644 index 0000000..60ee1ce Binary files /dev/null and b/newtiles/bridge.png differ diff --git a/newtiles/bridge2.png b/newtiles/bridge2.png new file mode 100644 index 0000000..a1b6dc0 Binary files /dev/null and b/newtiles/bridge2.png differ diff --git a/newtiles/bridge3.png b/newtiles/bridge3.png new file mode 100644 index 0000000..143d07f Binary files /dev/null and b/newtiles/bridge3.png differ diff --git a/newtiles/cloudleft.png b/newtiles/cloudleft.png index 41804b2..615bfcf 100644 Binary files a/newtiles/cloudleft.png and b/newtiles/cloudleft.png differ diff --git a/newtiles/cloudmid.png b/newtiles/cloudmid.png new file mode 100644 index 0000000..2b3d0f3 Binary files /dev/null and b/newtiles/cloudmid.png differ diff --git a/newtiles/cloudright.png b/newtiles/cloudright.png index c130e76..38bddb9 100644 Binary files a/newtiles/cloudright.png and b/newtiles/cloudright.png differ diff --git a/newtiles/full.png b/newtiles/full.png index 2a967a8..eaee092 100644 Binary files a/newtiles/full.png and b/newtiles/full.png differ diff --git a/newtiles/ladder.png b/newtiles/ladder.png new file mode 100644 index 0000000..d3a5d81 Binary files /dev/null and b/newtiles/ladder.png differ diff --git a/newtiles/laddertop.png b/newtiles/laddertop.png new file mode 100644 index 0000000..a07cc33 Binary files /dev/null and b/newtiles/laddertop.png differ diff --git a/newtiles/land.bmp b/newtiles/land.bmp deleted file mode 100644 index 0332599..0000000 Binary files a/newtiles/land.bmp and /dev/null differ diff --git a/newtiles/land.png b/newtiles/land.png index e8d9ef9..90748d0 100644 Binary files a/newtiles/land.png and b/newtiles/land.png differ diff --git a/newtiles/log1.png b/newtiles/log1.png new file mode 100644 index 0000000..7156120 Binary files /dev/null and b/newtiles/log1.png differ diff --git a/newtiles/log2.png b/newtiles/log2.png new file mode 100644 index 0000000..e9ce041 Binary files /dev/null and b/newtiles/log2.png differ diff --git a/newtiles/log3.png b/newtiles/log3.png new file mode 100644 index 0000000..f05ad47 Binary files /dev/null and b/newtiles/log3.png differ diff --git a/newtiles/log4.png b/newtiles/log4.png new file mode 100644 index 0000000..da2425c Binary files /dev/null and b/newtiles/log4.png differ diff --git a/newtiles/right1.bmp b/newtiles/right1.bmp new file mode 100644 index 0000000..2b69d41 Binary files /dev/null and b/newtiles/right1.bmp differ diff --git a/newtiles/slopedown.png b/newtiles/slopedown.png new file mode 100644 index 0000000..4a1be7c Binary files /dev/null and b/newtiles/slopedown.png differ diff --git a/newtiles/slopeup.png b/newtiles/slopeup.png new file mode 100644 index 0000000..319caba Binary files /dev/null and b/newtiles/slopeup.png differ diff --git a/rc b/rc index d98b40b..736f427 100755 Binary files a/rc and b/rc differ diff --git a/rc.c b/rc.c index 4561901..5441610 100644 --- a/rc.c +++ b/rc.c @@ -82,6 +82,7 @@ int main (int argc, char **argv) { sprite_t *s,*nextsprite; char filename[BUFLEN]; int i; + int *animtile; curlevelnum = 1; @@ -132,7 +133,8 @@ int main (int argc, char **argv) { fakeblock.lowness[i] = 0; } fakeblock.solid = S_SOLID; - fakeblock.img = IMG_Load("land.bmp"); + fakeblock.img[0] = IMG_Load("land.bmp"); + fakeblock.numframes = 1; fakeblock.next = NULL; fakeblock.prev = NULL; @@ -224,6 +226,9 @@ int main (int argc, char **argv) { /* check for keys */ SDL_PumpEvents(); keys = SDL_GetKeyState(NULL); + + + if (keys[SDLK_q]) { gtime = curlevel->hurryuptime -1; } @@ -323,6 +328,32 @@ int main (int argc, char **argv) { } } + + // for each animated tile on the level... + for (animtile = curlevel->animtiles; animtile && *animtile != -1; animtile++) { + int offset,numframes; + tiletype_t *tt; + + offset = *animtile; + + tt = gettile(curlevel->map[offset]); + + numframes = tt->numframes; + + // is it time to change frames? + if ((timer % tt->animspeed) == 0) { + // change its frame + curlevel->tileframe[offset]++; + if (curlevel->tileframe[offset] >= numframes) { + curlevel->tileframe[offset] = 0; + } + // redraw it + drawtile(temps, offset%LEVELW,offset/LEVELW); + } + + } + + // move sprites for (s = sprite; s ; s = s->next) { movesprite(s); } @@ -1283,9 +1314,11 @@ int addtext(int x, int y, int size, char *string, SDL_Color *c, int delay) { } +/* copy background buffer (ie. tiles) to screen, erasing sprites */ void removeall(void) { SDL_BlitSurface(temps, NULL, screen, NULL); } + void removetext(void) { SDL_Rect sarea; text_t *t; diff --git a/shared.c b/shared.c index fb981fc..5f72972 100644 --- a/shared.c +++ b/shared.c @@ -32,13 +32,18 @@ int loadlevel(int wnum, int lnum) { char *p; int tileid; int i; + int *ii; mapping_t mapping[MAXMAPPINGS]; int nmappings = 0; tiletype_t *lasttile; int newversion; + int numanim = 0; + int tempanim[LEVELW*LEVELH]; - level = malloc(sizeof(level_t)); + if (!level) level = malloc(sizeof(level_t)); + + if (level->animtiles) free(level->animtiles); level->id = 0; sprintf(level->name, "Level %d-%d",wnum,lnum); @@ -60,16 +65,19 @@ int loadlevel(int wnum, int lnum) { /* clear tiletype linked list */ while (tiletype != NULL) { + int i; tiletype_t *tt; /* kill first tile */ - if (tiletype->img) { - SDL_FreeSurface(tiletype->img); - tiletype->img = NULL; - tt = tiletype->next; - free(tiletype); - tiletype = tt; + for (i = 0; i < tiletype->numframes; i++) { + if (tiletype->img[i]) { + SDL_FreeSurface(tiletype->img[i]); + tiletype->img[i] = NULL; + } } + tt = tiletype->next; + free(tiletype); + tiletype = tt; } /* clear player linked list */ @@ -88,6 +96,11 @@ int loadlevel(int wnum, int lnum) { /* strip newline */ p[strlen(p)-1] = '\0'; + + + if ( level->tileset) free(level->tileset); + level->tileset = strdup(p); + strcat(p, ".tiles"); if (loadtiletypes(p)) { @@ -256,6 +269,7 @@ int loadlevel(int wnum, int lnum) { strncpy(buf2, buf, BUFLEN); p = strtok(buf2, ","); while (p) { + int numframes; tileid = atoi(p); /* validate it */ if (!gettile(tileid)) { @@ -276,6 +290,17 @@ int loadlevel(int wnum, int lnum) { /* all okay */ level->map[y*LEVELW+x] = tileid; + numframes = gettileframecount(tileid); + if (numframes == 1) { + // not animated + level->tileframe[y*LEVELW+x] = 0; + } else { + // animated + level->tileframe[y*LEVELW+x] = rand() % numframes; + tempanim[numanim] = y*LEVELW+x; + numanim++; + } + x++; p = strtok(NULL, ","); } @@ -451,6 +476,14 @@ int loadlevel(int wnum, int lnum) { } fclose(f); + + + // copy from our temp buffer into the real one + level->animtiles = malloc(sizeof(int) * (numanim+1)); + memcpy(level->animtiles,tempanim,numanim*sizeof(int)); + level->animtiles[numanim] = -1; + //level->animtiles = realloc(level->animtiles, (numanim+2) * sizeof(int)); // leave space for terminator + if ((numhelp > 0) && (curhelp != numhelp)) { printf("WARNING: Unused help text. First unused is '%s'\n",help[curhelp]); } @@ -498,6 +531,12 @@ int loadlevel(int wnum, int lnum) { gtime = 0; +printf("Loaded level. Animated tiles: "); +for (ii = level->animtiles ; ii && *ii != -1; ii++) { + printf("%d ",*ii); +} +printf(".\n"); + return B_FALSE; } @@ -552,6 +591,9 @@ void setdefaults(sprite_t *s) { case P_BURGER: s->score = 4000; break; + case P_FLOWERRED: + s->score = 5; + break; default: s->score = 0; break; @@ -679,13 +721,17 @@ int loadtiletypes(char *filename) { /* defaults */ t->id = 0; + t->animspeed = 0; // not animated + t->numframes = 1; // not animated t->water = B_FALSE; t->spikes = B_FALSE; t->solid = B_TRUE; for (i = 0; i < TILEW; i++) { t->lowness[i] = 0; } - t->img = NULL; + for (i = 0; i < MAXTILEFRAMES; i++) { + t->img[i] = NULL; + } t->next = NULL; state = 1; @@ -695,12 +741,18 @@ int loadtiletypes(char *filename) { } } else if (state == 1) { /* inside a definition */ if (strstr(buf, "end") == buf) { + //printf("got tile %d: %s (solid=%d)\n",t->id,t->name,t->solid); + /* check */ state = 0; } else if (strstr(buf, "id") == buf) { p = strtok(buf, " "); p = strtok(NULL, " "); t->id = atoi(p); + } else if (strstr(buf, "animspeed") == buf) { + p = strtok(buf, " "); + p = strtok(NULL, " "); + t->animspeed = atoi(p); } else if (strstr(buf, "lowness") == buf) { p = strtok(buf, " "); p = strtok(NULL, " "); @@ -722,21 +774,37 @@ int loadtiletypes(char *filename) { p = strtok(NULL, " "); t->water = atoi(p); } else if (strstr(buf, "file") == buf) { - p = strtok(buf, " "); - p = strtok(NULL, " "); - if (t->img) { - SDL_FreeSurface(t->img); - t->img = NULL; - } + int frame; + /* strip newline */ - p[strlen(p)-1] = '\0'; - t->img = IMG_Load(p); - if (!t->img) { - printf("cannot load tile image file: '%s'\n",p); - fclose(f); - return B_TRUE; + buf[strlen(buf)-1] = '\0'; + + p = strtok(buf, " "); + + // read all images + frame = 0; + p = strtok(NULL, " "); + while (p) { + if (t->img[frame]) { + SDL_FreeSurface(t->img[frame]); + t->img[frame] = NULL; + } + t->img[frame] = IMG_Load(p); + if (!t->img[frame]) { + printf("cannot load tile image file: '%s'\n",p); + fclose(f); + return B_TRUE; + } + // black is transparent + SDL_SetColorKey(t->img[frame], SDL_SRCCOLORKEY, SDL_MapRGB(screen->format, 0, 0, 0)); + + // get next one + frame++; + p = strtok(NULL, " "); } - SDL_SetColorKey(t->img, SDL_SRCCOLORKEY, SDL_MapRGB(screen->format, 0, 0, 0)); + t->numframes = frame; + // default animation speed + t->animspeed = 20; } } @@ -754,82 +822,85 @@ int loadimagesets(void) { SDL_Surface *reds; - imageset[P_PLAYER].img[F_WALK1] = IMG_Load("sprites/pdwarf.png"); - imageset[P_PLAYER].img[F_JUMP] = IMG_Load("sprites/pdwarfjump.png"); - imageset[P_PLAYER].img[F_FALL] = IMG_Load("sprites/pdwarffall.png"); - imageset[P_PLAYER].img[F_CAUGHT] = IMG_Load("sprites/pdwarf.png"); - imageset[P_PLAYER].img[F_DEAD] = IMG_Load("sprites/dwarfdie.png"); + loadspriteimage(P_PLAYER,F_WALK1, "sprites/pdwarf.png"); + loadspriteimage(P_PLAYER,F_JUMP, "sprites/pdwarfjump.png"); + loadspriteimage(P_PLAYER,F_FALL, "sprites/pdwarffall.png"); + loadspriteimage(P_PLAYER,F_CAUGHT, "sprites/pdwarf.png"); + loadspriteimage(P_PLAYER,F_DEAD, "sprites/dwarfdie.png"); /* next 3 are auto generated */ - imageset[P_PLAYER].img[F_CLIMB1] = IMG_Load("sprites/dclimb1.png"); - imageset[P_PLAYER].img[F_CLIMB2] = IMG_Load("sprites/dclimb2.png"); + loadspriteimage(P_PLAYER,F_CLIMB1, "sprites/dclimb1.png"); + loadspriteimage(P_PLAYER,F_CLIMB2, "sprites/dclimb2.png"); imageset[P_PLAYER].numimages = 10; - imageset[P_SNAKE].img[F_WALK1] = IMG_Load("sprites/snake.bmp"); - imageset[P_SNAKE].img[F_JUMP] = IMG_Load("sprites/snakejump.bmp"); - imageset[P_SNAKE].img[F_FALL] = IMG_Load("sprites/snakejump.bmp"); - imageset[P_SNAKE].img[F_CAUGHT] = IMG_Load("sprites/snakecaught.bmp"); - imageset[P_SNAKE].img[F_DEAD] = IMG_Load("sprites/snakedead.bmp"); + loadspriteimage(P_SNAKE,F_WALK1, "sprites/snake.bmp"); + loadspriteimage(P_SNAKE,F_JUMP, "sprites/snakejump.bmp"); + loadspriteimage(P_SNAKE,F_FALL, "sprites/snakejump.bmp"); + loadspriteimage(P_SNAKE,F_CAUGHT, "sprites/snakecaught.bmp"); + loadspriteimage(P_SNAKE,F_DEAD, "sprites/snakedead.bmp"); /* next 3 are auto generated */ imageset[P_SNAKE].numimages = 8; - imageset[P_RAT].img[F_WALK1] = IMG_Load("sprites/rat.bmp"); - imageset[P_RAT].img[F_JUMP] = IMG_Load("sprites/ratjump.bmp"); - imageset[P_RAT].img[F_FALL] = IMG_Load("sprites/ratjump.bmp"); - imageset[P_RAT].img[F_CAUGHT] = IMG_Load("sprites/ratcaught.bmp"); - imageset[P_RAT].img[F_DEAD] = IMG_Load("sprites/ratdead.bmp"); + loadspriteimage(P_RAT,F_WALK1, "sprites/rat.bmp"); + loadspriteimage(P_RAT,F_JUMP, "sprites/ratjump.bmp"); + loadspriteimage(P_RAT,F_FALL, "sprites/ratjump.bmp"); + loadspriteimage(P_RAT,F_CAUGHT, "sprites/ratcaught.bmp"); + loadspriteimage(P_RAT,F_DEAD, "sprites/ratdead.bmp"); /* next 3 are auto generated */ imageset[P_RAT].numimages = 8; - imageset[P_BEE].img[F_WALK1] = IMG_Load("sprites/bee.bmp"); - imageset[P_BEE].img[F_JUMP] = IMG_Load("sprites/beejump.bmp"); - imageset[P_BEE].img[F_FALL] = IMG_Load("sprites/beejump.bmp"); - imageset[P_BEE].img[F_CAUGHT] = IMG_Load("sprites/beecaught.bmp"); - imageset[P_BEE].img[F_DEAD] = IMG_Load("sprites/beedead.bmp"); + loadspriteimage(P_BEE,F_WALK1, "sprites/bee.bmp"); + loadspriteimage(P_BEE,F_JUMP, "sprites/beejump.bmp"); + loadspriteimage(P_BEE,F_FALL, "sprites/beejump.bmp"); + loadspriteimage(P_BEE,F_CAUGHT, "sprites/beecaught.bmp"); + loadspriteimage(P_BEE,F_DEAD, "sprites/beedead.bmp"); /* next 3 are auto generated */ imageset[P_BEE].numimages = 8; - imageset[P_SPIDER].img[F_WALK1] = IMG_Load("sprites/spider.bmp"); - imageset[P_SPIDER].img[F_JUMP] = IMG_Load("sprites/spiderjump.bmp"); - imageset[P_SPIDER].img[F_FALL] = IMG_Load("sprites/spiderfall.bmp"); - imageset[P_SPIDER].img[F_CAUGHT] = IMG_Load("sprites/spidercaught.bmp"); - imageset[P_SPIDER].img[F_DEAD] = IMG_Load("sprites/spiderdead.bmp"); + loadspriteimage(P_SPIDER,F_WALK1, "sprites/spider.bmp"); + loadspriteimage(P_SPIDER,F_JUMP, "sprites/spiderjump.bmp"); + loadspriteimage(P_SPIDER,F_FALL, "sprites/spiderfall.bmp"); + loadspriteimage(P_SPIDER,F_CAUGHT, "sprites/spidercaught.bmp"); + loadspriteimage(P_SPIDER,F_DEAD, "sprites/spiderdead.bmp"); /* next 3 are auto generated */ imageset[P_SPIDER].numimages = 8; - imageset[P_CLOUD].img[F_WALK1] = IMG_Load("sprites/cloud.bmp"); - imageset[P_CLOUD].img[F_JUMP] = IMG_Load("sprites/cloud.bmp"); - imageset[P_CLOUD].img[F_FALL] = IMG_Load("sprites/cloud.bmp"); - imageset[P_CLOUD].img[F_CAUGHT] = IMG_Load("sprites/cloud.bmp"); - imageset[P_CLOUD].img[F_DEAD] = IMG_Load("sprites/cloud.bmp"); + loadspriteimage(P_CLOUD,F_WALK1, "sprites/cloud.bmp"); + loadspriteimage(P_CLOUD,F_JUMP, "sprites/cloud.bmp"); + loadspriteimage(P_CLOUD,F_FALL, "sprites/cloud.bmp"); + loadspriteimage(P_CLOUD,F_CAUGHT, "sprites/cloud.bmp"); + loadspriteimage(P_CLOUD,F_DEAD, "sprites/cloud.bmp"); imageset[P_CLOUD].numimages = 2; - imageset[P_CHEESE].img[F_WALK1] = IMG_Load("sprites/cheese.bmp"); + loadspriteimage(P_CHEESE,F_WALK1, "sprites/cheese.bmp"); imageset[P_CHEESE].numimages = 1; - imageset[P_ICECREAM].img[F_WALK1] = IMG_Load("sprites/icecream.bmp"); + loadspriteimage(P_ICECREAM,F_WALK1, "sprites/icecream.bmp"); imageset[P_ICECREAM].numimages = 1; - imageset[P_CHIPS].img[F_WALK1] = IMG_Load("sprites/chips.bmp"); + loadspriteimage(P_CHIPS,F_WALK1, "sprites/chips.bmp"); imageset[P_CHIPS].numimages = 1; - imageset[P_BURGER].img[F_WALK1] = IMG_Load("sprites/burger.bmp"); + loadspriteimage(P_BURGER,F_WALK1, "sprites/burger.bmp"); imageset[P_BURGER].numimages = 1; - imageset[P_SPEED].img[F_WALK1] = IMG_Load("sprites/speed.bmp"); + loadspriteimage(P_SPEED,F_WALK1, "sprites/speed.bmp"); imageset[P_SPEED].numimages = 1; - imageset[P_NUMNETS].img[F_WALK1] = IMG_Load("sprites/numnets.bmp"); + loadspriteimage(P_NUMNETS,F_WALK1, "sprites/numnets.bmp"); imageset[P_NUMNETS].numimages = 1; - imageset[P_BIGNET].img[F_WALK1] = IMG_Load("sprites/bignet.bmp"); + loadspriteimage(P_BIGNET,F_WALK1, "sprites/bignet.bmp"); imageset[P_BIGNET].numimages = 1; - imageset[P_HELP].img[F_WALK1] = IMG_Load("sprites/help.bmp"); + loadspriteimage(P_HELP,F_WALK1, "sprites/help.bmp"); imageset[P_HELP].numimages = 1; + loadspriteimage(P_FLOWERRED,F_WALK1, "sprites/flower-red.png"); + imageset[P_FLOWERRED].numimages = 1; + /* bullets */ - imageset[P_SPIT].img[F_WALK1] = IMG_Load("sprites/spit.bmp"); + loadspriteimage(P_SPIT,F_WALK1, "sprites/spit.bmp"); imageset[P_SPIT].numimages = 1; @@ -1065,6 +1136,14 @@ void flip(void) { #endif } +// returns 0 if tile isn't animated, else the number of frames +int gettileframecount(int tid) { + tiletype_t *tt; + + tt = gettile(tid); + return tt->numframes; +} + int isfruit(int id) { switch (id) { case P_CHEESE: @@ -1075,6 +1154,7 @@ int isfruit(int id) { case P_NUMNETS: case P_BIGNET: case P_HELP: + case P_FLOWERRED: return B_TRUE; } @@ -1240,6 +1320,7 @@ int chartomonster(char ch) { case 's': return P_SPIDER; case '?': return P_HELP; case '1': return P_PLAYER; + case '@': return P_FLOWERRED; } return -1; @@ -1253,6 +1334,7 @@ char monstertochar(int id ) { case P_SPIDER: return 's'; case P_HELP: return '?'; case P_PLAYER: return '1'; + case P_FLOWERRED: return '@'; } return '\0'; @@ -1271,6 +1353,8 @@ tiletype_t *gettile(int tid) { void drawtile(SDL_Surface *where, int x, int y) { SDL_Rect area; tiletype_t *tt; + int frame; + int offset; if ((x < 0) || (y < 0) || (x >= LEVELW) || (y >= LEVELH)) { return; @@ -1282,17 +1366,23 @@ void drawtile(SDL_Surface *where, int x, int y) { area.h = 0; /* draw blank tile first */ tt = gettile(curlevel->bgtileid); - SDL_BlitSurface(tt->img, NULL, where, &area); + SDL_BlitSurface(tt->img[0], NULL, where, &area); - tt = gettile(curlevel->map[y*LEVELW+x]); + /* now draw real one */ + offset = y*LEVELW+x; + tt = gettile(curlevel->map[offset]); + frame = curlevel->tileframe[offset]; if (tt->id != curlevel->bgtileid) { - SDL_BlitSurface(tt->img, NULL, where, &area); + SDL_BlitSurface(tt->img[frame], NULL, where, &area); } + } void initglobals(void) { sprite = NULL; + level = NULL; + vidargs = 0; /* timers */ @@ -1307,3 +1397,15 @@ void initglobals(void) { green.r = 0; green.g = 255; green.b = 0; yellow.r = 255; yellow.g = 255; yellow.b = 0; } + + + +SDL_Surface *loadspriteimage(int spriteid, int frame, char *filename) { + imageset[spriteid].img[frame] = IMG_Load(filename); + + if (imageset[spriteid].img[frame] == NULL) { + printf("Error loading image file: %s\n",filename); + exit(1); + } + return imageset[spriteid].img[frame]; +} diff --git a/shared.h b/shared.h index 5608877..8dff819 100644 --- a/shared.h +++ b/shared.h @@ -15,6 +15,7 @@ int isbullet(int id); void flip(void); void killsprite(sprite_t *s); void drawsprite(sprite_t *s); +int gettileframecount(int tid); int isfruit(int id); inline void drawpixel16(SDL_Surface *screen, int x, int y, SDL_Color c); inline void drawpixel32(SDL_Surface *screen, int x, int y, SDL_Color c); @@ -26,5 +27,7 @@ char monstertochar(int id); tiletype_t *gettile(int tid); void drawtile(SDL_Surface *s, int x, int y); void initglobals(void); + +SDL_Surface *loadspriteimage(int spriteid, int frame, char *filename); #endif diff --git a/sprites/flower-red.png b/sprites/flower-red.png new file mode 100644 index 0000000..06c15d7 Binary files /dev/null and b/sprites/flower-red.png differ diff --git a/world1/level1.dat b/world1/level1.dat index 1e36e7e..f8bb112 100644 --- a/world1/level1.dat +++ b/world1/level1.dat @@ -11,6 +11,14 @@ monsters r 27 15 ? 7 19 ? 12 19 +@ 16 14 +@ 36 14 +@ 2 15 +@ 1 15 +@ 22 15 +@ 23 15 +@ 30 15 +@ 31 15 endmonsters 4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4, 4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4, @@ -27,12 +35,12 @@ endmonsters 4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4, 4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4, 4,0,0,0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,4,4,4,4,4,4,4,4,4,4, 4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4, 4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4, 4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4, diff --git a/world1/level2.dat b/world1/level2.dat index 34b449b..b534a88 100644 --- a/world1/level2.dat +++ b/world1/level2.dat @@ -9,11 +9,11 @@ Stand on this ledge then slam! endhelp monsters 1 4 10 -r 33 9 -r 16 10 ? 6 10 ? 12 10 ? 25 10 +r 34 9 +r 17 10 endmonsters 4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,0,0,0,0,0,0,0,0,0,4, 4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,0,0,0,0,0,0,0,0,0,4, @@ -24,8 +24,8 @@ endmonsters 4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,0,0,0,0,0,0,0,0,0,4, 4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4, 4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4, -4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4,0,4,0,0,0,0,4, -4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4,0,4,0,0,0,0,0,0,0,0,0,1,0,0,0,0,4,4,4,0,0,0,0,4, +4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,1,0,0,4, +4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4,0,0,0,4,0,0,0,0,0,0,0,1,0,0,0,0,4,1,1,1,4,0,0,4, 4,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,4,1,1,1,1,1,1,1,1,1,1,1,4, 4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4, 4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4, diff --git a/world1/level3.dat b/world1/level3.dat index 788a741..af7e844 100644 --- a/world1/level3.dat +++ b/world1/level3.dat @@ -11,34 +11,91 @@ r 5 7 r 35 7 r 35 23 r 4 23 +@ 26 11 +@ 27 11 +@ 28 11 +@ 28 19 +@ 27 19 +@ 26 19 +@ 12 11 +@ 13 11 +@ 14 11 +@ 14 19 +@ 13 19 +@ 12 19 +@ 2 7 +@ 37 7 +@ 37 23 +@ 2 23 +@ 18 28 +@ 18 28 +@ 18 28 +@ 18 28 +@ 18 28 +@ 18 28 +@ 18 28 +@ 18 28 +@ 18 28 +@ 19 28 +@ 20 28 +@ 20 28 +@ 20 28 +@ 21 28 +@ 21 28 +@ 21 28 +@ 21 28 +@ 21 28 +@ 22 28 +@ 22 28 +@ 22 28 +@ 22 28 +@ 22 28 +@ 22 28 +@ 22 28 +@ 22 28 +@ 22 28 +@ 22 28 +@ 23 28 +@ 23 28 +@ 23 28 +@ 23 28 +@ 23 28 +@ 23 28 +@ 23 28 +@ 23 28 +@ 23 28 +@ 17 28 +@ 17 28 +@ 16 28 +@ 16 28 endmonsters -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*~~~~~~~~~~000000000000000000~~~~~~~~~~* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*0000000~~~~~~~~~~0000~~~~~~~~~~0000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*00000000000000~~~~~~~~~~00000000000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*0000000~~~~~~~~~~0000~~~~~~~~~~0000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*~~~~~~~~~~000000000000000000~~~~~~~~~~* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4, +4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4, +4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4, +4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4, +4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4, +4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4, +4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0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0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4, +4,0,0,0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,0,0,0,0,1,1,1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,4, +4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4, +4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4, +4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4, +4,1,1,1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,4, +4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4, +4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4, +4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4, +4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4, +1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1, diff --git a/world1/level5.dat b/world1/level5.dat index a630e01..809666b 100644 --- a/world1/level5.dat +++ b/world1/level5.dat @@ -2,7 +2,10 @@ tileset green bg 0 hurryup 30 endmaps +help +endhelp monsters +1 3 28 r 10 4 r 23 8 r 23 16 @@ -10,35 +13,34 @@ r 12 20 r 28 20 r 25 24 r 30 28 -1 3 28 endmonsters -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*000000~~~~~~~~~~~~**000000000000000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*000000000000~~~~~~~~~~~~~~~00000000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*00000000000000/~~~~~~~~~\0000000000000* -*0000000000000/***********\000000000000* -*000000000000/**000000000**\00000000000* -*00000000000/***000000000***\0000000000* -*000~~~~~~~~~~~~~~0000~~~~~~~~~~~~~~000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*000000000~~~~0000000000000~~~~00000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*000~~~~~0000~~~~~0000~~~~~~~~~~~~~~000* -*0000000000000000*0000*0000000000000000* -*0000000000000000*0000*0000000000000000* -*0000000000000000*^^^^*0000000000000000* -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4, +4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4, +4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4, +4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4, +4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0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/level6.dat b/world1/level6.dat index 3ef42c8..a622146 100644 --- a/world1/level6.dat +++ b/world1/level6.dat @@ -2,40 +2,42 @@ tileset green bg 0 hurryup 30 endmaps +help +endhelp monsters +1 1 14 r 27 9 r 33 9 -1 1 14 r 18 15 r 21 19 endmonsters -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*0000000000000000000000*000000000000000* -*0000000000000000000000*000000000000000* -*0000000000000000000000*000000000000000* -*0000000000000000000000*000000000000000* -*0000000000000000000000*~~~~~~~~~~~~~~-* -*0000000000000000000000000000000000000=* -*0000000000000000000000000000000000000=* -*0000000000000000000000000000000000000=* -*0000000000000000000000000000000000000=* -*~000000000000000000000000000000000000=* -*00000000000000~~~~~~~~~~0000000000000=* -*0000000000000000000000000000000000000=* -*>>>00000000000000000000000000000000<<~* -****>000000000000000000000000000000<000* -*****>000000000~~~~~~~~~~000000000<0000* -******>>>0000000000000000000000<<<00000* -*********>>>0000000000000000<<<00000000* -************>>>>00000000<<<<00000000000* -****************00000000*00000000000000* -****************00000000*00000000000000* -****************000**000*00000000000000* -****************00000000*00000000000000* -****************^^^^^^^^*00000000000000* -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4, +4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4, +4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,18,19,0,0,0,0,0,0,0,4, +4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4, +4,0,0,18,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,1,1,1,1,1,1,1,1,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4, diff --git a/world1/level7.dat b/world1/level7.dat index 500afa6..efbdcb1 100644 --- a/world1/level7.dat +++ b/world1/level7.dat @@ -2,41 +2,43 @@ tileset green bg 0 hurryup 30 endmaps +help +endhelp monsters +1 2 28 a 21 4 r 7 8 r 32 13 r 17 18 r 28 22 -1 2 28 endmonsters -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*0~~-~~~~~00000000000000000000000000000* -*000=0000000000000000000000000000000000* -*000=0000000000~~~~~~000000000000000000* -*000=0000000000000000000000000000000000* -*000=0000000000000000000000000000000000* -*000=0000000000000000000000000~~~~~-~~~* -*000=000000000000000000000000000000=000* -*000=000000000000000000000000000000=000* -*000=000000000000000000000000000000=000* -*000=0000000000000^^000000000000000=000* -*000=00000~~~~~-~~~~~00000000000000=000* -*000=0000000000=0000000000000000000=000* -*000=0000000000=0000000000000000000=000* -*000=0000000000=0000000000000000000=000* -*000=0000000000=0000000~~~-~~~~0000=000* -*000=0000000000=0000000000=00000000=000* -*000=0000000000=0000000000=00000000=000* -*000=0000000000=0000000000=00000000=000* -*000=0000000000=0000000000=00000000=000* -*000=0000000000=0000000000=00000000=000* -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4, +4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4, +4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0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,0,0,0,0,0,0,0,0,7,0,0,0,0,0,0,0,0,0,0,7,0,0,0,0,0,0,0,0,7,0,0,0,4, +1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1, diff --git a/world1/level8.dat b/world1/level8.dat index 123be46..3fce017 100644 --- a/world1/level8.dat +++ b/world1/level8.dat @@ -2,43 +2,45 @@ tileset castle bg 0 hurryup 30 endmaps +help +endhelp monsters +1 1 21 a 10 3 a 35 3 r 19 6 r 3 7 r 37 8 -1 1 21 -s 14 23 -s 26 23 +s 14 24 +s 26 24 endmonsters -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*00000000000000000000000000000000000000* -*0000000000000000000000=000000000000000* -*0000000000000000000000=000000000000000* -*000000000000000~~~~~~~-~~~~00000000000* -*~~~~~~\000000000000000=000000000000000* -********\00000000000000=000000000~~~~~~* -*********00000000000000=000000000000000* -*0000000000000000000000=000000000000000* -*00000000000~~~-~0000~~~~~000-~~~~~0000* -*00000000000000=0000000000000=000000000* -*00000000000000=0000000000000=000000000* -*00000000000000=0000000000000=000000000* -*00000000000000=0000000000000=000000000* -*00000000000000=0000000000000=000000000* -*00000000000000=000/~~~\00000=000000000* -*00000000000000=00/*****\0000=000000000* -*00000000/~~\00=0/*******\00/~\00000000* -*0000000/****~~~~*********~~***\0000000* -*~~{{{~~************************{{{{{{{* -*}}}}}}}}}}}}}0}}}}}*}}}}}0}}}}}}}}}}}}* -*}}}}}}}}}}}}}}}}}}}*}}}}}}}}}}}}}}}}}}* -*}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}* -*}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}* -*}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}* -*}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}* -~~~~~~~~~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,14,14,14,4, +4,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,4, +4,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,4, +4,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,4, +4,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,14,4, +1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,