Skip to content

Commit 3ef4b14

Browse files
committed
框架跟进
1 parent 874626b commit 3ef4b14

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

51 files changed

+278
-277
lines changed

Zenitha

assets/game/init.lua

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -451,6 +451,8 @@ function GAME.checkFinish()
451451
GAME.mode.result()
452452
if GAME.mode.resultPage~=NULL then
453453
TASK.new(task_switchToResult)
454+
else
455+
SCN.back()
454456
end
455457
end
456458
end

assets/scene/about_out.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,7 @@ function scene.draw()
148148
end
149149

150150
scene.widgetList={
151-
{type='button_fill',pos={0,0},x=120,y=60,w=180,h=70,fillColor='B',cornerR=15,sound_trigger='button_back',fontSize=40,text=BackText,code=WIDGET.c_backScn'fadeHeader'},
151+
{type='button_fill',pos={0,0},x=120,y=60,w=180,h=70,fillColor='B',cornerR=15,sound_trigger='button_back',fontSize=40,text=BackText,onPress=WIDGET.c_backScn'fadeHeader'},
152152
{type='text',pos={0,0},x=240,y=60,alignX='left',fontType='bold',fontSize=60,text=LANG'about_title'},
153153
}
154154
return scene

assets/scene/dictionary.lua

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -184,13 +184,13 @@ do -- Widgets
184184
type='button',pos={.5,.5},x=mainX+mainW-50,y=210,w=80,h=80,
185185
sound_trigger=false,lineWidth=4,
186186
fontSize=60,text=CHAR.icon.copy,
187-
code=copyText,
187+
onPress=copyText,
188188
}
189189
linkButton=WIDGET.new{
190190
type='button',pos={.5,.5},x=mainX+mainW-150,y=210,w=80,h=80,
191191
sound_trigger=false,lineWidth=4,
192192
fontSize=60,text=CHAR.icon.earth,
193-
code=openLink,
193+
onPress=openLink,
194194
}
195195
end
196196

@@ -521,10 +521,10 @@ scene.widgetList={
521521
inputBox,
522522
copyButton,
523523
linkButton,
524-
{type='button',pos={.5,.5},x=mainX+mainW+70,y=-310,w=80,h=80,sound_trigger=false,lineWidth=4,fontSize=60,text=CHAR.icon.cross_big,code=close},
524+
{type='button',pos={.5,.5},x=mainX+mainW+70,y=-310,w=80,h=80,sound_trigger=false,lineWidth=4,fontSize=60,text=CHAR.icon.cross_big,onPress=close},
525525
{
526526
type='button',pos={.5,.5},x=mainX+mainW+70,y=320,w=80,h=80,sound_trigger='button_soft',lineWidth=4,fontSize=50,text="",
527-
code=WIDGET.c_goScn('zeta_input_method','none'),
527+
onPress=WIDGET.c_goScn('zeta_input_method','none'),
528528
visibleFunc=function() return SETTINGS._system.locale=='zh' end,
529529
},
530530
}

assets/scene/error.lua

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -103,8 +103,8 @@ function scene.draw()
103103
end
104104

105105
scene.widgetList={
106-
{type='button',pos={.5,1},x=-130,y=-100,w=220,h=100,fontSize=75,text=CHAR.icon.console,code=WIDGET.c_goScn'_console',visibleTick=function() return time>1 end},
107-
{type='button',pos={.5,1},x=130,y=-100,w=220,h=100,fontSize=70,text=CHAR.icon.cross_big,code=WIDGET.c_pressKey'escape',visibleTick=function() return time>1 end},
106+
{type='button',pos={.5,1},x=-130,y=-100,w=220,h=100,fontSize=75,text=CHAR.icon.console,onPress=WIDGET.c_goScn'_console',visibleTick=function() return time>1 end},
107+
{type='button',pos={.5,1},x=130,y=-100,w=220,h=100,fontSize=70,text=CHAR.icon.cross_big,onPress=WIDGET.c_pressKey'escape',visibleTick=function() return time>1 end},
108108
}
109109

110110
return scene

assets/scene/game_in.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,6 @@ function scene.draw()
110110
end
111111

112112
scene.widgetList={
113-
{name='pause',type='button',pos={0,.5},x=210,y=-360,w=200,h=80,lineWidth=4,cornerR=0,sound_trigger='button_back',fontSize=60,text=CHAR.icon.pause,code=function() sysAction('back') end},
113+
{name='pause',type='button',pos={0,.5},x=210,y=-360,w=200,h=80,lineWidth=4,cornerR=0,sound_trigger='button_back',fontSize=60,text=CHAR.icon.pause,onPress=function() sysAction('back') end},
114114
}
115115
return scene

assets/scene/game_out.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -135,6 +135,6 @@ function scene.draw()
135135
end
136136

137137
scene.widgetList={
138-
{name='pause',type='button',pos={0,0},x=120,y=80,w=160,h=80,sound_trigger=false,fontSize=60,text=CHAR.icon.pause,code=function() sysAction('back') end},
138+
{name='pause',type='button',pos={0,0},x=120,y=80,w=160,h=80,sound_trigger=false,fontSize=60,text=CHAR.icon.pause,onPress=function() sysAction('back') end},
139139
}
140140
return scene

assets/scene/keyset_in.lua

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -75,19 +75,19 @@ local function selAct(mode,act)
7575
end
7676

7777
scene.widgetList={
78-
{type='button', x=600,y=80, w=200,h=70,cornerR=0,text=LANG"keyset_brik_moveLeft", fontSize=20,color='lG',code=selAct('brik','moveLeft' )},
79-
{type='button', x=600,y=160,w=200,h=70,cornerR=0,text=LANG"keyset_brik_moveRight", fontSize=20,color='lG',code=selAct('brik','moveRight')},
80-
{type='button', x=600,y=240,w=200,h=70,cornerR=0,text=LANG"keyset_brik_rotateCW", fontSize=20,color='lG',code=selAct('brik','rotateCW' )},
81-
{type='button', x=600,y=320,w=200,h=70,cornerR=0,text=LANG"keyset_brik_rotateCCW", fontSize=20,color='lG',code=selAct('brik','rotateCCW')},
82-
{type='button', x=600,y=400,w=200,h=70,cornerR=0,text=LANG"keyset_brik_rotate180", fontSize=20,color='lG',code=selAct('brik','rotate180')},
83-
{type='button', x=600,y=480,w=200,h=70,cornerR=0,text=LANG"keyset_brik_softDrop", fontSize=20,color='lG',code=selAct('brik','softDrop' )},
84-
{type='button', x=600,y=560,w=200,h=70,cornerR=0,text=LANG"keyset_brik_hardDrop", fontSize=20,color='lG',code=selAct('brik','hardDrop' )},
85-
{type='button', x=600,y=640,w=200,h=70,cornerR=0,text=LANG"keyset_brik_holdPiece", fontSize=20,color='lG',code=selAct('brik','holdPiece')},
86-
{type='button', x=600,y=720,w=200,h=70,cornerR=0,text=LANG"keyset_sys_restart", fontSize=20,color='lG',code=selAct('sys', 'restart' )},
87-
{type='button', x=600,y=800,w=200,h=70,cornerR=0,text=LANG"keyset_sys_back", fontSize=20,color='lG',code=selAct('sys', 'back' )},
88-
{type='button', x=600,y=880,w=200,h=70,cornerR=0,text=LANG"keyset_sys_quit", fontSize=20,color='lG',code=selAct('sys', 'quit' )},
78+
{type='button', x=600,y=80, w=200,h=70,cornerR=0,text=LANG"keyset_brik_moveLeft", fontSize=20,color='lG',onPress=selAct('brik','moveLeft' )},
79+
{type='button', x=600,y=160,w=200,h=70,cornerR=0,text=LANG"keyset_brik_moveRight", fontSize=20,color='lG',onPress=selAct('brik','moveRight')},
80+
{type='button', x=600,y=240,w=200,h=70,cornerR=0,text=LANG"keyset_brik_rotateCW", fontSize=20,color='lG',onPress=selAct('brik','rotateCW' )},
81+
{type='button', x=600,y=320,w=200,h=70,cornerR=0,text=LANG"keyset_brik_rotateCCW", fontSize=20,color='lG',onPress=selAct('brik','rotateCCW')},
82+
{type='button', x=600,y=400,w=200,h=70,cornerR=0,text=LANG"keyset_brik_rotate180", fontSize=20,color='lG',onPress=selAct('brik','rotate180')},
83+
{type='button', x=600,y=480,w=200,h=70,cornerR=0,text=LANG"keyset_brik_softDrop", fontSize=20,color='lG',onPress=selAct('brik','softDrop' )},
84+
{type='button', x=600,y=560,w=200,h=70,cornerR=0,text=LANG"keyset_brik_hardDrop", fontSize=20,color='lG',onPress=selAct('brik','hardDrop' )},
85+
{type='button', x=600,y=640,w=200,h=70,cornerR=0,text=LANG"keyset_brik_holdPiece", fontSize=20,color='lG',onPress=selAct('brik','holdPiece')},
86+
{type='button', x=600,y=720,w=200,h=70,cornerR=0,text=LANG"keyset_sys_restart", fontSize=20,color='lG',onPress=selAct('sys', 'restart' )},
87+
{type='button', x=600,y=800,w=200,h=70,cornerR=0,text=LANG"keyset_sys_back", fontSize=20,color='lG',onPress=selAct('sys', 'back' )},
88+
{type='button', x=600,y=880,w=200,h=70,cornerR=0,text=LANG"keyset_sys_quit", fontSize=20,color='lG',onPress=selAct('sys', 'quit' )},
8989

90-
{type='button',pos={1,1},x=-300,y=-80,w=160,h=80,cornerR=0,text=LANG"setting_test",fontSize=40,code=PlayInterior'brik/interior/test',visibleFunc=function() return not GAME.mode end},
91-
{type='button',pos={1,1},x=-120,y=-80,w=160,h=80,sound_trigger='button_back',cornerR=0,fontSize=60,text=CHAR.icon.back,code=WIDGET.c_backScn('none')},
90+
{type='button',pos={1,1},x=-300,y=-80,w=160,h=80,cornerR=0,text=LANG"setting_test",fontSize=40,onPress=PlayInterior'brik/interior/test',visibleFunc=function() return not GAME.mode end},
91+
{type='button',pos={1,1},x=-120,y=-80,w=160,h=80,sound_trigger='button_back',cornerR=0,fontSize=60,text=CHAR.icon.back,onPress=WIDGET.c_backScn('none')},
9292
}
9393
return scene

0 commit comments

Comments
 (0)