Compare commits
1 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
bdee7fba03 |
BIN
BGM/hide.ogg
BIN
BGM/hide.ogg
Binary file not shown.
BIN
BGM/infinite.ogg
Normal file
BIN
BGM/infinite.ogg
Normal file
Binary file not shown.
BIN
SFX/fail.ogg
Normal file
BIN
SFX/fail.ogg
Normal file
Binary file not shown.
BIN
SFX/win.ogg
Normal file
BIN
SFX/win.ogg
Normal file
Binary file not shown.
@@ -245,7 +245,7 @@ function love.touchpressed(id,x,y)
|
||||
if scene=="play"and setting.virtualkeySwitch then
|
||||
local t=onVirtualkey(x,y)
|
||||
if t then
|
||||
pressKey(t)
|
||||
pressKey(t,players[1])
|
||||
end
|
||||
elseif scene=="setting3"then
|
||||
x,y=convert(x,y)
|
||||
|
||||
2
conf.lua
2
conf.lua
@@ -9,7 +9,7 @@ function love.conf(t)
|
||||
t.audio.mixwithsystem=true--Switch on to keep background music playing
|
||||
|
||||
local W=t.window
|
||||
W.title="Techmino V0.65"
|
||||
W.title="Techmino V0.68"
|
||||
W.icon="/image/icon.png"
|
||||
W.width,W.height=1280,720
|
||||
W.borderless=X
|
||||
|
||||
21
gamefunc.lua
21
gamefunc.lua
@@ -132,17 +132,17 @@ function throwBadge(s,r,amount)--Player id
|
||||
ins(FX.badge,{x1,y1,x2,y2,t=0,size=(10+min(amount,10))*.1})
|
||||
end
|
||||
function freshgho()
|
||||
if not P.gameEnv._20G then
|
||||
P.y_img=P.cy>#field+1 and #field+1 or P.cy
|
||||
while not ifoverlap(cb,cx,y_img-1)do
|
||||
P.y_img=P.y_img-1
|
||||
end
|
||||
else
|
||||
if P.gameEnv._20G or keyPressing[7]and gameEnv.sdarr==0 then
|
||||
while not ifoverlap(cb,cx,cy-1)do
|
||||
P.cy=P.cy-1
|
||||
P.spinLast=false
|
||||
end
|
||||
P.y_img=P.cy
|
||||
else
|
||||
P.y_img=P.cy>#field+1 and #field+1 or P.cy
|
||||
while not ifoverlap(cb,cx,y_img-1)do
|
||||
P.y_img=P.y_img-1
|
||||
end
|
||||
end
|
||||
end
|
||||
function freshLockDelay()
|
||||
@@ -324,17 +324,18 @@ function drop()
|
||||
if b2b>500 then
|
||||
showText("Tetris B2B2B","fly",70)
|
||||
csend=6
|
||||
exblock=exblock+2
|
||||
sendTime=80
|
||||
exblock=exblock+1
|
||||
elseif b2b>=100 then
|
||||
showText("Tetris B2B","drive",70)
|
||||
sendTime=70
|
||||
csend=5
|
||||
exblock=exblock+1
|
||||
else
|
||||
showText("Tetris","stretch",80)
|
||||
sendTime=60
|
||||
csend=4
|
||||
end
|
||||
P.b2b=P.b2b+100
|
||||
sendTime=60
|
||||
P.cstat.tetris=P.cstat.tetris+1
|
||||
elseif cc>0 then
|
||||
if dospin then
|
||||
@@ -372,7 +373,7 @@ function drop()
|
||||
if dospin then
|
||||
showText(spinName[0][bn],"appear",50)
|
||||
SFX("spin_0")
|
||||
P.b2b=b2b+40
|
||||
P.b2b=b2b+30
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
43
list.lua
43
list.lua
@@ -73,7 +73,7 @@ end
|
||||
|
||||
sfx={
|
||||
"button",
|
||||
"ready","start",
|
||||
"ready","start","win","fail",
|
||||
"move","rotate","rotatekick","hold",
|
||||
"prerotate","prehold",
|
||||
"drop","fall",
|
||||
@@ -89,7 +89,7 @@ bgm={
|
||||
"race",
|
||||
"push",
|
||||
"reason",
|
||||
"hide",
|
||||
"infinite",
|
||||
}
|
||||
|
||||
prevMenu={
|
||||
@@ -109,16 +109,17 @@ prevMenu={
|
||||
main="quit",
|
||||
}
|
||||
|
||||
modeID={"sprint","marathon","zen","infinite","solo","death","blind","tetris41","asymsolo","gmroll","p2","p3","p4"}
|
||||
modeName={"Sprint","Marathon","Zen","Infinite","1v1","Death","Blind","Tetris 41","Asymmetry solo","GM roll","2P","3P","4P"}
|
||||
modeID={"sprint","marathon","zen","infinite","solo","death","blind","puzzle","tetris41","asymsolo","gmroll","p2","p3","p4"}
|
||||
modeName={"Sprint","Marathon","Zen","Infinite","1v1","Death","Blind","Puzzle","Tetris 41","Asymmetry solo","GM roll","2P","3P","4P"}
|
||||
modeInfo={
|
||||
sprint="Clear 40 Lines",
|
||||
marathon="Clear 200 Lines",
|
||||
zen="Clear 200 Lines without gravity",
|
||||
infinite="Infinite game,infinite happy",
|
||||
infinite="Infinite game,infinite happiness",
|
||||
solo="Beat AI",
|
||||
death="Survive under terrible speed",
|
||||
blind="Invisible board!",
|
||||
puzzle="Your keyboard broke",
|
||||
tetris41="Melee fight with 40 AIs",
|
||||
asymsolo=" See-->",
|
||||
gmroll="Who want to be the grand master?",
|
||||
@@ -140,9 +141,9 @@ ren_n={"ren_1","ren_2","ren_3","ren_4","ren_5","ren_6","ren_7","ren_8","ren_9","
|
||||
percent0to5={[0]="0%","20%","40%","60%","80%","100%",}
|
||||
|
||||
marathon_drop={[0]=60,48,40,30,24,18,15,12,10,8,7,6,5,4,3,2,1,1,0,0}
|
||||
death_lock={10,9,8,7,6}
|
||||
death_wait={6,5,4,3,2}
|
||||
death_fall={10,8,7,6,5}
|
||||
death_lock={10,9,9,8,8}
|
||||
death_wait={6,6,5,5,4}
|
||||
death_fall={10,9,8,7,6}
|
||||
snapLevelValue={1,10,20,40,60,80}
|
||||
snapLevelName={"Free pos","Snap-10","Snap-20","Snap-40","Snap-60","Snap-80"}
|
||||
|
||||
@@ -192,8 +193,18 @@ act={
|
||||
count=60+26--Althour'z neim
|
||||
end,
|
||||
insDown=function()if cy~= y_img then P.cy,P.lockDelay,P.spinLast=y_img,gameEnv.lock,false end end,
|
||||
insLeft=function()while not ifoverlap(cb,cx-1,cy)do P.cx,P.lockDelay=cx-1,gameEnv.lock;freshgho()end end,
|
||||
insRight=function()while not ifoverlap(cb,cx+1,cy)do P.cx,P.lockDelay=cx+1,gameEnv.lock;freshgho()end end,
|
||||
insLeft=function()
|
||||
while not ifoverlap(cb,cx-1,cy)do
|
||||
P.cx,P.lockDelay=cx-1,gameEnv.lock
|
||||
freshgho()
|
||||
end
|
||||
end,
|
||||
insRight=function()
|
||||
while not ifoverlap(cb,cx+1,cy)do
|
||||
P.cx,P.lockDelay=cx+1,gameEnv.lock
|
||||
freshgho()
|
||||
end
|
||||
end,
|
||||
down1=function()if cy~=y_img then P.cy=cy-1 end end,
|
||||
down4=function()for i=1,4 do if cy~=y_img then P.cy=cy-1 else break end end end,
|
||||
quit=function()Event.gameover.lose()end,
|
||||
@@ -229,8 +240,8 @@ TRS={
|
||||
[03]={{0,0},{1,0},{1,1},{0,-2},{1,-2}},
|
||||
[02]={{0,0},{1,0},{-1,0},{0,-1},{0,1}},
|
||||
[20]={{0,0},{-1,0},{1,0},{0,1},{0,-1}},
|
||||
[13]={{0,0},{0,1},{0,-1},{-1,0},{1,0},{0,2}},
|
||||
[31]={{0,0},{0,-1},{0,1},{1,0},{-1,0},{0,2}},
|
||||
[13]={{0,0},{0,-1},{0,1},{-1,0},{1,0},{0,2}},
|
||||
[31]={{0,0},{0,1},{0,-1},{1,0},{-1,0},{0,2}},
|
||||
},
|
||||
[2]={
|
||||
[01]={{0,0},{-1,0},{-1,1},{0,-2},{-1,-2}},
|
||||
@@ -243,8 +254,8 @@ TRS={
|
||||
[03]={{0,0},{1,0},{1,1},{0,-2},{1,-2},{0,1}},
|
||||
[02]={{0,0},{-1,0},{1,0},{0,-1},{0,1}},
|
||||
[20]={{0,0},{1,0},{-1,0},{0,1},{0,-1}},
|
||||
[13]={{0,0},{0,-1},{0,1},{1,0},{-1,0},{0,2}},
|
||||
[31]={{0,0},{0,1},{0,-1},{-1,0},{1,0},{0,2}},
|
||||
[13]={{0,0},{0,1},{0,-1},{1,0},{-1,0},{0,2}},
|
||||
[31]={{0,0},{0,-1},{0,1},{-1,0},{1,0},{0,2}},
|
||||
},
|
||||
[5]={
|
||||
[01]={{0,0},{-1,0},{-1,1},{0,-2},{-1,-2}},
|
||||
@@ -264,8 +275,8 @@ TRS={
|
||||
[01]={{0,0},{1,0},{-2,0},{-2,-1},{1,2}},
|
||||
[10]={{0,0},{2,0},{-1,0},{2,1},{-1,-2}},
|
||||
[12]={{0,0},{-1,0},{2,0},{-1,2},{2,-1}},
|
||||
[21]={{0,0},{-2,0},{1,0},{-2,1},{1,-2}},
|
||||
[23]={{0,0},{2,0},{-1,0},{2,1},{-1,-2}},
|
||||
[21]={{0,0},{-2,0},{1,0},{1,-2},{-2,1}},
|
||||
[23]={{0,0},{2,0},{-1,0},{-1,-2},{2,1}},
|
||||
[32]={{0,0},{-2,0},{1,0},{-2,-1},{1,2}},
|
||||
[30]={{0,0},{1,0},{-2,0},{1,-2},{-2,1}},
|
||||
[03]={{0,0},{-1,0},{2,0},{2,-1},{-1,2}},
|
||||
|
||||
30
main.lua
30
main.lua
@@ -114,7 +114,7 @@ loadmode={
|
||||
}
|
||||
createPlayer(1,340,15)
|
||||
curBG="strap"
|
||||
BGM("reason")
|
||||
BGM("infinite")
|
||||
end,
|
||||
infinite=function()
|
||||
modeEnv={
|
||||
@@ -125,7 +125,7 @@ loadmode={
|
||||
}
|
||||
createPlayer(1,340,15)
|
||||
curBG="glow"
|
||||
BGM("hide")
|
||||
BGM("infinite")
|
||||
end,
|
||||
gmroll=function()
|
||||
modeEnv={
|
||||
@@ -171,10 +171,28 @@ loadmode={
|
||||
curBG="game2"
|
||||
BGM("push")
|
||||
end,
|
||||
puzzle=function()
|
||||
modeEnv={
|
||||
hold=false,
|
||||
das=0,
|
||||
arr=0,
|
||||
_20G=true,
|
||||
drop=0,
|
||||
lock=1e99,
|
||||
wait=1,
|
||||
fall=10,
|
||||
target=40,
|
||||
reach=Event.gameover.win,
|
||||
}
|
||||
createPlayer(1,340,15)
|
||||
curBG="glow"
|
||||
BGM("way")
|
||||
end,
|
||||
tetris41=function()
|
||||
modeEnv={
|
||||
wait=1,
|
||||
fall=1,
|
||||
freshLimit=15,
|
||||
}
|
||||
royaleMode=true
|
||||
createPlayer(1,340,15)--Player
|
||||
@@ -290,6 +308,7 @@ Event={
|
||||
end
|
||||
end
|
||||
showText("WIN","appear",100,nil,true)
|
||||
if P.id==1 and players[2]and players[2].ai then SFX("win")end
|
||||
ins(task,Event.task.win)
|
||||
end,
|
||||
lose=function()
|
||||
@@ -323,6 +342,7 @@ Event={
|
||||
visTime[i][j]=min(visTime[i][j],20)
|
||||
end
|
||||
end
|
||||
if P.id==1 and players[2]and players[2].ai then SFX("fail")end
|
||||
ins(task,Event.task.lose)
|
||||
end,
|
||||
},
|
||||
@@ -430,6 +450,10 @@ mesDisp={
|
||||
mStr(gameEnv.target,-75,380)
|
||||
gc.line(-120,377,-30,377)
|
||||
end,
|
||||
puzzle=function()
|
||||
setFont(75)
|
||||
mStr(max(40-P.cstat.row,0),-75,280)
|
||||
end,
|
||||
tetris41=function()
|
||||
gc.draw(badgeIcon,-120,150,nil,1.5)
|
||||
setFont(50)
|
||||
@@ -531,7 +555,7 @@ require("sysfunc")
|
||||
require("gamefunc")
|
||||
require("timer")
|
||||
require("paint")
|
||||
require("game_scene")
|
||||
require("scene")
|
||||
require("call&sys")
|
||||
|
||||
userData=fs.newFile("userdata")
|
||||
|
||||
38
paint.lua
38
paint.lua
@@ -205,7 +205,7 @@ end
|
||||
function Pnt.main()
|
||||
gc.setColor(1,1,1)
|
||||
setFont(30)
|
||||
gc.print("Alpha V0.65",370,150)
|
||||
gc.print("Alpha V0.68",370,150)
|
||||
gc.print(system,530,110)
|
||||
gc.draw(titleImage,30,30)
|
||||
end
|
||||
@@ -253,28 +253,8 @@ function Pnt.play()
|
||||
drawPixel(j,i,field[j][i],min(visTime[j][i],20)*.05)
|
||||
end
|
||||
end
|
||||
else
|
||||
gc.setColor(1,1,1,falling/gameEnv.fall)
|
||||
gc.rectangle("fill",0,600-30*j,320,30)
|
||||
end
|
||||
end--Field
|
||||
if not P.result then
|
||||
if gameEnv.ghost then
|
||||
for i=1,r do for j=1,c do
|
||||
if cb[i][j]>0 then
|
||||
drawPixel(i+y_img-1,j+cx-1,bn,.3)
|
||||
end
|
||||
end end
|
||||
end--Ghost
|
||||
if waiting<=0 then
|
||||
gc.setColor(1,1,1)
|
||||
for i=1,r do for j=1,c do
|
||||
if cb[i][j]>0 then
|
||||
drawPixel(i+cy-1,j+cx-1,bn,1)
|
||||
end
|
||||
end end--Block
|
||||
end
|
||||
end
|
||||
gc.setColor(1,1,1)
|
||||
gc.draw(PTC.dust[p])--Draw game field
|
||||
gc.setStencilTest()--In-playField mask
|
||||
@@ -293,13 +273,13 @@ function Pnt.play()
|
||||
if not a.sent then
|
||||
if a.countdown>0 then
|
||||
gc.setColor(attackColor[a.lv][1])
|
||||
gc.rectangle("fill",305,600-h,8,-bar+5)
|
||||
gc.rectangle("fill",315,600-h,8,-bar+5)
|
||||
gc.setColor(attackColor[a.lv][2])
|
||||
gc.rectangle("fill",305,600-h+(-bar+5),8,-(-bar+5)*(1-a.countdown/a.cd0))
|
||||
gc.rectangle("fill",315,600-h+(-bar+5),8,-(-bar+5)*(1-a.countdown/a.cd0))
|
||||
--Timing
|
||||
else
|
||||
attackColor.animate[a.lv]((sin((Timer()-i)*20)+1)*.5)
|
||||
gc.rectangle("fill",305,600-h,8,-bar+5)
|
||||
gc.rectangle("fill",315,600-h,8,-bar+5)
|
||||
--Warning
|
||||
end
|
||||
end
|
||||
@@ -377,19 +357,19 @@ function Pnt.play()
|
||||
end
|
||||
if a.countdown>0 then
|
||||
gc.setColor(attackColor[a.lv][1])
|
||||
gc.rectangle("fill",305,600-h,8,-bar+5)
|
||||
gc.rectangle("fill",308,600-h,8,-bar+5)
|
||||
gc.setColor(attackColor[a.lv][2])
|
||||
gc.rectangle("fill",305,600-h+(-bar+5),8,-(-bar+5)*(1-a.countdown/a.cd0))
|
||||
gc.rectangle("fill",308,600-h+(-bar+5),8,-(-bar+5)*(1-a.countdown/a.cd0))
|
||||
--Timing
|
||||
else
|
||||
attackColor.animate[a.lv]((sin((Timer()-i)*20)+1)*.5)
|
||||
gc.rectangle("fill",305,600-h,8,-bar+5)
|
||||
gc.rectangle("fill",308,600-h,8,-bar+5)
|
||||
--Warning
|
||||
end
|
||||
else
|
||||
gc.setColor(attackColor[a.lv][1])
|
||||
bar=bar*(20-a.time)*.05
|
||||
gc.rectangle("fill",305,600-h,8,-bar+5)
|
||||
gc.rectangle("fill",308,600-h,8,-bar+5)
|
||||
--Disappear
|
||||
end
|
||||
h=h+bar
|
||||
@@ -442,7 +422,7 @@ function Pnt.play()
|
||||
|
||||
gc.setColor(1,1,1)
|
||||
setFont(40)
|
||||
gc.print(format("%0.2f",time),-130,530)--Draw time
|
||||
gc.print(format("%.2f",time),-130,530)--Draw time
|
||||
if mesDisp[gamemode]then mesDisp[gamemode]()end--Draw other message
|
||||
|
||||
setFont(15)
|
||||
|
||||
10
timer.lua
10
timer.lua
@@ -106,7 +106,7 @@ function Tmr.play(dt)
|
||||
v=0 for i=2,10 do v=v+i*(i-1)*7.2/(frame-dropTime[i])end P.dropSpeed=dropSpeed*.99+v*.1
|
||||
--Update speeds
|
||||
|
||||
if P.ai then
|
||||
if P.ai and waiting<=0 then
|
||||
P.ai.controlDelay=P.ai.controlDelay-1
|
||||
if P.ai.controlDelay==0 then
|
||||
if #P.ai.controls>0 then
|
||||
@@ -189,8 +189,12 @@ function Tmr.play(dt)
|
||||
end
|
||||
end
|
||||
P.b2b1=P.b2b1*.93+P.b2b*.07
|
||||
if P.b2b>500 then P.b2b=P.b2b-.1 end
|
||||
--ALive
|
||||
if P.b2b>500 then
|
||||
P.b2b=P.b2b-.2
|
||||
elseif P.b2b>100 then
|
||||
P.b2b=P.b2b-.15
|
||||
end
|
||||
--Alive
|
||||
else
|
||||
P.keySpeed=keySpeed*.96+cstat.key/time*60*.04
|
||||
P.dropSpeed=dropSpeed*.96+cstat.piece/time*60*.04
|
||||
|
||||
Reference in New Issue
Block a user