整理代码,移除多余的保存成功提示

This commit is contained in:
MrZ626
2021-06-19 20:46:23 +08:00
parent d0b9cdc503
commit e381f66767
3 changed files with 3 additions and 10 deletions

View File

@@ -275,9 +275,7 @@ function gameOver()--Save record
end
end
if needSave then
if FILE.save(RANKS,'conf/unlock')then
MES.new('check',text.saveDone)
end
FILE.save(RANKS,'conf/unlock')
end
end
local D=M.score(P)

View File

@@ -289,7 +289,6 @@ function NET.loadSavedData(sections)
if success then
MES.new('check',text.saveDone)
end
MES.new('check',text.saveDone)
else
MES.new('error',text.versionNotMatch,1)
end

View File

@@ -12,13 +12,9 @@ local function login()
end
NET.wsconn_user_pswd(email,password)
if savePW then
if FILE.save({email,password},'conf/account')then
MES.new('check',text.saveDone)
end
FILE.save({email,password},'conf/account')
else
if love.filesystem.getInfo('conf/account')then
love.filesystem.remove('conf/account')
end
love.filesystem.remove('conf/account')
end
end