Compare commits
1 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
d8cbfa72ac |
BIN
BGM/hide.ogg
Normal file
BIN
BGM/hide.ogg
Normal file
Binary file not shown.
@@ -248,7 +248,7 @@ function love.touchpressed(id,x,y)
|
||||
pressKey(t)
|
||||
end
|
||||
elseif scene=="setting3"then
|
||||
sel=nil
|
||||
x,y=convert(x,y)
|
||||
for K=1,#virtualkey do
|
||||
local b=virtualkey[K]
|
||||
if (x-b[1])^2+(y-b[2])^2<b[3]then
|
||||
@@ -276,10 +276,10 @@ function love.touchreleased(id,x,y)
|
||||
end
|
||||
elseif scene=="setting3"and sel then
|
||||
x,y=convert(x,y)
|
||||
dx,dy=dx*screenK,dy*screenK
|
||||
if sel then
|
||||
local b=virtualkey[sel]
|
||||
b[1],b[2]=int(b[1]/snapLevelValue[snapLevel]+.5)*40,int(b[2]/snapLevelValue[snapLevel]+.5)*snapLevelValue[snapLevel]
|
||||
local k=snapLevelValue[snapLevel]
|
||||
b[1],b[2]=int(b[1]/k+.5)*k,int(b[2]/k+.5)*k
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
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.5"
|
||||
W.title="Techmino V0.65"
|
||||
W.icon="/image/icon.png"
|
||||
W.width,W.height=1280,720
|
||||
W.borderless=X
|
||||
|
||||
21
gamefunc.lua
21
gamefunc.lua
@@ -221,7 +221,7 @@ function pressKey(i,player)
|
||||
|
||||
ins(keyTime,1,frame)rem(keyTime,11)
|
||||
cstat.key=cstat.key+1
|
||||
if not player then stat.key=stat.key+1 end
|
||||
if player.id==1 then stat.key=stat.key+1 end
|
||||
--Key count
|
||||
end
|
||||
-- if playmode=="recording"then ins(rec,{i,frame})end
|
||||
@@ -321,7 +321,7 @@ function drop()
|
||||
|
||||
P.combo=P.combo+1--combo=0 is under
|
||||
if cc==4 then
|
||||
if b2b>480 then
|
||||
if b2b>500 then
|
||||
showText("Tetris B2B2B","fly",70)
|
||||
csend=6
|
||||
exblock=exblock+2
|
||||
@@ -338,7 +338,7 @@ function drop()
|
||||
P.cstat.tetris=P.cstat.tetris+1
|
||||
elseif cc>0 then
|
||||
if dospin then
|
||||
if b2b>480 then
|
||||
if b2b>500 then
|
||||
showText(spinName[cc][bn].." B2B2B","spin",40)
|
||||
csend=b2bATK[cc]+1
|
||||
exblock=exblock+1
|
||||
@@ -382,7 +382,9 @@ function drop()
|
||||
exblock=exblock+2
|
||||
sendTime=sendTime+30
|
||||
SFX("perfectclear")
|
||||
P.b2b=b2b+150
|
||||
if cstat.piece>10 then
|
||||
P.b2b=600
|
||||
end
|
||||
end
|
||||
|
||||
csend=csend+(renATK[combo]or 4)
|
||||
@@ -403,8 +405,8 @@ function drop()
|
||||
csend=int(csend)
|
||||
--Buffs
|
||||
|
||||
stat.atk=stat.atk+csend
|
||||
P.cstat.atk=P.cstat.atk+csend
|
||||
if P.id==1 then stat.atk=stat.atk+csend end
|
||||
--ATK statistics
|
||||
|
||||
while csend>0 and P.atkBuffer[1]do
|
||||
@@ -423,14 +425,19 @@ function drop()
|
||||
end
|
||||
end
|
||||
if csend>0 then
|
||||
showText(csend,"appear",30,50)
|
||||
showText(csend,"zoomout",25,70)
|
||||
if #players.alive>1 then
|
||||
garbageSend(P.id,csend,sendTime)
|
||||
end
|
||||
end
|
||||
elseif cc==0 then
|
||||
if P.b2b>450 then
|
||||
P.b2b=max(b2b-2,450)
|
||||
elseif P.b2b>100 then
|
||||
P.b2b=max(b2b-5,100)
|
||||
end
|
||||
garbageRelease()
|
||||
end--Send attack
|
||||
end
|
||||
if id==1 then
|
||||
stat.piece,stat.row=stat.piece+1,stat.row+cc
|
||||
end
|
||||
|
||||
12
list.lua
12
list.lua
@@ -89,6 +89,7 @@ bgm={
|
||||
"race",
|
||||
"push",
|
||||
"reason",
|
||||
"hide",
|
||||
}
|
||||
|
||||
prevMenu={
|
||||
@@ -108,12 +109,13 @@ prevMenu={
|
||||
main="quit",
|
||||
}
|
||||
|
||||
modeID={"sprint","marathon","zen","solo","death","blind","tetris41","asymsolo","gmroll","p2","p3","p4"}
|
||||
modeName={"Sprint","Marathon","Zen","1v1","Death","Blind","Tetris 41","Asymmetry solo","GM roll","2P","3P","4P"}
|
||||
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"}
|
||||
modeInfo={
|
||||
sprint="Clear 40 Lines",
|
||||
marathon="Clear 200 Lines",
|
||||
zen="Clear 200 Lines without gravity",
|
||||
infinite="Infinite game,infinite happy",
|
||||
solo="Beat AI",
|
||||
death="Survive under terrible speed",
|
||||
blind="Invisible board!",
|
||||
@@ -141,7 +143,7 @@ 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}
|
||||
snapLevelValue={1,10,20,40,80}
|
||||
snapLevelValue={1,10,20,40,60,80}
|
||||
snapLevelName={"Free pos","Snap-10","Snap-20","Snap-40","Snap-60","Snap-80"}
|
||||
|
||||
act={
|
||||
@@ -322,7 +324,7 @@ Buttons={
|
||||
code=function()
|
||||
setting.bgblock=not setting.bgblock
|
||||
if not setting.bgblock then
|
||||
for i=1,116 do
|
||||
for i=1,16 do
|
||||
BGblockList[i].v=3*BGblockList[i].v
|
||||
end
|
||||
end
|
||||
@@ -355,7 +357,7 @@ Buttons={
|
||||
end--Reset virtualkey
|
||||
end},
|
||||
{x=640,y=310,w=170,h=80,t=function()return snapLevelName[snapLevel]end,code=function()
|
||||
snapLevel=snapLevel%5+1
|
||||
snapLevel=snapLevel%6+1
|
||||
end},
|
||||
{x=830,y=310,w=170,h=80,t=function()return percent0to5[setting.virtualkeyAlpha]end,code=function()
|
||||
setting.virtualkeyAlpha=(setting.virtualkeyAlpha+1)%6
|
||||
|
||||
27
main.lua
27
main.lua
@@ -116,6 +116,17 @@ loadmode={
|
||||
curBG="strap"
|
||||
BGM("reason")
|
||||
end,
|
||||
infinite=function()
|
||||
modeEnv={
|
||||
drop=1e99,
|
||||
lock=1e99,
|
||||
wait=1,
|
||||
fall=1,
|
||||
}
|
||||
createPlayer(1,340,15)
|
||||
curBG="glow"
|
||||
BGM("hide")
|
||||
end,
|
||||
gmroll=function()
|
||||
modeEnv={
|
||||
drop=0,
|
||||
@@ -227,7 +238,7 @@ loadmode={
|
||||
p2=function()
|
||||
modeEnv={
|
||||
wait=1,
|
||||
fall=30,
|
||||
fall=1,
|
||||
freshLimit=15,
|
||||
}
|
||||
createPlayer(1,20,15)
|
||||
@@ -239,7 +250,7 @@ loadmode={
|
||||
p3=function()
|
||||
modeEnv={
|
||||
wait=1,
|
||||
fall=30,
|
||||
fall=1,
|
||||
freshLimit=15,
|
||||
}
|
||||
createPlayer(1,20,100,.65)
|
||||
@@ -252,7 +263,7 @@ loadmode={
|
||||
p4=function()
|
||||
modeEnv={
|
||||
wait=1,
|
||||
fall=30,
|
||||
fall=1,
|
||||
freshLimit=15,
|
||||
}
|
||||
createPlayer(1,25,150,.5)
|
||||
@@ -393,6 +404,14 @@ mesDisp={
|
||||
setFont(75)
|
||||
mStr(max(200-P.cstat.row,0),-75,280)
|
||||
end,
|
||||
infinite=function()
|
||||
setFont(50)
|
||||
mStr(cstat.atk,-75,320)
|
||||
mStr(format("%.2f",2.5*cstat.atk/cstat.piece),-75,430)
|
||||
setFont(20)
|
||||
gc.print("Attack",-103,360)
|
||||
gc.print("Efficiency",-114,472)
|
||||
end,
|
||||
gmroll=function()
|
||||
setFont(35)
|
||||
gc.print("Tetris",-120,390)
|
||||
@@ -503,7 +522,7 @@ stat={
|
||||
spin=0,
|
||||
}
|
||||
--User Data&User Setting
|
||||
--------------------------------Warning!_G is __indexed to players[n] when changing any player's data!
|
||||
--------------------------------Wrning!_G __index Ply[n] when chng any playr's elments!
|
||||
require("list")
|
||||
require("texture")
|
||||
require("ai")
|
||||
|
||||
22
paint.lua
22
paint.lua
@@ -81,6 +81,16 @@ FX={
|
||||
gc.setColor(1,1,1,a*(rnd()+.5))
|
||||
mStr(t.text,150,250-t.font*.5+t.dy)
|
||||
end,
|
||||
zoomout=function(t,a)
|
||||
gc.push("transform")
|
||||
setFont(t.font)
|
||||
gc.translate(150,290+t.dy)
|
||||
gc.setColor(1,1,1,a)
|
||||
local k=t.t^.5*.2+1
|
||||
gc.scale(k,k)
|
||||
mStr(t.text,0,-t.font*.5)
|
||||
gc.pop()
|
||||
end
|
||||
}
|
||||
|
||||
function drawButton()
|
||||
@@ -195,7 +205,7 @@ end
|
||||
function Pnt.main()
|
||||
gc.setColor(1,1,1)
|
||||
setFont(30)
|
||||
gc.print("Alpha V0.6",370,150)
|
||||
gc.print("Alpha V0.65",370,150)
|
||||
gc.print(system,530,110)
|
||||
gc.draw(titleImage,30,30)
|
||||
end
|
||||
@@ -386,12 +396,12 @@ function Pnt.play()
|
||||
if h>600 then break end
|
||||
end--Buffer line
|
||||
|
||||
gc.setColor(b2b<100 and color.white or b2b<=480 and color.lightRed or color.lightBlue)
|
||||
gc.rectangle("fill",-15,600,10,-b2b1)
|
||||
gc.setColor(b2b<100 and color.white or b2b<=500 and color.lightRed or color.lightBlue)
|
||||
gc.rectangle("fill",-17,600,10,-b2b1)
|
||||
gc.setColor(color.red)
|
||||
gc.rectangle("fill",-20,600-100,16,5)
|
||||
gc.rectangle("fill",-23,600-100,16,5)
|
||||
gc.setColor(color.blue)
|
||||
gc.rectangle("fill",-20,600-480,16,5)
|
||||
gc.rectangle("fill",-23,600-500,16,5)
|
||||
--B2B bar
|
||||
|
||||
setFont(40)
|
||||
@@ -432,7 +442,7 @@ function Pnt.play()
|
||||
|
||||
gc.setColor(1,1,1)
|
||||
setFont(40)
|
||||
gc.print(format("%0.2f",time),-125,530)--Draw time
|
||||
gc.print(format("%0.2f",time),-130,530)--Draw time
|
||||
if mesDisp[gamemode]then mesDisp[gamemode]()end--Draw other message
|
||||
|
||||
setFont(15)
|
||||
|
||||
@@ -13,7 +13,7 @@ function sysSFX(s,v)
|
||||
end
|
||||
end
|
||||
function SFX(s,v)
|
||||
if setting.sfx then
|
||||
if setting.sfx and not P.ai then
|
||||
local n=1
|
||||
while sfx[s][n]:isPlaying()do
|
||||
n=n+1
|
||||
@@ -23,10 +23,6 @@ function SFX(s,v)
|
||||
break
|
||||
end
|
||||
end
|
||||
if P.id>1 then
|
||||
v=1/(#players.alive-1)
|
||||
-- if v<.02 then return nil end
|
||||
end
|
||||
sfx[s][n]:setVolume(v or 1)
|
||||
sfx[s][n]:play()
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user