diff --git a/desktop_version/src/Script.cpp b/desktop_version/src/Script.cpp index 850a06af..537ade05 100644 --- a/desktop_version/src/Script.cpp +++ b/desktop_version/src/Script.cpp @@ -3221,9 +3221,11 @@ void scriptclass::startgamemode( int t ) //load("intro"); break; case 22: //play custom level (in game) + { //Initilise the level //First up, find the start point - ed.weirdloadthing(ed.ListOfMetaData[game.playcustomlevel].filename); + std::string filename = std::string(ed.ListOfMetaData[game.playcustomlevel].filename); + ed.load(filename); ed.findstartpoint(); game.gamestate = GAMEMODE; @@ -3263,10 +3265,13 @@ void scriptclass::startgamemode( int t ) graphics.fademode = 4; //load("intro"); break; + } case 23: //Continue in custom level + { //Initilise the level //First up, find the start point - ed.weirdloadthing(ed.ListOfMetaData[game.playcustomlevel].filename); + std::string filename = std::string(ed.ListOfMetaData[game.playcustomlevel].filename); + ed.load(filename); ed.findstartpoint(); game.gamestate = GAMEMODE; @@ -3309,6 +3314,7 @@ void scriptclass::startgamemode( int t ) graphics.fademode = 4; //load("intro"); break; + } #endif case 100: game.savestats(); diff --git a/desktop_version/src/editor.cpp b/desktop_version/src/editor.cpp index d287ffea..008ad269 100644 --- a/desktop_version/src/editor.cpp +++ b/desktop_version/src/editor.cpp @@ -344,14 +344,6 @@ void editorclass::reset() returneditoralpha = 0; } -void editorclass::weirdloadthing(std::string t) -{ - //Stupid pointless function because I hate C++ and everything to do with it - //It's even stupider now that I don't need to append .vvvvvv anymore! bah, whatever - //t=t+".vvvvvv"; - load(t); -} - void editorclass::gethooks() { //Scan through the script and create a hooks list based on it diff --git a/desktop_version/src/editor.h b/desktop_version/src/editor.h index 041bd31c..f22a4b28 100644 --- a/desktop_version/src/editor.h +++ b/desktop_version/src/editor.h @@ -140,7 +140,6 @@ class editorclass{ int findwarptoken(int t); void countstuff(); void findstartpoint(); - void weirdloadthing(std::string t); int getlevelcol(int t); int getenemycol(int t); int entcol;