From 906ce569c0f7fcf8a543813b21d4ddb466e02136 Mon Sep 17 00:00:00 2001 From: Syping Date: Sat, 16 May 2020 16:16:59 +0200 Subject: [PATCH] fix compileArgs for reworked function --- scripts/luaenginec.lea | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/scripts/luaenginec.lea b/scripts/luaenginec.lea index 166347b..8fafa4a 100644 --- a/scripts/luaenginec.lea +++ b/scripts/luaenginec.lea @@ -116,13 +116,12 @@ end function compileScript() local filePath = showFileDialog(SaveFileDialog, "Select output file...", currentFilter, mainWindow) if (filePath ~= nil) then - local extraArg1 - local extraArg2 + local compileArgs = { getWidgetText(scriptLineEdit) } if (currentSstub ~= nil) then - extraArg1 = "--luaengine" - extraArg2 = sstubDir.."/"..currentSstub + compileArgs[2] = "--luaengine" + compileArgs[3] = sstubDir.."/"..currentSstub end - if (executeProcess(compilerPath, getWidgetText(scriptLineEdit), filePath, extraArg1, extraArg2, false) == false) then + if (executeProcess(compilerPath, compileArgs, false) == false) then showMessageBox(WarningMessageBox, "Error occurred while compile!", "LuaEngine Compiler") end end