两个manual文件改为txt格式
说明书和法律信息场景找不到文件不会爆炸了
This commit is contained in:
@@ -1,7 +1,12 @@
|
||||
local scene={}
|
||||
function scene.sceneInit()
|
||||
BG.set('cubes')
|
||||
WIDGET.active.texts:setTexts(STRING.split(love.filesystem.read("legals.md"),'\n'))
|
||||
local fileData=love.filesystem.read("legals.md")
|
||||
if fileData then
|
||||
WIDGET.active.texts:setTexts(STRING.split(fileData,'\n'))
|
||||
else
|
||||
WIDGET.active.texts:setTexts{"[legals.md not found]"}
|
||||
end
|
||||
end
|
||||
|
||||
function scene.wheelMoved(_,y)
|
||||
|
||||
@@ -2,7 +2,13 @@ local scene={}
|
||||
|
||||
function scene.sceneInit()
|
||||
BG.set('cubes')
|
||||
WIDGET.active.texts:setTexts(require("parts.language.manual_"..(SETTING.locale:find'zh'and'zh'or'en')))
|
||||
local fileData=love.filesystem.read('parts/language/manual_'..(SETTING.locale:find'zh'and'zh'or'en')..'.txt')
|
||||
if fileData then
|
||||
WIDGET.active.texts:setTexts(STRING.split(fileData,'\n'))
|
||||
else
|
||||
WIDGET.active.texts:setTexts{"[manual file not found]"}
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
function scene.wheelMoved(_,y)
|
||||
|
||||
Reference in New Issue
Block a user