From a1e8ca9a1558fe8ff9f82fc64dd448b2a9022ab3 Mon Sep 17 00:00:00 2001 From: HKXluo Date: Sun, 4 May 2025 19:56:05 +0800 Subject: [PATCH] 2 --- Demo/SanjuuniApi-Demo/demo1.lua | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/Demo/SanjuuniApi-Demo/demo1.lua b/Demo/SanjuuniApi-Demo/demo1.lua index 01ab628..d4d66b5 100644 --- a/Demo/SanjuuniApi-Demo/demo1.lua +++ b/Demo/SanjuuniApi-Demo/demo1.lua @@ -47,12 +47,17 @@ print("\nConversion successful! Download URL:") print(download_url) luafile = http.get(download_url) if luafile then - -- 保存Lua文件 / Save Lua file print("\nLua file downloaded successfully.") + + -- 保存Lua文件 / Save Lua file f = fs.open("demo.lua", "w") f.write(luafile.readAll()) f.close() print("\nLua file saved as demo.lua.") + + -- 直接运行Lua文件 / Run Lua file + -- load(luafile.readAll())() + else print("\nFailed to download Lua file.") end