From 63280205d3adb2caa8d4d528d99ca035b7302321 Mon Sep 17 00:00:00 2001 From: "Juan J. Martinez" Date: Thu, 20 Jul 2023 22:11:26 +0100 Subject: Stage 17 --- data/stage17.json | 175 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ src/data.h | 1 + src/game.c | 3 +- 3 files changed, 178 insertions(+), 1 deletion(-) create mode 100644 data/stage17.json diff --git a/data/stage17.json b/data/stage17.json new file mode 100644 index 0000000..ed47dec --- /dev/null +++ b/data/stage17.json @@ -0,0 +1,175 @@ +{ "compressionlevel":-1, + "height":23, + "infinite":false, + "layers":[ + { + "data":[51, 52, 51, 52, 51, 52, 51, 52, 51, 52, 51, 52, 51, 52, 51, 52, 51, 52, 51, 52, 51, 52, 51, 52, 51, 52, 51, 52, 51, 52, 51, 52, 51, 52, 51, 52, 51, 52, 51, 52, 71, 72, 71, 72, 71, 72, 71, 72, 71, 72, 71, 72, 71, 72, 71, 72, 71, 72, 71, 72, 71, 72, 71, 72, 71, 72, 71, 72, 71, 72, 71, 72, 71, 72, 71, 72, 71, 72, 71, 72, 51, 52, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 51, 52, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 51, 52, 71, 72, 23, 24, 23, 24, 23, 24, 23, 24, 5, 6, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 71, 72, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 71, 72, 51, 52, 3, 4, 5, 6, 3, 4, 3, 4, 3, 4, 11, 12, 3, 4, 3, 4, 3, 4, 3, 4, 5, 6, 51, 52, 3, 5, 6, 4, 3, 4, 3, 4, 3, 4, 5, 6, 51, 52, 71, 72, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 31, 32, 5, 6, 23, 24, 23, 24, 23, 24, 23, 24, 71, 72, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 71, 72, 51, 52, 3, 4, 3, 4, 3, 4, 3, 4, 50, 50, 50, 50, 50, 50, 3, 4, 3, 4, 3, 4, 3, 4, 51, 52, 3, 4, 3, 4, 3, 4, 3, 4, 3, 4, 3, 4, 51, 52, 71, 72, 23, 24, 23, 24, 23, 5, 6, 24, 1, 2, 1, 1, 2, 1, 23, 24, 23, 24, 5, 6, 23, 24, 46, 47, 23, 24, 23, 24, 23, 24, 5, 6, 23, 24, 23, 24, 71, 72, 51, 52, 3, 4, 3, 4, 3, 4, 3, 4, 3, 22, 3, 4, 22, 4, 3, 4, 3, 4, 3, 4, 3, 4, 66, 67, 5, 6, 3, 4, 3, 4, 3, 4, 3, 4, 3, 4, 51, 52, 71, 72, 23, 24, 23, 24, 23, 24, 73, 74, 50, 50, 50, 50, 50, 50, 53, 54, 50, 50, 50, 50, 50, 50, 73, 74, 50, 50, 50, 50, 23, 24, 50, 50, 50, 50, 23, 24, 71, 72, 51, 52, 3, 4, 3, 4, 3, 4, 71, 72, 1, 1, 1, 1, 1, 1, 71, 72, 1, 2, 1, 1, 2, 1, 71, 72, 1, 1, 2, 1, 3, 4, 1, 2, 1, 1, 3, 4, 51, 52, 71, 72, 23, 24, 23, 24, 23, 24, 51, 52, 23, 24, 23, 24, 23, 24, 51, 52, 23, 22, 23, 24, 22, 24, 51, 52, 23, 24, 22, 24, 23, 24, 23, 22, 23, 24, 23, 24, 71, 72, 51, 52, 3, 5, 6, 4, 3, 4, 71, 72, 50, 50, 50, 50, 50, 50, 71, 72, 50, 50, 50, 50, 50, 50, 71, 72, 3, 4, 50, 50, 50, 50, 50, 50, 3, 4, 3, 4, 51, 52, 71, 72, 23, 24, 23, 24, 23, 24, 51, 52, 1, 2, 1, 1, 2, 1, 51, 52, 1, 1, 1, 1, 1, 1, 51, 52, 23, 24, 1, 1, 1, 1, 1, 1, 23, 24, 23, 24, 71, 72, 51, 52, 3, 4, 3, 4, 3, 4, 71, 72, 3, 22, 3, 4, 22, 4, 71, 72, 3, 5, 6, 4, 3, 4, 71, 72, 3, 4, 3, 4, 5, 6, 3, 4, 3, 4, 3, 4, 51, 52, 71, 72, 23, 24, 23, 24, 23, 24, 51, 52, 50, 50, 50, 50, 50, 50, 51, 52, 50, 50, 50, 50, 50, 50, 51, 52, 23, 24, 23, 24, 23, 24, 23, 24, 23, 5, 6, 24, 71, 72, 51, 52, 3, 4, 3, 4, 3, 4, 71, 72, 1, 1, 1, 1, 1, 1, 71, 72, 1, 2, 1, 1, 2, 1, 71, 72, 3, 4, 3, 4, 3, 4, 3, 4, 3, 4, 3, 4, 51, 52, 71, 72, 23, 24, 23, 5, 6, 24, 51, 52, 23, 24, 23, 5, 6, 24, 51, 52, 23, 22, 23, 24, 22, 24, 51, 52, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 71, 72, 51, 52, 3, 4, 3, 4, 3, 4, 71, 72, 50, 50, 50, 50, 50, 50, 71, 72, 50, 50, 50, 50, 50, 50, 71, 72, 3, 5, 6, 4, 3, 4, 3, 4, 3, 4, 3, 4, 51, 52, 71, 72, 23, 24, 23, 24, 23, 24, 1, 1, 1, 2, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 48, 49, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 23, 24, 71, 72, 51, 52, 5, 6, 3, 4, 3, 4, 3, 4, 3, 22, 3, 4, 22, 4, 3, 4, 3, 4, 3, 4, 3, 4, 68, 69, 3, 4, 3, 4, 3, 4, 3, 4, 3, 5, 6, 4, 51, 52, 71, 72, 3, 4, 3, 4, 3, 4, 53, 54, 53, 54, 53, 54, 53, 54, 3, 4, 3, 4, 3, 4, 53, 54, 53, 54, 53, 54, 53, 54, 3, 4, 53, 54, 3, 4, 3, 4, 71, 72, 51, 52, 102, 102, 102, 102, 102, 102, 71, 72, 71, 72, 71, 72, 71, 72, 102, 102, 102, 102, 102, 102, 71, 72, 71, 72, 71, 72, 71, 72, 102, 102, 71, 72, 102, 102, 102, 102, 51, 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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, 21, 21, 21, 21, 21, 21, 0, 0, 21, 21, 21, 21, 21, 21, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], + "height":23, + "id":2, + "name":"Gold", + "opacity":1, + "type":"tilelayer", + "visible":true, + "width":40, + "x":0, + "y":0 + }, + { + "draworder":"topdown", + "id":3, + "name":"Entities", + "objects":[ + { + "height":16, + "id":1, + "name":"Player", + "rotation":0, + "type":"", + "visible":true, + "width":16, + "x":96, + "y":32 + }, + { + "height":16, + "id":28, + "name":"GoldKey", + "rotation":0, + "type":"", + "visible":true, + "width":16, + "x":96, + "y":152 + }, + { + "height":16, + "id":29, + "name":"SilverKey", + "rotation":0, + "type":"", + "visible":true, + "width":16, + "x":256, + "y":152 + }, + { + "height":16, + "id":30, + "name":"Bat", + "rotation":0, + "type":"", + "visible":true, + "width":16, + "x":224, + "y":32 + }, + { + "height":16, + "id":32, + "name":"Bones", + "rotation":0, + "type":"", + "visible":true, + "width":16, + "x":80, + "y":128 + }, + { + "height":16, + "id":33, + "name":"Old", + "properties":[ + { + "name":"dir", + "type":"string", + "value":"left" + }], + "rotation":0, + "type":"", + "visible":true, + "width":16, + "x":176, + "y":128 + }, + { + "height":16, + "id":34, + "name":"Snake", + "properties":[ + { + "name":"dir", + "type":"string", + "value":"left" + }], + "rotation":0, + "type":"", + "visible":true, + "width":16, + "x":168, + "y":56 + }, + { + "height":16, + "id":35, + "name":"Bonus", + "rotation":0, + "type":"", + "visible":true, + "width":16, + "x":96, + "y":56 + }, + { + "height":16, + "id":36, + "name":"Bonus", + "rotation":0, + "type":"", + "visible":true, + "width":16, + "x":80, + "y":152 + }], + "opacity":1, + "type":"objectgroup", + "visible":true, + "x":0, + "y":0 + }], + "nextlayerid":4, + "nextobjectid":37, + "orientation":"orthogonal", + "renderorder":"right-down", + "tiledversion":"1.7.2", + "tileheight":8, + "tilesets":[ + { + "columns":20, + "firstgid":1, + "image":"tiles.png", + "imageheight":48, + "imagewidth":160, + "margin":0, + "name":"Map", + "spacing":0, + "tilecount":120, + "tileheight":8, + "tilewidth":8 + }], + "tilewidth":8, + "type":"map", + "version":"1.6", + "width":40 +} \ No newline at end of file diff --git a/src/data.h b/src/data.h index 5b2d118..d87640e 100644 --- a/src/data.h +++ b/src/data.h @@ -30,6 +30,7 @@ extern const uint8_t binary_stage13_start[]; extern const uint8_t binary_stage14_start[]; extern const uint8_t binary_stage15_start[]; extern const uint8_t binary_stage16_start[]; +extern const uint8_t binary_stage17_start[]; /* sound */ extern const uint8_t binary_music_start[]; diff --git a/src/game.c b/src/game.c index 9f9b8e3..28c0cca 100644 --- a/src/game.c +++ b/src/game.c @@ -53,13 +53,14 @@ static Entity *tmonster; /* 0-index */ #define START_STAGE 0 -#define STAGES_LEN 16 +#define STAGES_LEN 17 static const uint8_t *stages[STAGES_LEN] = { binary_stage01_start, binary_stage02_start, binary_stage03_start, binary_stage04_start, binary_stage05_start, binary_stage06_start, binary_stage07_start, binary_stage08_start, binary_stage09_start, binary_stage10_start, binary_stage11_start, binary_stage12_start, binary_stage13_start, binary_stage14_start, binary_stage15_start, binary_stage16_start, + binary_stage17_start, }; static void hud_render() -- cgit v1.2.3