moar worldbuilding with textfile
Derek Stevens nilix@nilfm.cc
4 files changed,
5 insertions(+),
10 deletions(-)
M
Engine.c
→
Engine.c
@@ -528,6 +528,7 @@ if (quit) return;
switch (menucounter) { case 0: + playing = 1; thisChunk = LEVEL1; nextChunk = LEVEL1;@@ -539,7 +540,6 @@ warpto(mapData[0]);
hero->point.x = 160; hero->point.y = 90; - playing = 1; fclose(saveData); break;@@ -548,6 +548,7 @@ if (saveData)
{ fscanf(saveData, "%d %d %d %d %lld", &level, &roomNo, &xPos, &yPos, &eventState); } + playing = 1; thisChunk = (enum dataChunks)(level); nextChunk = (enum dataChunks)(level);@@ -559,7 +560,6 @@ hero->point.x = xPos;
hero->point.y = yPos; warpto(mapData[roomNo]); - playing = 1; fclose(saveData); printf("Loaded save: level %d, room %d (%d,%d) state: %lld\n", level, roomNo, xPos, yPos, eventState); break;
M
HyperKaos.h
→
HyperKaos.h
@@ -16,5 +16,5 @@ void cleanHyperKaos(HyperKaos* self);
void run(HyperKaos* self); void addKaos(HyperKaos* self, Kaos* target); -int isCompleted(int x); +int hasCompleted(int x); int notCompleted(int x);
M
main.c
→
main.c
@@ -14,12 +14,6 @@ #include "HyperKaos.h"
#include "WorldData.h" #include "Scene.h" -/*const int SCREEN_WIDTH = 320; -const int SCREEN_HEIGHT = 180; -const int SCREEN_BPP = 32; - -const int FRAMES_PER_SECOND = 30;*/ - int fullscreen = 0; int playing = 0; int quit = 0;@@ -79,7 +73,6 @@ }
intro(); - // main game loop while (!quit) { mainmenu();