添加触摸/点击特效开关
This commit is contained in:
@@ -124,7 +124,7 @@ function love.mousepressed(x,y,k,touch)
|
|||||||
WIDGET.press(mx,my)
|
WIDGET.press(mx,my)
|
||||||
end
|
end
|
||||||
lastX,lastY=mx,my
|
lastX,lastY=mx,my
|
||||||
SYSFX.newTap(3,mx,my,30)
|
if SETTING.clickFX then SYSFX.newTap(3,mx,my,30)end
|
||||||
end
|
end
|
||||||
function love.mousemoved(x,y,dx,dy,touch)
|
function love.mousemoved(x,y,dx,dy,touch)
|
||||||
if touch then return end
|
if touch then return end
|
||||||
@@ -194,7 +194,7 @@ function love.touchreleased(id,x,y)
|
|||||||
if SCN.touchUp then SCN.touchUp(x,y)end
|
if SCN.touchUp then SCN.touchUp(x,y)end
|
||||||
if(x-lastX)^2+(y-lastY)^2<62 then
|
if(x-lastX)^2+(y-lastY)^2<62 then
|
||||||
if SCN.touchClick then SCN.touchClick(x,y)end
|
if SCN.touchClick then SCN.touchClick(x,y)end
|
||||||
SYSFX.newTap(3,x,y,30)
|
if SETTING.clickFX then SYSFX.newTap(3,x,y,30)end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
@@ -276,6 +276,7 @@ SETTING={--Settings
|
|||||||
fullscreen=true,
|
fullscreen=true,
|
||||||
bg=true,
|
bg=true,
|
||||||
powerInfo=false,
|
powerInfo=false,
|
||||||
|
clickFX=true,
|
||||||
|
|
||||||
--Sound
|
--Sound
|
||||||
sfx=1,
|
sfx=1,
|
||||||
|
|||||||
@@ -310,8 +310,9 @@ return{
|
|||||||
highCam="Screen Scrolling",
|
highCam="Screen Scrolling",
|
||||||
nextPos="Next Preview",
|
nextPos="Next Preview",
|
||||||
fullscreen="Full Screen",
|
fullscreen="Full Screen",
|
||||||
bg="Background",
|
|
||||||
power="Power Info",
|
power="Power Info",
|
||||||
|
clickFX="Click FX",
|
||||||
|
bg="Background",
|
||||||
clean="Fast Draw",
|
clean="Fast Draw",
|
||||||
},
|
},
|
||||||
setting_sound={
|
setting_sound={
|
||||||
|
|||||||
@@ -284,8 +284,9 @@ return{
|
|||||||
highCam="Vue d'oiseau",
|
highCam="Vue d'oiseau",
|
||||||
nextPos="Prévisualisation de position",
|
nextPos="Prévisualisation de position",
|
||||||
fullscreen="Plein écran",
|
fullscreen="Plein écran",
|
||||||
bg="Arrière-plan",
|
|
||||||
power="Infos d'alimentation",
|
power="Infos d'alimentation",
|
||||||
|
-- clickFX="Click FX",
|
||||||
|
bg="Arrière-plan",
|
||||||
-- clean="Fast Draw",
|
-- clean="Fast Draw",
|
||||||
},
|
},
|
||||||
setting_sound={
|
setting_sound={
|
||||||
|
|||||||
@@ -310,8 +310,9 @@ return{
|
|||||||
highCam="Vista Olho-de-pássaro",
|
highCam="Vista Olho-de-pássaro",
|
||||||
nextPos="Próxima Pos.",
|
nextPos="Próxima Pos.",
|
||||||
fullscreen="Tela cheia",
|
fullscreen="Tela cheia",
|
||||||
bg="Fundo",
|
|
||||||
power="Informação bateria",
|
power="Informação bateria",
|
||||||
|
-- clickFX="Click FX",
|
||||||
|
bg="Fundo",
|
||||||
-- clean="Fast Draw",
|
-- clean="Fast Draw",
|
||||||
},
|
},
|
||||||
setting_sound={
|
setting_sound={
|
||||||
|
|||||||
@@ -288,8 +288,9 @@ return{
|
|||||||
highCam="Cám. Vista Aérea",
|
highCam="Cám. Vista Aérea",
|
||||||
nextPos="Ver Spawn de Pza. Sig.",
|
nextPos="Ver Spawn de Pza. Sig.",
|
||||||
fullscreen="Pant. Completa",
|
fullscreen="Pant. Completa",
|
||||||
bg="Fondo",
|
|
||||||
power="Inf. de Batería",
|
power="Inf. de Batería",
|
||||||
|
-- clickFX="Click FX",
|
||||||
|
bg="Fondo",
|
||||||
clean="Fast Draw",
|
clean="Fast Draw",
|
||||||
},
|
},
|
||||||
setting_sound={
|
setting_sound={
|
||||||
|
|||||||
@@ -169,8 +169,9 @@ return{
|
|||||||
highCam="↑__↑",
|
highCam="↑__↑",
|
||||||
nextPos="???←",
|
nextPos="???←",
|
||||||
fullscreen="|←→|",
|
fullscreen="|←→|",
|
||||||
bg="__?__",
|
|
||||||
power="+.",
|
power="+.",
|
||||||
|
clickFX="_.~",
|
||||||
|
bg="__?__",
|
||||||
clean="[]→→O",
|
clean="[]→→O",
|
||||||
},
|
},
|
||||||
setting_sound={
|
setting_sound={
|
||||||
|
|||||||
@@ -310,8 +310,9 @@ return{
|
|||||||
highCam="超屏视野",
|
highCam="超屏视野",
|
||||||
nextPos="生成预览",
|
nextPos="生成预览",
|
||||||
fullscreen="全屏",
|
fullscreen="全屏",
|
||||||
bg="背景",
|
|
||||||
power="电量显示",
|
power="电量显示",
|
||||||
|
clickFX="点按特效",
|
||||||
|
bg="背景",
|
||||||
clean="绘制优化",
|
clean="绘制优化",
|
||||||
},
|
},
|
||||||
setting_sound={
|
setting_sound={
|
||||||
|
|||||||
@@ -37,20 +37,21 @@ scene.widgetList={
|
|||||||
SETTING.frameMul=i<5 and 5*i+20 or 10*i
|
SETTING.frameMul=i<5 and 5*i+20 or 10*i
|
||||||
end},
|
end},
|
||||||
|
|
||||||
WIDGET.newSwitch{name="text", x=1160, y=180,font=35,disp=SETval("text"), code=SETrev("text")},
|
WIDGET.newSwitch{name="text", x=1140, y=160,font=35,disp=SETval("text"), code=SETrev("text")},
|
||||||
WIDGET.newSwitch{name="score", x=1160, y=230,font=35,disp=SETval("score"), code=SETrev("score")},
|
WIDGET.newSwitch{name="score", x=1140, y=210,font=35,disp=SETval("score"), code=SETrev("score")},
|
||||||
WIDGET.newSwitch{name="warn", x=1160, y=280,font=35,disp=SETval("warn"), code=SETrev("warn")},
|
WIDGET.newSwitch{name="warn", x=1140, y=260,font=35,disp=SETval("warn"), code=SETrev("warn")},
|
||||||
WIDGET.newSwitch{name="highCam", x=1160, y=330,font=35,disp=SETval("highCam"),code=SETrev("highCam")},
|
WIDGET.newSwitch{name="highCam", x=1140, y=310,font=35,disp=SETval("highCam"),code=SETrev("highCam")},
|
||||||
WIDGET.newSwitch{name="nextPos", x=1160, y=380,font=35,disp=SETval("nextPos"),code=SETrev("nextPos")},
|
WIDGET.newSwitch{name="nextPos", x=1140, y=360,font=35,disp=SETval("nextPos"),code=SETrev("nextPos")},
|
||||||
WIDGET.newSwitch{name="fullscreen", x=1160, y=430,disp=SETval("fullscreen"), code=switchFullscreen},
|
WIDGET.newSwitch{name="fullscreen", x=1140, y=410,disp=SETval("fullscreen"), code=switchFullscreen},
|
||||||
WIDGET.newSwitch{name="bg", x=1160, y=480,font=35,disp=SETval("bg"),
|
WIDGET.newSwitch{name="power", x=1140, y=460,font=35,disp=SETval("powerInfo"),code=SETrev("powerInfo")},
|
||||||
|
WIDGET.newSwitch{name="clickFX", x=1140, y=510,font=35,disp=SETval("clickFX"),code=SETrev("clickFX")},
|
||||||
|
WIDGET.newSwitch{name="bg", x=1140, y=560,font=35,disp=SETval("bg"),
|
||||||
code=function()
|
code=function()
|
||||||
BG.set("none")
|
BG.set("none")
|
||||||
SETTING.bg=not SETTING.bg
|
SETTING.bg=not SETTING.bg
|
||||||
BG.set()
|
BG.set()
|
||||||
end},
|
end},
|
||||||
WIDGET.newSwitch{name="power", x=990, y=610,font=35,disp=SETval("powerInfo"),code=SETrev("powerInfo")},
|
WIDGET.newSwitch{name="clean", x=990, y=640,font=35,disp=SETval("cleanCanvas"),code=SETrev("cleanCanvas")},
|
||||||
WIDGET.newSwitch{name="clean", x=990, y=670,font=35,disp=SETval("cleanCanvas"),code=SETrev("cleanCanvas")},
|
|
||||||
WIDGET.newButton{name="back", x=1140, y=640,w=170,h=80,font=40,code=backScene},
|
WIDGET.newButton{name="back", x=1140, y=640,w=170,h=80,font=40,code=backScene},
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user