From f1ce68b67721357e1d444af6a9547e149503d9d6 Mon Sep 17 00:00:00 2001 From: MrZ626 <1046101471@qq.com> Date: Thu, 10 Sep 2020 23:16:48 +0800 Subject: [PATCH] =?UTF-8?q?win=E4=B8=8B=E6=8F=90=E9=86=92=E7=94=A8?= =?UTF-8?q?=E6=88=B7=E5=88=A0=E6=8E=89=E5=AD=98=E6=A1=A3=E5=86=85CCloader?= =?UTF-8?q?=EF=BC=8C=E5=A3=B0=E6=98=8E=E4=B8=A4=E4=B8=AA=E5=85=A8=E5=B1=80?= =?UTF-8?q?=E5=8F=98=E9=87=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Zframework/init.lua | 1 - main.lua | 2 ++ parts/ai.lua | 5 ++++- parts/scenes.lua | 22 +++++++++++++++++----- 4 files changed, 23 insertions(+), 7 deletions(-) diff --git a/Zframework/init.lua b/Zframework/init.lua index 59a8f14b..a4ddd764 100644 --- a/Zframework/init.lua +++ b/Zframework/init.lua @@ -429,7 +429,6 @@ function love.run() love.resize(gc.getWidth(),gc.getHeight()) SCN.init("load")--Scene Launch - marking=true return function() local _ diff --git a/main.lua b/main.lua index beedc2f1..703dae38 100644 --- a/main.lua +++ b/main.lua @@ -11,6 +11,8 @@ --? function NULL()end DBP=print--use this if need debugging print +marking=true +NOGAME=false --Global Setting & Vars math.randomseed(os.time()*626) diff --git a/parts/ai.lua b/parts/ai.lua index 94d41a63..06e798b7 100644 --- a/parts/ai.lua +++ b/parts/ai.lua @@ -17,6 +17,7 @@ local blockPos={4,4,4,4,4,5,4} local scs={{0,1},{0,1},{0,1},{0,1},{0,1},{.5,.5},{-.5,1.5}} -------------------------------------------------Cold clear do + local fs=love.filesystem if system=="Windows"then local success,message=require("CCloader") if success then @@ -24,9 +25,11 @@ do else LOG.print("Cannot load CC: "..message,"warn",color.red) end + if fs.getInfo("CCloader.dll")then + NOGAME="delCC" + end elseif system=="Android"then local armList={"arm64-v8a","armeabi-v7a"} - local fs=love.filesystem local libFunc,success,message for i=1,#armList do local CCloader_f,size=fs.read("data","libAndroid/"..armList[i].."/libCCloader.so") diff --git a/parts/scenes.lua b/parts/scenes.lua index cc1e5a1c..07ae14de 100644 --- a/parts/scenes.lua +++ b/parts/scenes.lua @@ -726,12 +726,24 @@ do--intro if k==2 then VOC.play("bye") SCN.back() - elseif newVersionLaunch then - SCN.push("main","fade") - SCN.swapTo("history","fade") - LOG.print(text.newVersion,"warn",color.lBlue) + elseif NOGAME=="delCC"then + LOG.print("Please quit the game, then delete CCloader.dll(21KB) in saving folder!",600,color.yellow) + LOG.print("请关闭游戏,然后删除存档文件夹内的 CCloader.dll(21KB) !",600,color.yellow) + TASK.new(function(S) + S[1]=S[1]-1 + if S[1]==0 then + love.system.openURL(love.filesystem.getSaveDirectory()) + return true + end + end,{60}) else - SCN.go("main") + if newVersionLaunch then + SCN.push("main","fade") + SCN.swapTo("history","fade") + LOG.print(text.newVersion,"warn",color.lBlue) + else + SCN.go("main") + end end end function touchDown.intro(id,x,y)