]> git.mxchange.org Git - quix0rs-blobwars.git/blobdiff - src/cutscene.cpp
Added .gitignore to ignore certain files + fixed access rights on Makefile* as
[quix0rs-blobwars.git] / src / cutscene.cpp
index 4e37d9b5dac9dab6eb80ffcee170ac1cc3a6f1de..68672b6b0a3a779f139dbfa3dce9fce8a8d80c8a 100644 (file)
@@ -1,5 +1,6 @@
 /*
 Copyright (C) 2004-2011 Parallel Realities
+Copyright (C) 2011-2015 Perpendicular Dimensions
 
 This program is free software; you can redistribute it and/or
 modify it under the terms of the GNU General Public License
@@ -20,6 +21,8 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
 
 #include "cutscene.h"
 
+List sceneList;
+
 void createSceneList()
 {
        char sceneLine[1024] = "";
@@ -61,7 +64,7 @@ void createSceneList()
                        line = strtok(NULL, "\n");
                }
                
-               if (strcmp(line, "@none@") != 0)
+               if (scene && strcmp(line, "@none@") != 0)
                {
                        scene->appendText(line);
                }
@@ -75,7 +78,7 @@ bool setupScene(const char *stagename)
        char sceneLine[1024];
 
        if (!engine.loadData(_("data/ending")))
-               graphics.showErrorAndExit("Couldn't load cutscene data file (%s)", _("data/ending"));
+               return graphics.showErrorAndExit("Couldn't load cutscene data file (%s)", _("data/ending")), false;
 
        char *line = strtok((char*)engine.dataBuffer, "\n");
        int i = 0;