From 0f7f50381179117af3001a2fd43bedb26f7203ec Mon Sep 17 00:00:00 2001 From: Deyan Dobromirov Date: Sat, 12 Oct 2019 18:10:02 +0300 Subject: [PATCH] Fixed: Frame close shortcut `ALT + E` closes all opened frame at once Fixed: Frame close shortcut `ALT + E` closes the last frame on the stack Fixed: workshop_publish.bat not deleting the last extracted log --- lua/autorun/trackassembly_init.lua | 4 +++- lua/weapons/gmod_tool/stools/trackassembly.lua | 4 +++- workshop_publish.bat | 5 +++++ 3 files changed, 11 insertions(+), 2 deletions(-) diff --git a/lua/autorun/trackassembly_init.lua b/lua/autorun/trackassembly_init.lua index d45643aa..bb82f945 100644 --- a/lua/autorun/trackassembly_init.lua +++ b/lua/autorun/trackassembly_init.lua @@ -73,7 +73,7 @@ local gtInitLogs = {"*Init", false, 0} ------ CONFIGURE ASMLIB ------ asmlib.InitBase("track","assembly") -asmlib.SetOpVar("TOOL_VERSION","7.571") +asmlib.SetOpVar("TOOL_VERSION","7.573") asmlib.SetIndexes("V" , "x", "y", "z") asmlib.SetIndexes("A" ,"pitch","yaw","roll") asmlib.SetIndexes("WV",1,2,3) @@ -115,6 +115,8 @@ if(SERVER) then end ------ CONFIGURE INTERNALS ----- +asmlib.IsFlag("new_close_frame", false) +asmlib.IsFlag("old_close_frame", false) asmlib.IsFlag("en_context_menu", false) asmlib.SetOpVar("MODE_DATABASE", asmlib.GetAsmConvar("modedb" , "STR")) asmlib.SetOpVar("TRACE_MARGIN" , asmlib.GetAsmConvar("maxtrmarg", "FLT")) diff --git a/lua/weapons/gmod_tool/stools/trackassembly.lua b/lua/weapons/gmod_tool/stools/trackassembly.lua index 5360cae5..69fe473a 100644 --- a/lua/weapons/gmod_tool/stools/trackassembly.lua +++ b/lua/weapons/gmod_tool/stools/trackassembly.lua @@ -911,7 +911,9 @@ function TOOL:Think() local wormo = self:GetWorkingMode() if(utilIsValidModel(model)) then if(CLIENT) then -- Precache the model or it is invalid otherwise - if(inputIsKeyDown(KEY_LALT) and inputIsKeyDown(KEY_E)) then + local bOld = asmlib.IsFlag("old_close_frame", asmlib.IsFlag("new_close_frame")) + local bNew = asmlib.IsFlag("new_close_frame", inputIsKeyDown(KEY_E)) + if(not bOld and bNew and inputIsKeyDown(KEY_LALT)) then local pnFrame = conElements:Pull() -- Retrieve a panel from the stack if(IsValid(pnFrame)) then pnFrame:Close() end -- Call close on it ! end -- Shortcut for closing the routine pieces. A `close` call, get it :D diff --git a/workshop_publish.bat b/workshop_publish.bat index 00d42cf0..f83adc2c 100644 --- a/workshop_publish.bat +++ b/workshop_publish.bat @@ -94,3 +94,8 @@ rd /S /Q !gmadRevPath!Workshop echo !gmadName! Published ! echo. timeout 500 + +:: Give a chance to copy the logs +del !gmadRevPath!!gmadNameLOG! + +exit 0