网格从开关改为可调透明度

This commit is contained in:
MrZ626
2020-12-09 15:47:48 +08:00
parent 0443d5baf7
commit 4eba28fa96
9 changed files with 28 additions and 27 deletions

View File

@@ -240,6 +240,7 @@ do
type(S.spawn)~="number"or
type(S.ghost)~="number"or
type(S.center)~="number"or
type(S.grid)~="number"or
S.bgm>1 or S.sfx>1 or S.voc>1 or
S.stereo>1 or S.VKSFX>1 or S.VKAlpha>1
then

View File

@@ -242,7 +242,7 @@ SETTING={
--Graphic
block=true,ghost=.3,center=1,
smooth=true,grid=false,
smooth=true,grid=.16,
bagLine=false,
lockFX=2,
dropFX=2,

View File

@@ -255,13 +255,13 @@ return{
game="Jeu→",
block="Dessiner le bloc",
ghost="Pièce fantôme",
center="Centre",
smooth="Chute fluide",
grid="Grille",
bagLine="Ligne du Sac",
ghost="Pièce fantôme",
grid="Grille",
center="Centre",
lockFX="Effets de verrouillage",
dropFX="Effets de chute",
moveFX="Effets de déplacement",

View File

@@ -257,13 +257,13 @@ return{
game="Juego→",
block="Dibujar Bloques",
ghost="Fantasma",
center="Centrar",
smooth="Caída Fluida",
grid="Grilla",
bagLine="Línea de Bag de Pzas.",
ghost="Fantasma",
grid="Grilla",
center="Centrar",
lockFX="FX Vis. de Bloqueo",
dropFX="FX Vis. de Caída",
moveFX="FX Vis. de Movim.",

View File

@@ -161,13 +161,13 @@ return{
game="Game→",
block="==↓==",
ghost="__↓__",
center="+",
smooth="~~↓~~",
grid="#",
bagLine="123|123",
ghost="__↓__",
grid="#",
center="+",
lockFX="↓_~",
dropFX="↓~",
moveFX="←→~",

View File

@@ -277,13 +277,13 @@ return{
game="游戏设置→",
block="方块可见",
ghost="阴影透明度",
center="旋转中心透明度",
smooth="平滑下落",
grid="网格",
bagLine="包分界线",
ghost="阴影透明度",
grid="网格",
center="旋转中心透明度",
lockFX="锁定特效",
dropFX="下落特效",
moveFX="移动特效",

View File

@@ -15,10 +15,10 @@ local frameColorList={
COLOR.lOrange,
}
--local function drawCell(y,x,id)gc.draw(SKIN.curText[id],30*x-30,-30*y)end
local function drawGrid(P)
local function drawGrid(P,alpha)
local FBN,FUP=P.fieldBeneath,P.fieldUp
gc.setLineWidth(1)
gc.setColor(1,1,1,.2)
gc.setColor(1,1,1,alpha)
for x=1,9 do
gc.line(30*x,-10,30*x,600)
end
@@ -323,7 +323,7 @@ function draw.norm(P)
gc.rectangle("fill",0,-10,300,610)
--Draw grid
if ENV.grid then drawGrid(P)end
if ENV.grid then drawGrid(P,ENV.grid)end
--In-field things
gc.push("transform")

View File

@@ -10,7 +10,7 @@ return{
swap=true,
ghost=.3,center=1,
smooth=false,grid=false,
smooth=false,grid=.16,
bagLine=false,
text=true,
score=true,

View File

@@ -13,13 +13,13 @@ scene.widgetList={
WIDGET.newButton{name="sound", x=200, y=80,w=240,h=80,color="lCyan",font=35,code=WIDGET.lnk_swapScene("setting_sound","swipeR")},
WIDGET.newButton{name="game", x=1080, y=80,w=240,h=80,color="lCyan",font=35,code=WIDGET.lnk_swapScene("setting_game","swipeL")},
WIDGET.newSwitch{name="block", x=360, y=180, disp=WIDGET.lnk_SETval("block"), code=WIDGET.lnk_SETrev("block")},
WIDGET.newSlider{name="ghost", x=260, y=250,w=200,unit=.6,disp=WIDGET.lnk_SETval("ghost"),show="percent", code=WIDGET.lnk_SETsto("ghost")},
WIDGET.newSlider{name="center", x=260, y=300,w=200,unit=1, disp=WIDGET.lnk_SETval("center"), code=WIDGET.lnk_SETsto("center")},
WIDGET.newSwitch{name="block", x=340, y=180, disp=WIDGET.lnk_SETval("block"), code=WIDGET.lnk_SETrev("block")},
WIDGET.newSwitch{name="smooth", x=340, y=240, disp=WIDGET.lnk_SETval("smooth"), code=WIDGET.lnk_SETrev("smooth")},
WIDGET.newSwitch{name="bagLine", x=340, y=300, disp=WIDGET.lnk_SETval("bagLine"), code=WIDGET.lnk_SETrev("bagLine")},
WIDGET.newSwitch{name="smooth", x=700, y=180, disp=WIDGET.lnk_SETval("smooth"), code=WIDGET.lnk_SETrev("smooth")},
WIDGET.newSwitch{name="grid", x=700, y=240, disp=WIDGET.lnk_SETval("grid"), code=WIDGET.lnk_SETrev("grid")},
WIDGET.newSwitch{name="bagLine", x=700, y=300, disp=WIDGET.lnk_SETval("bagLine"), code=WIDGET.lnk_SETrev("bagLine")},
WIDGET.newSlider{name="ghost", x=630, y=180,w=200,unit=.6,disp=WIDGET.lnk_SETval("ghost"),show="percent", code=WIDGET.lnk_SETsto("ghost")},
WIDGET.newSlider{name="grid", x=630, y=240,w=200,unit=.4,disp=WIDGET.lnk_SETval("grid"),show="percent", code=WIDGET.lnk_SETsto("grid")},
WIDGET.newSlider{name="center", x=630, y=300,w=200,unit=1, disp=WIDGET.lnk_SETval("center"), code=WIDGET.lnk_SETsto("center")},
WIDGET.newSlider{name="lockFX", x=350, y=365,w=373,unit=5, disp=WIDGET.lnk_SETval("lockFX"), code=WIDGET.lnk_SETsto("lockFX")},
WIDGET.newSlider{name="dropFX", x=350, y=410,w=373,unit=5, disp=WIDGET.lnk_SETval("dropFX"), code=WIDGET.lnk_SETsto("dropFX")},