From e60c04be85230767c799902da6cf967aedd111a9 Mon Sep 17 00:00:00 2001 From: SilicaAndPina Date: Sat, 25 Jul 2020 01:50:25 +1200 Subject: [PATCH] CommitLog | --- Spaceinator.project.gmx | 1 + objects/obj_controller.object.gmx | 2 +- objects/obj_controller_world_gen.object.gmx | 26 ++++++++++++++++++++- scripts/save_game_data.gml | 2 ++ 4 files changed, 29 insertions(+), 2 deletions(-) create mode 100644 scripts/save_game_data.gml diff --git a/Spaceinator.project.gmx b/Spaceinator.project.gmx index 2305a25..109e26c 100644 --- a/Spaceinator.project.gmx +++ b/Spaceinator.project.gmx @@ -29,6 +29,7 @@ + objects\obj_player diff --git a/objects/obj_controller.object.gmx b/objects/obj_controller.object.gmx index cc656ee..2f5a501 100644 --- a/objects/obj_controller.object.gmx +++ b/objects/obj_controller.object.gmx @@ -53,7 +53,7 @@ if(!global.debug) { draw_set_color(c_white); - draw_healthbar(10,10,500,30,(obj_player.energy/obj_player.energy_max)*100,c_gray,c_yellow,c_blue,0,true,false); + draw_healthbar(10,10,500,30,(obj_player.energy/obj_player.energy_max)*100,c_gray,c_blue,c_navy,0,true,false); draw_text(11,13,string(obj_player.energy)+" / "+string(obj_player.energy_max)); draw_healthbar(10,40,300,60,(obj_player.hp/obj_player.hp_max)*100,c_gray,c_red,c_green,0,true,false); diff --git a/objects/obj_controller_world_gen.object.gmx b/objects/obj_controller_world_gen.object.gmx index 9af7238..ee8635e 100644 --- a/objects/obj_controller_world_gen.object.gmx +++ b/objects/obj_controller_world_gen.object.gmx @@ -8,6 +8,29 @@ <undefined> <undefined> + + + 1 + 603 + 7 + 0 + 0 + -1 + 2 + + + self + 0 + 0 + + + 1 + global.allchunks = ds_list_create(); + + + + + 1 @@ -32,7 +55,8 @@ for(var i = 0; i < 16; i ++) var chunkat = instance_position(cX[i], cY[i],obj_chunk); if(chunkat == noone) // create { - instance_create(cX[i],cY[i],obj_chunk); + var chunkInstId = instance_create(cX[i],cY[i],obj_chunk); + ds_list_add(global.allchunks,chunkInstId); } else // load { diff --git a/scripts/save_game_data.gml b/scripts/save_game_data.gml new file mode 100644 index 0000000..635d57b --- /dev/null +++ b/scripts/save_game_data.gml @@ -0,0 +1,2 @@ +///save_game_data +