diff --git a/TODO.txt b/TODO.txt index 58fabfd..4b5196d 100644 --- a/TODO.txt +++ b/TODO.txt @@ -24,8 +24,6 @@ Actors should be able to follow a path defined with a polyline on a layer on the Actors should be able to calculate their facing state automatically depending on their movement state (for path following) -Maps should be able to have image layers - Map parallax should work Should implement support for rendering CLAY UI elements diff --git a/assets/ffbg2-scaled.png b/assets/ffbg2-scaled.png new file mode 100644 index 0000000..5d437e9 Binary files /dev/null and b/assets/ffbg2-scaled.png differ diff --git a/assets/imagemap.tmj b/assets/imagemap.tmj new file mode 100644 index 0000000..ce881da --- /dev/null +++ b/assets/imagemap.tmj @@ -0,0 +1,99 @@ +{ "compressionlevel":-1, + "height":48, + "infinite":false, + "layers":[ + { + "id":4, + "image":"../assets/ffbg2-scaled.png", + "name":"Image Layer 1", + "offsetx":5.6843418860808e-14, + "offsety":2.01612903225805, + "opacity":1, + "type":"imagelayer", + "visible":true, + "x":0, + "y":0 + }, + { + "draworder":"topdown", + "id":2, + "locked":true, + "name":"Object Layer 1", + "objects":[ + { + "gid":147, + "height":16, + "id":1, + "name":"player", + "properties":[ + { + "name":"character", + "type":"string", + "value":"little guy" + }, + { + "name":"state", + "type":"int", + "value":24 + }], + "rotation":0, + "type":"actor", + "visible":true, + "width":16, + "x":440.510088317656, + "y":140.347239175702 + }, + { + "gid":149, + "height":16, + "id":2, + "name":"npc", + "properties":[ + { + "name":"character", + "type":"string", + "value":"little guy" + }, + { + "name":"state", + "type":"int", + "value":272 + }], + "rotation":0, + "type":"actor", + "visible":true, + "width":16, + "x":261.106052990594, + "y":156.523012852732 + }], + "opacity":1, + "type":"objectgroup", + "visible":true, + "x":0, + "y":0 + }], + "nextlayerid":5, + "nextobjectid":3, + "orientation":"orthogonal", + "renderorder":"right-down", + "tiledversion":"1.8.2", + "tileheight":16, + "tilesets":[ + { + "columns":48, + "firstgid":1, + "image":"../assets/World_A1.png", + "imageheight":576, + "imagewidth":768, + "margin":0, + "name":"World_A1", + "spacing":0, + "tilecount":1728, + "tileheight":16, + "tilewidth":16 + }], + "tilewidth":16, + "type":"map", + "version":"1.8", + "width":64 +} diff --git a/assets/properties.json b/assets/properties.json new file mode 100644 index 0000000..c94c8b1 --- /dev/null +++ b/assets/properties.json @@ -0,0 +1,7 @@ +{ + "properties": { + "some.key.with.a.value": "value", + "game.screenwidth": "640", + "game.screenheight": "480" + } +} diff --git a/deps/libakgl b/deps/libakgl index 36dfd47..b8dee45 160000 --- a/deps/libakgl +++ b/deps/libakgl @@ -1 +1 @@ -Subproject commit 36dfd47a062952b35cc34c0fbe7b0433e99101ec +Subproject commit b8dee456ca276494a483012284a239dad30d844e diff --git a/src/akgltest.c b/src/akgltest.c index 69fbf3b..3a5b2cf 100644 --- a/src/akgltest.c +++ b/src/akgltest.c @@ -115,7 +115,7 @@ SDL_AppResult SDL_AppInit(void **appstate, int argc, char *argv[]) CATCH(errctx, akgl_load_start_bgm((char *)&dirnamebuf)); CATCH(errctx, music_toggle(NULL, NULL)); - strcpy((char *)&dirnamebuf, "assets/tilemap.tmj"); + strcpy((char *)&dirnamebuf, "assets/imagemap.tmj"); CATCH(errctx, akgl_tilemap_load((char *)&dirnamebuf, (akgl_Tilemap *)&gamemap)); CATCH(errctx, akgl_text_loadfont("C64Pro", "assets/C64_Pro-STYLE.ttf", 18));