整理代码
This commit is contained in:
@@ -493,7 +493,7 @@ function commands.unlockall(bool)
|
||||
RANKS[name]=M.score and 0 or 6
|
||||
end
|
||||
end
|
||||
FILE.save(RANKS,"conf/unlock")
|
||||
FILE.save(RANKS,'conf/unlock')
|
||||
log{C.lC,"\85\78\76\79\67\75\65\76\76"}
|
||||
SFX.play('clear_2')
|
||||
else
|
||||
|
||||
@@ -50,11 +50,11 @@ function scene.keyDown(key)
|
||||
end
|
||||
if key=="return2"or kb.isDown("lalt","lctrl","lshift")then
|
||||
if initField then
|
||||
FILE.save(CUSTOMENV,"conf/customEnv",'q')
|
||||
FILE.save(CUSTOMENV,'conf/customEnv','q')
|
||||
loadGame('custom_puzzle',true)
|
||||
end
|
||||
else
|
||||
FILE.save(CUSTOMENV,"conf/customEnv",'q')
|
||||
FILE.save(CUSTOMENV,'conf/customEnv','q')
|
||||
loadGame('custom_clear',true)
|
||||
end
|
||||
elseif key=="f"then
|
||||
@@ -102,7 +102,7 @@ function scene.keyDown(key)
|
||||
do return end
|
||||
::THROW_fail::LOG.print(text.dataCorrupted,COLOR.R)
|
||||
elseif key=="escape"then
|
||||
FILE.save(CUSTOMENV,"conf/customEnv",'q')
|
||||
FILE.save(CUSTOMENV,'conf/customEnv','q')
|
||||
SCN.back()
|
||||
else
|
||||
WIDGET.keyPressed(key)
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
local scene={}
|
||||
|
||||
function scene.sceneBack()
|
||||
FILE.save(SETTING,"conf/settings")
|
||||
FILE.save(SETTING,'conf/settings')
|
||||
end
|
||||
|
||||
local function setLang(n)return function()SETTING.lang=n LANG.set(n)end end
|
||||
|
||||
@@ -170,7 +170,7 @@ local loadingThread=coroutine.wrap(function()
|
||||
RANKS[name]=nil
|
||||
end
|
||||
end
|
||||
FILE.save(RANKS,"conf/unlock",'q')
|
||||
FILE.save(RANKS,'conf/unlock','q')
|
||||
end
|
||||
|
||||
DAILYLAUNCH=freshDate'q'
|
||||
|
||||
@@ -28,7 +28,7 @@ scene.widgetList={
|
||||
USER.uid=false
|
||||
USER.username=false
|
||||
USER.authToken=false
|
||||
FILE.save(USER,"conf/user",'q')
|
||||
FILE.save(USER,'conf/user','q')
|
||||
SCN.back()
|
||||
end
|
||||
else
|
||||
|
||||
@@ -122,7 +122,7 @@ function scene.sceneBack()
|
||||
STAT.todayTime=STAT.todayTime+PLAYERS[1].stat.time
|
||||
if not GAME.replaying and(PLAYERS[1].frameRun>400 or GAME.result)and not GAME.result then
|
||||
mergeStat(STAT,PLAYERS[1].stat)
|
||||
FILE.save(STAT,"conf/data")
|
||||
FILE.save(STAT,'conf/data')
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
@@ -39,7 +39,7 @@ scene.widgetList={
|
||||
local D=parseCB()
|
||||
if D then
|
||||
TABLE.update(D,RANKS)
|
||||
FILE.save(RANKS,"conf/unlock")
|
||||
FILE.save(RANKS,'conf/unlock')
|
||||
LOG.print(text.importSuccess,'message')
|
||||
else
|
||||
LOG.print(text.dataCorrupted,'warn')
|
||||
@@ -50,7 +50,7 @@ scene.widgetList={
|
||||
local D=parseCB()
|
||||
if D and D.version==STAT.version then
|
||||
TABLE.update(D,STAT)
|
||||
FILE.save(STAT,"conf/data")
|
||||
FILE.save(STAT,'conf/data')
|
||||
LOG.print(text.importSuccess,'message')
|
||||
else
|
||||
LOG.print(text.dataCorrupted,'warn')
|
||||
@@ -61,7 +61,7 @@ scene.widgetList={
|
||||
local D=parseCB()
|
||||
if D then
|
||||
TABLE.update(D,SETTING)
|
||||
FILE.save(SETTING,"conf/settings")
|
||||
FILE.save(SETTING,'conf/settings')
|
||||
LOG.print(text.importSuccess,'message')
|
||||
else
|
||||
LOG.print(text.dataCorrupted,'warn')
|
||||
@@ -72,7 +72,7 @@ scene.widgetList={
|
||||
local D=parseCB()
|
||||
if D then
|
||||
TABLE.update(D,VK_org)
|
||||
FILE.save(VK_org,"conf/virtualkey")
|
||||
FILE.save(VK_org,'conf/virtualkey')
|
||||
LOG.print(text.importSuccess,'message')
|
||||
else
|
||||
LOG.print(text.dataCorrupted,'warn')
|
||||
|
||||
@@ -6,7 +6,7 @@ function scene.sceneInit()
|
||||
BG.set()
|
||||
end
|
||||
function scene.sceneBack()
|
||||
FILE.save(SETTING,"conf/settings")
|
||||
FILE.save(SETTING,'conf/settings')
|
||||
end
|
||||
|
||||
function scene.draw()
|
||||
|
||||
@@ -23,7 +23,7 @@ function scene.sceneInit()
|
||||
BG.set('none')
|
||||
end
|
||||
function scene.sceneBack()
|
||||
FILE.save(keyMap,"conf/key")
|
||||
FILE.save(keyMap,'conf/key')
|
||||
end
|
||||
|
||||
function scene.keyDown(key)
|
||||
|
||||
@@ -15,7 +15,7 @@ function scene.sceneInit()
|
||||
BG.set()
|
||||
end
|
||||
function scene.sceneBack()
|
||||
FILE.save(SETTING,"conf/settings")
|
||||
FILE.save(SETTING,'conf/settings')
|
||||
end
|
||||
|
||||
function scene.mouseDown(x,y)
|
||||
|
||||
@@ -15,7 +15,7 @@ function scene.sceneInit()
|
||||
selected=false
|
||||
end
|
||||
function scene.sceneBack()
|
||||
FILE.save(VK_org,"conf/virtualkey")
|
||||
FILE.save(VK_org,'conf/virtualkey')
|
||||
end
|
||||
|
||||
local function onVK_org(x,y)
|
||||
|
||||
@@ -4,7 +4,7 @@ function scene.sceneInit()
|
||||
BG.set()
|
||||
end
|
||||
function scene.sceneBack()
|
||||
FILE.save(SETTING,"conf/settings")
|
||||
FILE.save(SETTING,'conf/settings')
|
||||
end
|
||||
|
||||
scene.widgetList={
|
||||
|
||||
Reference in New Issue
Block a user