diff --git a/call&sys.lua b/call&sys.lua index f117fbb3..3b128052 100644 --- a/call&sys.lua +++ b/call&sys.lua @@ -38,8 +38,8 @@ local sceneInit={ end, custom=function() optSel=optSel or 1 - curBG="matrix" - BGM("blank") + curBG=customRange.bg[customSel[12]] + BGM(customRange.bgm[customSel[13]]) end, draw=function() curBG="none" @@ -142,10 +142,10 @@ function buttonControl_gamepad(i) end end -mouseDown,mouseMove,mouseUp,wheelmoved={},{},{},{} -touchDown,touchUp,touchMove={},{},{} -keyDown,keyUp={},{} -gamepadDown,gamepadUp={},{} +local mouseDown,mouseMove,mouseUp,wheelmoved={},{},{},{} +local touchDown,touchUp,touchMove={},{},{} +local keyDown,keyUp={},{} +local gamepadDown,gamepadUp={},{} function mouseDown.intro(x,y,k) if k==2 then back() @@ -229,8 +229,18 @@ end function keyDown.custom(key) if key=="left"then customSel[optSel]=(customSel[optSel]-2)%#customRange[customID[optSel]]+1 + if optSel==12 then + curBG=customRange.bg[customSel[12]] + elseif optSel==13 then + BGM(customRange.bgm[customSel[13]]) + end elseif key=="right"then customSel[optSel]=customSel[optSel]%#customRange[customID[optSel]]+1 + if optSel==12 then + curBG=customRange.bg[customSel[optSel]] + elseif optSel==13 then + BGM(customRange.bgm[customSel[optSel]]) + end elseif key=="down"then optSel=optSel%#customID+1 elseif key=="up"then diff --git a/conf.lua b/conf.lua index 80fa7445..555fa824 100644 --- a/conf.lua +++ b/conf.lua @@ -9,7 +9,7 @@ function love.conf(t) t.audio.mixwithsystem=true--Switch on to keep sysBGM local W=t.window - W.title="Techmino V0.7.20" + W.title="Techmino V0.7.21" W.icon="/image/icon.png" W.width,W.height=1280,720 W.minwidth,W.minheight=640,360 diff --git a/dataList.lua b/dataList.lua index f3e4de9f..35e1e724 100644 --- a/dataList.lua +++ b/dataList.lua @@ -83,7 +83,7 @@ loadmode={ c4wtrain=function() createPlayer(1,340,15) local F=P.field - for i=1,22 do + for i=1,24 do F[i]=getNewRow(10) P.visTime[i]=getNewRow(20) for x=4,7 do F[i][x]=0 end @@ -368,7 +368,6 @@ Event={ P.rank=1 P.result="WIN" changeAtk(P) - BGM("8-bit happiness") end for i=1,#P.atkBuffer do P.atkBuffer[i].sent=true @@ -379,11 +378,14 @@ Event={ P.visTime[i][j]=min(P.visTime[i][j],20) end end - if P.id==1 then + if P.human then gamefinished=true newTask(Event_task.finish,P) SFX("win") VOICE("win") + if modeEnv.royaleMode then + BGM("8-bit happiness") + end end showText(P,text.win,"beat",90,nil,.4,curMode.id~="custom") end, @@ -451,11 +453,11 @@ Event={ end P.gameEnv.keepVisible=P.gameEnv.visible~="show" showText(P,text.lose,"appear",90,nil,nil,true) - if P.id==1 then + if P.human then gamefinished=true - if modeEnv.royaleMode then BGM("end")end SFX("fail") VOICE("lose") + if modeEnv.royaleMode then BGM("end")end end if #players.alive==1 then local t=P @@ -530,10 +532,7 @@ Event={ P.gameEnv.wait=death_wait[s] P.gameEnv.fall=death_fall[s] P.gameEnv.das=int(7.3-s*.4) - if s==4 then - P.gameEnv.bone=true - newTask(Event_task.bgmWarp,P,120) - end + if s==4 then P.gameEnv.bone=true end showText(P,text.stage[s],"fly",80,-120) SFX("reach") end @@ -640,7 +639,7 @@ Event_task={ removeRow(P.field) removeRow(P.visTime) end - if P.id==1 then + if #players==1 then pauseGame() end return true @@ -678,17 +677,19 @@ Event_task={ survivor_easy=function(self,P) if not P.control then return end P.counter=P.counter+1 - if P.counter>=max(60,150-2*P.modeData.event)then + if P.counter>=max(60,150-2*P.modeData.event)and P.atkBuffer.sum<4 then ins(P.atkBuffer,{pos=rnd(10),amount=1,countdown=30,cd0=30,time=0,sent=false,lv=1}) - P.counter=0 + P.atkBuffer.sum=P.atkBuffer.sum+1 + P.stat.recv=P.stat.recv+1 if P.modeData.event==45 then showText(P,text.maxspeed,"appear",80,-140)end + P.counter=0 P.modeData.event=P.modeData.event+1 end end, survivor_normal=function(self,P) if not P.control then return end P.counter=P.counter+1 - if P.counter>=max(90,180-2*P.modeData.event)then + if P.counter>=max(90,180-2*P.modeData.event)and P.atkBuffer.sum<8 then local d=P.modeData.event+1 if d%4==0 then ins(P.atkBuffer,{pos=rnd(10),amount=1,countdown=60,cd0=60,time=0,sent=false,lv=1}) elseif d%4==1 then ins(P.atkBuffer,{pos=rnd(10),amount=2,countdown=70,cd0=70,time=0,sent=false,lv=1}) @@ -697,52 +698,52 @@ Event_task={ end P.atkBuffer.sum=P.atkBuffer.sum+d%4+1 P.stat.recv=P.stat.recv+d%4+1 - if P.atkBuffer.sum>20 then garbageRelease()end - P.counter=0 if P.modeData.event==45 then showText(P,text.maxspeed,"appear",80,-140)end - P.modeData.event=P.modeData.event+1 + P.counter=0 + P.modeData.event=d end end, survivor_hard=function(self,P) if not P.control then return end P.counter=P.counter+1 - if P.counter>=max(60,180-2*P.modeData.event)then + if P.counter>=max(60,180-2*P.modeData.event)and P.atkBuffer.sum<15 then if P.modeData.event%3<2 then ins(P.atkBuffer,{pos=rnd(10),amount=1,countdown=0,cd0=0,time=0,sent=false,lv=1}) else ins(P.atkBuffer,{pos=rnd(10),amount=3,countdown=60,cd0=60,time=0,sent=false,lv=2}) end - P.atkBuffer.sum=P.atkBuffer.sum+(P.modeData.event%3<2 and 1 or 3) - if P.atkBuffer.sum>20 then garbageRelease()end - P.counter=0 + local R=(P.modeData.event%3<2 and 1 or 3) + P.atkBuffer.sum=P.atkBuffer.sum+R + P.stat.recv=P.stat.recv+R if P.modeData.event==45 then showText(P,text.maxspeed,"appear",80,-140)end + P.counter=0 P.modeData.event=P.modeData.event+1 end end, survivor_lunatic=function(self,P) if not P.control then return end P.counter=P.counter+1 - if P.counter>=max(60,150-P.modeData.event)then + if P.counter>=max(60,150-P.modeData.event)and P.atkBuffer.sum<20 then local t=max(60,90-P.modeData.event) ins(P.atkBuffer,{pos=rnd(10),amount=4,countdown=t,cd0=t,time=0,sent=false,lv=3}) P.atkBuffer.sum=P.atkBuffer.sum+4 - if P.atkBuffer.sum>15 then garbageRelease()end - P.counter=0 + P.stat.recv=P.stat.recv+4 if P.modeData.event==60 then showText(P,text.maxspeed,"appear",80,-140)end + P.counter=0 P.modeData.event=P.modeData.event+1 end end, survivor_ultimate=function(self,P) if not P.control then return end P.counter=P.counter+1 - if P.counter>=max(300,600-10*P.modeData.event)then + if P.counter>=max(300,600-10*P.modeData.event)and P.atkBuffer.sum<20 then local t=max(300,480-12*P.modeData.event) ins(P.atkBuffer,{pos=rnd(10),amount=4,countdown=t,cd0=t,time=0,sent=false,lv=2}) ins(P.atkBuffer,{pos=rnd(10),amount=4,countdown=t,cd0=t,time=0,sent=false,lv=3}) ins(P.atkBuffer,{pos=rnd(10),amount=6,countdown=1.2*t,cd0=1.2*t,time=0,sent=false,lv=4}) ins(P.atkBuffer,{pos=rnd(10),amount=6,countdown=1.5*t,cd0=1.5*t,time=0,sent=false,lv=5}) P.atkBuffer.sum=P.atkBuffer.sum+20 - if P.atkBuffer.sum>32 then garbageRelease()end + P.stat.recv=P.stat.recv+4 P.counter=0 if P.modeData.event==31 then showText(P,text.maxspeed,"appear",80,-140)end P.modeData.event=P.modeData.event+1 diff --git a/font.ttf b/font.ttf index e0d542f0..fa8fb009 100644 Binary files a/font.ttf and b/font.ttf differ diff --git a/gamefunc.lua b/gamefunc.lua index 8a257628..5a7fdb8b 100644 --- a/gamefunc.lua +++ b/gamefunc.lua @@ -1015,7 +1015,7 @@ end function pressKey(i,p) P=p P.keyPressing[i]=true - if P.id==1 then + if P.human then virtualkeyDown[i]=true virtualkeyPressTime[i]=10 end diff --git a/image/mess/title.png b/image/mess/title.png index 12041aa5..a5a5aba1 100644 Binary files a/image/mess/title.png and b/image/mess/title.png differ diff --git a/image/mess/title_old.png b/image/mess/title_old.png new file mode 100644 index 00000000..12041aa5 Binary files /dev/null and b/image/mess/title_old.png differ diff --git a/language/chi.lua b/language/chi.lua index 44374368..65c3dafa 100644 --- a/language/chi.lua +++ b/language/chi.lua @@ -91,7 +91,7 @@ return{ load={"加载语音ing","加载音乐ing","加载音效ing","加载完成",}, tips={ - "不是动画,真的在加载!", + "不是动画,真的在加载!", "整个游戏都是MrZ完成的!", "大满贯10连击消四全清!", "<方块研究所>有一个Nspire-CX版本!", @@ -103,7 +103,7 @@ return{ "Miya:喵!", "225238922,哔哩哔哩 干杯~", "适度游戏益脑,沉迷游戏伤身,合理安排时间,享受健康生活", - "合群了就会消失,但是消失不代表没有意义", + "合群了就会消失,但是消失不代表没有意义", "学会使用两个旋转键,三个更好", "更小的DAS和ARR拥有更高的操作上限", "注意到\"旋转\"到底对方块做了些什么吗?", @@ -158,10 +158,10 @@ return{ quit="退出", }, mode={ - up="Λ", - down="v", - left="<", - right=">", + up="↑", + down="↓", + left="←", + right="→", start="开始", custom="自定义(C)", back="返回", @@ -175,8 +175,8 @@ return{ custom={ up="↑", down="↓", - left="<", - right=">", + left="←", + right="→", start1="消除开始", start2="拼图开始", draw="画图(D)", diff --git a/language/chi_full.lua b/language/chi_full.lua index 690f2ee9..08fdc8db 100644 --- a/language/chi_full.lua +++ b/language/chi_full.lua @@ -158,10 +158,10 @@ return{ quit="退出", }, mode={ - up="Λ", - down="v", - left="<", - right=">", + up="↑", + down="↓", + left="←", + right="→", start="开始", custom="自定义(C)", back="返回", @@ -175,8 +175,8 @@ return{ custom={ up="↑", down="↓", - left="<", - right=">", + left="←", + right="→", start1="消除开始", start2="拼图开始", draw="画图(D)", diff --git a/language/eng.lua b/language/eng.lua index 86cec50a..f059d195 100644 --- a/language/eng.lua +++ b/language/eng.lua @@ -158,10 +158,10 @@ return{ quit="Quit", }, mode={ - up="Λ", - down="v", - left="<", - right=">", + up="↑", + down="↓", + left="←", + right="→", start="Start", custom="Custom(C)", back="Back", @@ -175,8 +175,8 @@ return{ custom={ up="↑", down="↓", - left="<", - right=">", + left="←", + right="→", start1="Clear Start", start2="Puzzle Start", draw="Draw(D)", diff --git a/list.lua b/list.lua index 70864c45..8d2d96ba 100644 --- a/list.lua +++ b/list.lua @@ -148,7 +148,7 @@ customRange={ target={10,20,40,100,200,500,1000,1e99}, freshLimit={0,8,15,1e99}, opponent={0,60,30,20,15,10,7,5,4,3,2,1}, - bg={"none","game1","game2","game3","strap","rgb","grid","glow","matrix"}, + bg={"none","game1","game2","game3","strap","rgb","glow","matrix"}, bgm={"blank","way","race","newera","push","reason","infinite","secret7th","secret8th","rockblock"}, } @@ -260,16 +260,18 @@ local virtualkeySet={ },--PC key feedback } local customSet={ - {20,20,1,1,7,1,1,1,3,4,1,1,1}, - {18,20,1,1,7,1,1,1,8,3,8,1,1}, - {22,22,1,1,7,3,1,3,8,4,1,1,1}, - {20,20,1,1,7,1,1,3,8,3,1,1,1}, - {23,11,8,11,4,1,2,1,8,3,1,1,1}, + {20,20,1,1,7,1,1,1,3,4,1,3,3}, + {18,20,1,1,7,1,1,1,8,3,8,3,3}, + {22,22,1,1,7,3,1,3,8,4,1,8,7}, + {20,20,1,1,7,1,1,3,8,3,1,7,8}, + {23,11,8,11,4,1,2,1,8,3,1,4,9}, } local function useDefaultSet(n) for i=1,#customSet[n]do customSel[i]=customSet[n][i] end + curBG=customRange.bg[customSel[12]] + BGM(customRange.bgm[customSel[13]]) end Buttons={ load={}, @@ -283,23 +285,23 @@ Buttons={ quit= {x=1180,y=620,w=120,h=120,rgb=color.lightGrey, f=50,code=function()gotoScene("quit")end,up="setting",left="help"}, }, mode={ - up= {x=1000,y=210,w=200,h=140, rgb=color.white, f=64, code=function()keyDown.mode("up")end, hide=function()return modeSel==1 end,}, - down= {x=1000,y=430,w=200,h=140, rgb=color.white, f=80, code=function()keyDown.mode("down")end, hide=function()return modeSel==#modeID end,}, - left= {x=190, y=160,w=100,h=80, rgb=color.white, code=function()keyDown.mode("left")end, hide=function()return levelSel==1 end,}, - right= {x=350, y=160,w=100,h=80, rgb=color.white, code=function()keyDown.mode("right")end,hide=function()return levelSel==#modeLevel[modeID[modeSel]]end,}, + up= {x=1000,y=210,w=200,h=140, rgb=color.white, f=80, code=function()love.keypressed("up")end, hide=function()return modeSel==1 end,}, + down= {x=1000,y=430,w=200,h=140, rgb=color.white, f=80, code=function()love.keypressed("down")end, hide=function()return modeSel==#modeID end,}, + left= {x=190, y=160,w=100,h=80, rgb=color.white, code=function()love.keypressed("left")end, hide=function()return levelSel==1 end,}, + right= {x=350, y=160,w=100,h=80, rgb=color.white, code=function()love.keypressed("right")end,hide=function()return levelSel==#modeLevel[modeID[modeSel]]end,}, start= {x=1000,y=600,w=250,h=100, rgb=color.green, f=50, code=function() loadGame(modeSel,levelSel)end}, custom= {x=275, y=420,w=200,h=90, rgb=color.yellow, code=function()gotoScene("custom")end}, back= {x=640, y=630,w=230,h=90, rgb=color.white, f=45, code=back}, }, music={ - up= {x=1100,y=200,w=120,h=120, rgb=color.white,f=50,code=function()sel=(sel-2)%#musicID+1 end}, + up= {x=1100,y=200,w=120,h=120, rgb=color.white,f=40,code=function()sel=(sel-2)%#musicID+1 end}, play= {x=1100,y=340,w=120,h=120, rgb=color.white,f=40,code=function()BGM(musicID[sel])end}, down= {x=1100,y=480,w=120,h=120, rgb=color.white,f=50,code=function()sel=sel%#musicID+1 end}, back= {x=640, y=630,w=230,h=90, rgb=color.white,f=45,code=back}, }, custom={ - up= {x=1000,y=220, w=100,h=100, rgb=color.white, code=function()optSel=(optSel-2)%#customID+1 end}, + up= {x=1000,y=220, w=100,h=100, rgb=color.white,f=50, code=function()optSel=(optSel-2)%#customID+1 end}, down= {x=1000,y=460, w=100,h=100, rgb=color.white,f=50, code=function()optSel=optSel%#customID+1 end}, left= {x=880, y=340, w=100,h=100, rgb=color.white,f=50, code=function()customSel[optSel]=(customSel[optSel]-2)%#customRange[customID[optSel]]+1 end}, right= {x=1120,y=340, w=100,h=100, rgb=color.white,f=50, code=function()customSel[optSel]=customSel[optSel]%#customRange[customID[optSel]]+1 end}, @@ -379,9 +381,7 @@ Buttons={ VIB(1) end,up="sfx",down="fullscreen",left="swap",right="voc"}, voc= {x=940,y=160, w=160, h=60,rgb=color.white, - hide=function() - return not(kb.isDown("m")or false) - end, + hide=function()return true end, code=function() setting.voc=not setting.voc end,up="sfx",down="fullscreen",left="vib"}, diff --git a/paint.lua b/paint.lua index 63bedbf4..2e793c07 100644 --- a/paint.lua +++ b/paint.lua @@ -320,12 +320,14 @@ function Pnt.intro() end function Pnt.main() gc.setColor(1,1,1) - gc.draw(titleImage,300,30) + gc.draw(titleImage,280,30,nil,1.3) setFont(30) - gc.print("Alpha V0.7.20",290,140) - gc.print(system,800,110) + gc.print("Alpha V0.7.21",290,125) + gc.print(system,845,95) end function Pnt.mode() + gc.setColor(1,1,1) + gc.draw(titleImage,830,30) setFont(40) gc.setColor(modeLevelColor[modeLevel[modeID[modeSel]][levelSel]]or color.white) mStr(modeLevel[modeID[modeSel]][levelSel],270,215) @@ -477,7 +479,13 @@ function Pnt.play() gc.setLineWidth(1) gc.setColor(1,1,1,.2) for x=1,9 do gc.line(30*x,-10,30*x,600)end - for y=0,19 do gc.line(0,30*y,300,30*y)end + for y=0,19 do + y=30*y+P.fieldBeneath + gc.line(0,y,300,y) + end + if P.fieldBeneath>20 then + gc.line(0,P.fieldBeneath-30,300,P.fieldBeneath-30) + end end--Grid lines gc.translate(0,P.fieldBeneath) gc.setScissor(scr.x+P.absFieldX*scr.k,scr.y+P.absFieldY*scr.k,300*P.size*scr.k,610*P.size*scr.k) @@ -538,9 +546,9 @@ function Pnt.play() end --Draw game field gc.setScissor()--In-playField mask - gc.translate(0,-P.fieldBeneath) gc.setColor(1,1,1) gc.draw(PTC.dust[p]) + gc.translate(0,-P.fieldBeneath) gc.setLineWidth(3) gc.rectangle("line",-1,-11,302,612)--Draw boarder @@ -775,7 +783,7 @@ function Pnt.help() for i=1,11 do gc.printf(text.help[i],140,15+43*i,1000,"center") end - gc.draw(titleImage,180,600,.2,.7+.05*sin(Timer()*2),nil,140,100) + gc.draw(titleImage,250,600,.2,1+.05*sin(Timer()*2),nil,212,35) gc.setLineWidth(5) gc.rectangle("line",17,17,260,260) gc.rectangle("line",1077,17,186,186) @@ -794,5 +802,5 @@ function Pnt.stat() gc.print(text.stat[i],400,30*i-5) gc.print(statOpt(i),720,30*i-5) end - gc.draw(titleImage,260,570,.2+.07*sin(Timer()*3),.8,nil,250,60) + gc.draw(titleImage,260,600,.2+.07*sin(Timer()*3),nil,nil,212,35) end \ No newline at end of file diff --git a/toolfunc.lua b/toolfunc.lua index 8c6bcf0f..d51230ef 100644 --- a/toolfunc.lua +++ b/toolfunc.lua @@ -127,9 +127,12 @@ end function BGM(s) if setting.bgm and bgmPlaying~=s then if bgmPlaying then newTask(Event_task.bgmFadeOut,nil,bgmPlaying)end - for i=1,#Task do - if Task[i].code==Event_task.bgmFadeIn then - Task[i].code=Event_task.bgmFadeOut + for i=#Task,1,-1 do + local T=Task[i] + if T.code==Event_task.bgmFadeIn then + T.code=Event_task.bgmFadeOut + elseif T.code==Event_task.bgmFadeOut and T.data==s then + rem(Task,i) end end if s then