From c97b28f238e2bee706019598f531bf431e27aca1 Mon Sep 17 00:00:00 2001 From: Misa Date: Mon, 7 Sep 2020 21:22:44 -0700 Subject: [PATCH] Don't hardcode destroy() arguments in loadcustom() Otherwise, the new arguments to destroy(), which are 'moving' and 'disappear', would be thrown away by the simplified parser. Let's create less work for ourselves to do and simply not have a hardcoded list of allowed arguments for destroy() in the parser. --- desktop_version/src/Script.cpp | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/desktop_version/src/Script.cpp b/desktop_version/src/Script.cpp index b9b88151..a9577aa1 100644 --- a/desktop_version/src/Script.cpp +++ b/desktop_version/src/Script.cpp @@ -3768,13 +3768,7 @@ void scriptclass::loadcustom(const std::string& t) add("custom"+lines[i]); }else if(words[0] == "destroy"){ if(customtextmode==1){ add("endtext"); customtextmode=0;} - if(words[1]=="gravitylines"){ - add("destroy(gravitylines)"); - }else if(words[1]=="warptokens"){ - add("destroy(warptokens)"); - }else if(words[1]=="platforms"){ - add("destroy(platforms)"); - } + add(lines[i]); }else if(words[0] == "speaker"){ speakermode=0; if(words[1]=="gray" || words[1]=="grey" || words[1]=="terminal" || words[1]=="0") speakermode=0;