修复自定义场地16号颜色的方块名位置显示错误

优化皮肤设置页面交互效果
This commit is contained in:
MrZ626
2021-12-06 03:25:39 +08:00
parent 46223e38cd
commit aef4220ac0
2 changed files with 25 additions and 26 deletions

View File

@@ -428,8 +428,8 @@ function scene.draw()
setFont(55)
gc.setColor(1,1,1)
for i=1,7 do
local skin=SETTING.skin[i]
mStr(text.block[i],500+skin%8*80,90+80*int(skin/8))
local skin=SETTING.skin[i]-1
mStr(text.block[i],580+(skin%8)*80,90+80*int(skin/8))
end
end

View File

@@ -78,43 +78,42 @@ local function _nextDir(i)
end
playEgg.hide=not selEggMode
end
SFX.play('rotate')
end
scene.widgetList={
WIDGET.newText{name='title', x=80,y=50,font=70,align='L'},
WIDGET.newSelector{name='skinSet',x=780,y=100,w=320,list=SKIN.getList(),disp=SETval('skinSet'),code=SETsto('skinSet')},
WIDGET.newButton{name='prev1', x=130,y=220,w=80,h=65,fText="",code=function()_prevSkin(1)end},
WIDGET.newButton{name='prev2', x=270,y=220,w=80,h=65,fText="",code=function()_prevSkin(2)end},
WIDGET.newButton{name='prev3', x=410,y=220,w=80,h=65,fText="",code=function()_prevSkin(3)end},
WIDGET.newButton{name='prev4', x=550,y=220,w=80,h=65,fText="",code=function()_prevSkin(4)end},
WIDGET.newButton{name='prev5', x=690,y=220,w=80,h=65,fText="",code=function()_prevSkin(5)end},
WIDGET.newButton{name='prev6', x=830,y=220,w=80,h=65,fText="",code=function()_prevSkin(6)end},
WIDGET.newButton{name='prev7', x=970,y=220,w=80,h=65,fText="",code=function()_prevSkin(7)end},
WIDGET.newButton{name='prev1', x=130,y=220,w=80,h=65,sound='hold',font=40,fText="",code=function()_prevSkin(1)end},
WIDGET.newButton{name='prev2', x=270,y=220,w=80,h=65,sound='hold',font=40,fText="",code=function()_prevSkin(2)end},
WIDGET.newButton{name='prev3', x=410,y=220,w=80,h=65,sound='hold',font=40,fText="",code=function()_prevSkin(3)end},
WIDGET.newButton{name='prev4', x=550,y=220,w=80,h=65,sound='hold',font=40,fText="",code=function()_prevSkin(4)end},
WIDGET.newButton{name='prev5', x=690,y=220,w=80,h=65,sound='hold',font=40,fText="",code=function()_prevSkin(5)end},
WIDGET.newButton{name='prev6', x=830,y=220,w=80,h=65,sound='hold',font=40,fText="",code=function()_prevSkin(6)end},
WIDGET.newButton{name='prev7', x=970,y=220,w=80,h=65,sound='hold',font=40,fText="",code=function()_prevSkin(7)end},
WIDGET.newButton{name='next1', x=130,y=440,w=80,h=65,fText="",code=function()_nextSkin(1)end},
WIDGET.newButton{name='next2', x=270,y=440,w=80,h=65,fText="",code=function()_nextSkin(2)end},
WIDGET.newButton{name='next3', x=410,y=440,w=80,h=65,fText="",code=function()_nextSkin(3)end},
WIDGET.newButton{name='next4', x=550,y=440,w=80,h=65,fText="",code=function()_nextSkin(4)end},
WIDGET.newButton{name='next5', x=690,y=440,w=80,h=65,fText="",code=function()_nextSkin(5)end},
WIDGET.newButton{name='next6', x=830,y=440,w=80,h=65,fText="",code=function()_nextSkin(6)end},
WIDGET.newButton{name='next7', x=970,y=440,w=80,h=65,fText="",code=function()_nextSkin(7)end},
WIDGET.newButton{name='next1', x=130,y=440,w=80,h=65,sound='hold',font=40,fText="",code=function()_nextSkin(1)end},
WIDGET.newButton{name='next2', x=270,y=440,w=80,h=65,sound='hold',font=40,fText="",code=function()_nextSkin(2)end},
WIDGET.newButton{name='next3', x=410,y=440,w=80,h=65,sound='hold',font=40,fText="",code=function()_nextSkin(3)end},
WIDGET.newButton{name='next4', x=550,y=440,w=80,h=65,sound='hold',font=40,fText="",code=function()_nextSkin(4)end},
WIDGET.newButton{name='next5', x=690,y=440,w=80,h=65,sound='hold',font=40,fText="",code=function()_nextSkin(5)end},
WIDGET.newButton{name='next6', x=830,y=440,w=80,h=65,sound='hold',font=40,fText="",code=function()_nextSkin(6)end},
WIDGET.newButton{name='next7', x=970,y=440,w=80,h=65,sound='hold',font=40,fText="",code=function()_nextSkin(7)end},
WIDGET.newButton{name='spin1', x=130,y=540,w=80,h=65,code=function()_nextDir(1)end,font=50,fText=CHAR.icon.retry_spin},
WIDGET.newButton{name='spin2', x=270,y=540,w=80,h=65,code=function()_nextDir(2)end,font=50,fText=CHAR.icon.retry_spin},
WIDGET.newButton{name='spin3', x=410,y=540,w=80,h=65,code=function()_nextDir(3)end,font=50,fText=CHAR.icon.retry_spin},
WIDGET.newButton{name='spin4', x=550,y=540,w=80,h=65,code=function()_nextDir(4)end,font=50,fText=CHAR.icon.retry_spin},
WIDGET.newButton{name='spin5', x=690,y=540,w=80,h=65,code=function()_nextDir(5)end,font=50,fText=CHAR.icon.retry_spin},
WIDGET.newButton{name='spin6', x=825,y=540,w=80,h=65,code=function()_nextDir(6)end,font=50,fText=CHAR.icon.retry_spin},
WIDGET.newButton{name='spin7', x=970,y=540,w=80,h=65,code=function()_nextDir(7)end,font=50,fText=CHAR.icon.retry_spin},
WIDGET.newButton{name='spin1', x=130,y=540,w=80,h=65,sound='rotate',font=40,code=function()_nextDir(1)end,fText=CHAR.icon.retry_spin},
WIDGET.newButton{name='spin2', x=270,y=540,w=80,h=65,sound='rotate',font=40,code=function()_nextDir(2)end,fText=CHAR.icon.retry_spin},
WIDGET.newButton{name='spin3', x=410,y=540,w=80,h=65,sound='rotate',font=40,code=function()_nextDir(3)end,fText=CHAR.icon.retry_spin},
WIDGET.newButton{name='spin4', x=550,y=540,w=80,h=65,sound='rotate',font=40,code=function()_nextDir(4)end,fText=CHAR.icon.retry_spin},
WIDGET.newButton{name='spin5', x=690,y=540,w=80,h=65,sound='rotate',font=40,code=function()_nextDir(5)end,fText=CHAR.icon.retry_spin},
WIDGET.newButton{name='spin6', x=825,y=540,w=80,h=65,sound='rotate',font=40,code=function()_nextDir(6)end,fText=CHAR.icon.retry_spin},
WIDGET.newButton{name='spin7', x=970,y=540,w=80,h=65,sound='rotate',font=40,code=function()_nextDir(7)end,fText=CHAR.icon.retry_spin},
WIDGET.newButton{name='skinR', x=200,y=640,w=220,h=80,color='lV',font=35,
WIDGET.newButton{name='skinR', x=200,y=640,w=220,h=80,color='lV',font=35,sound='back',
code=function()
SETTING.skin={1,7,11,3,14,4,9,1,7,2,6,10,2,13,5,9,15,10,11,3,10,2,16,8,4,10,13,2,8}
SFX.play('rotate')
end},
WIDGET.newButton{name='faceR', x=480,y=640,w=220,h=80,color='lR',font=35,
WIDGET.newButton{name='faceR', x=480,y=640,w=220,h=80,color='lR',font=35,sound='back',
code=function()
for i=1,29 do
SETTING.face[i]=0