新增ARS_Z旋转系统 close #141

This commit is contained in:
MrZ626
2021-08-21 02:40:56 +08:00
parent 961cf347da
commit e1d85b0a04
3 changed files with 46 additions and 1 deletions

View File

@@ -661,6 +661,49 @@ do
}
end
local ARS_Z
do
local lrOnly={'+0+0','+1+0','-1+0'}
local upOnly={'+0+0','+0+1','+0+2'}
local lrSet={
[01]=lrOnly,[10]=lrOnly,[03]=lrOnly,[30]=lrOnly,
[12]=lrOnly,[21]=lrOnly,[32]=lrOnly,[23]=lrOnly,
[02]=lrOnly,[20]=lrOnly,[13]=lrOnly,[31]=lrOnly,
}
local upSet={
[01]=upOnly,[10]=upOnly,[03]=upOnly,[30]=upOnly,
[12]=upOnly,[21]=upOnly,[32]=upOnly,[23]=upOnly,
[02]=upOnly,[20]=upOnly,[13]=upOnly,[31]=upOnly,
}
local centerPos=TABLE.copy(defaultCenterPos)
centerPos[1]={[0]={1,1},{1,0},{1,1},{1,0}}--Z
centerPos[2]={[0]={1,1},{1,1},{1,1},{1,1}}--S
centerPos[3]={[0]={1,1},{1,0},{1,1},{1,1}}--L
centerPos[4]={[0]={1,1},{1,0},{1,1},{1,1}}--J
centerPos[5]={[0]={1,1},{1,0},{1,1},{1,1}}--T
centerPos[7]={[0]={0,2},{2,0},{0,2},{2,0}}--I
centerPos[10]={[0]={1,1},{1,0},{1,1},{1,0}}--P
centerPos[11]={[0]={1,1},{1,1},{1,1},{1,1}}--Q
centerPos[15]={[0]={1,1},{1,0},{1,1},{1,1}}--U
centerPos[16]={[0]={1,1},{1,1},{1,1},{1,1}}--V
centerPos[19]={[0]={1.5,1.5},{1.5,0.5},{1.5,1.5},{1.5,0.5}}--J5
centerPos[20]={[0]={1.5,1.5},{1.5,0.5},{1.5,1.5},{1.5,0.5}}--L5
centerPos[21]={[0]={1.5,1.5},{1.5,0.5},{1.5,1.5},{1.5,0.5}}--R
centerPos[22]={[0]={1.5,1.5},{1.5,0.5},{1.5,1.5},{1.5,0.5}}--Y
centerPos[23]={[0]={1.5,1.5},{1.5,0.5},{1.5,1.5},{1.5,0.5}}--N
centerPos[24]={[0]={1.5,1.5},{1.5,0.5},{1.5,1.5},{1.5,0.5}}--H
centerPos[26]={[0]={0,1},{0,0},{0,1},{0,0}}--I3
centerPos[28]={[0]={0,1},{0,0},{0,1},{0,0}}--I2
ARS_Z={
centerDisp=TABLE.new(false,29),
centerPos=centerPos,
kickTable=TABLE.new(lrSet,29),
}
ARS_Z.kickTable[7]=upSet
ARS_Z.kickTable[25]=upSet
end
local ASC
do
local L={'+0+0','+1+0','+0-1','+1-1','+0-2','+1-2','+2+0','+2-1','+2-2','-1+0','-1-1','+0+1','+1+1','+2+1','-1-2','-2+0','+0+2','+1+2','+2+2','-2-1','-2-2'}
@@ -821,6 +864,7 @@ local RSlist={
SRS=SRS,
SRS_plus=SRS_plus,
BiRS=BiRS,
ARS_Z=ARS_Z,
ASC=ASC,
ASC_plus=ASC_plus,
C2=C2,

View File

@@ -104,6 +104,7 @@ local function update_misc(P,dt)
end
--Field shaking
--TODO
if P.gameEnv.shakeFX then
local O=P.fieldOff
O.vx=O.vx*.8-abs(O.x)^1.3*(O.x>0 and .1 or -.1)

View File

@@ -41,7 +41,7 @@ scene.widgetList={
WIDGET.newButton{name="key", x=640, y=220, w=320,h=80, color='lG',font=35,code=goScene'setting_key'},
WIDGET.newButton{name="touch", x=990, y=220, w=320,h=80, color='lB',font=35,code=goScene'setting_touch'},
WIDGET.newSlider{name="reTime", x=330, y=320, w=300,unit=10,disp=SETval("reTime"),code=SETsto("reTime"),show=function(S)return(.5+S.disp()*.25).."s"end},
WIDGET.newSelector{name="RS", x=300, y=420, w=300,color='S',list={'TRS','SRS','SRS_plus','BiRS','ASC','ASC_plus','C2','C2_sym','Classic','Classic_plus','None','None_plus'},disp=SETval("RS"),code=SETsto("RS")},
WIDGET.newSelector{name="RS", x=300, y=420, w=300,color='S',list={'TRS','SRS','SRS_plus','BiRS','ARS_Z','ASC','ASC_plus','C2','C2_sym','Classic','Classic_plus','None','None_plus'},disp=SETval("RS"),code=SETsto("RS")},
WIDGET.newButton{name="layout", x=250, y=540, w=200,h=70,font=35, code=goScene'setting_skin'},
WIDGET.newSwitch{name="autoPause", x=1060, y=320, disp=SETval("autoPause"), code=SETrev("autoPause")},
WIDGET.newSelector{name="menuPos", x=980, y=420, w=300,color='O',list={'left','middle','right'},disp=SETval("menuPos"),code=SETsto("menuPos")},