规范加载外部库代码
This commit is contained in:
@@ -23,6 +23,7 @@ do--LOADLIB
|
|||||||
local success,message=require(libName[system])
|
local success,message=require(libName[system])
|
||||||
if success then
|
if success then
|
||||||
LOG.print(name.." load successfully","warn",color.green)
|
LOG.print(name.." load successfully","warn",color.green)
|
||||||
|
return success
|
||||||
else
|
else
|
||||||
LOG.print("Cannot load "..name..": "..message,"warn",color.red)
|
LOG.print("Cannot load "..name..": "..message,"warn",color.red)
|
||||||
end
|
end
|
||||||
@@ -54,7 +55,7 @@ do--LOADLIB
|
|||||||
return
|
return
|
||||||
end
|
end
|
||||||
LOG.print(name.." load successfully","warn",color.green)
|
LOG.print(name.." load successfully","warn",color.green)
|
||||||
libFunc()
|
return libFunc()
|
||||||
else
|
else
|
||||||
LOG.print("No "..name.." for "..system,"warn",color.red)
|
LOG.print("No "..name.." for "..system,"warn",color.red)
|
||||||
return
|
return
|
||||||
|
|||||||
@@ -16,7 +16,8 @@ local Timer=love.timer.getTime
|
|||||||
local blockPos={4,4,4,4,4,5,4}
|
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}}
|
local scs={{0,1},{0,1},{0,1},{0,1},{0,1},{.5,.5},{-.5,1.5}}
|
||||||
-------------------------------------------------Cold clear
|
-------------------------------------------------Cold clear
|
||||||
if LOADLIB("CC")then
|
cc=LOADLIB("CC")
|
||||||
|
if cc then
|
||||||
local CCblockID={6,5,4,3,2,1,0}
|
local CCblockID={6,5,4,3,2,1,0}
|
||||||
CC={
|
CC={
|
||||||
getConf= cc.get_default_config ,--()options,weights
|
getConf= cc.get_default_config ,--()options,weights
|
||||||
|
|||||||
Reference in New Issue
Block a user