Compare commits

...

44 Commits

Author SHA1 Message Date
MrZ_26
f2cf2ce29b 纠正部分rank文件转换错误,转换老版本lastPlay 2020-08-09 22:02:14 +08:00
MrZ_26
397cdd3e75 文字小改 2020-08-09 18:32:45 +08:00
MrZ_26
5b7dd0cfdd 修改T,F,U,T5的踢墙表 2020-08-09 18:32:38 +08:00
MrZ_26
15b413040d 修复游戏结束后马上暂停并解除还会自动暂停 2020-08-09 14:40:01 +08:00
MrZ_26
e746cf7bb1 死亡预警在两个方向的宽度调整 2020-08-09 14:32:30 +08:00
MrZ_26
e4258dad42 方块生成音设置滑条改为连续 2020-08-09 02:33:34 +08:00
MrZ_26
156a1f92be 自定义序列的问号位置摆正,添加序列/场地重置音效 2020-08-09 02:25:02 +08:00
MrZ_26
77af980255 打错字 2020-08-09 02:21:25 +08:00
MrZ_26
d4cd90cfea 模式文件中改用玩家的随机而非系统随机,便于正确回放 2020-08-09 02:02:43 +08:00
MrZ_26
10c3157ad1 库名改为全大写 2020-08-09 01:31:54 +08:00
MrZ_26
0c3a91fc7c 修复刷新锁延时不刷新落延 2020-08-09 01:31:02 +08:00
MrZ_26
a3ecfeb59a 修复画图切换到custom可返回bug,二者之间切换样式更换 2020-08-09 01:30:53 +08:00
MrZ_26
243fa72f98 文字微调,退出游戏场景时保存数据文件 2020-08-09 01:30:45 +08:00
MrZ_26
67835a722b 0.10.2:锁延修复 2020-08-09 00:31:14 +08:00
MrZ_26
e07287223c 触屏特效修复 2020-08-09 00:08:23 +08:00
MrZ_26
94214abc01 锁延机制再修改(应该不能偷鸡了) 2020-08-09 00:03:34 +08:00
MrZ_26
38d8d73d82 进出debug模式问题 2020-08-08 23:57:28 +08:00
MrZ_26
fd6dfda9c4 更新字体 2020-08-08 23:57:21 +08:00
MrZ_26
7f3edeaacf 将失败换为游戏结束 2020-08-08 23:55:56 +08:00
MrZ_26
8de924cd82 0.10.1:漏洞修复 2020-08-08 16:05:49 +08:00
MrZ_26
3a866bab1f 修改retro皮肤的骨块 2020-08-08 16:05:12 +08:00
MrZ_26
be1b6175b2 回放录像包含设置数据 2020-08-08 15:16:00 +08:00
MrZ_26
8ff5202a1f 控制设置das/arr预览错误 2020-08-08 15:11:03 +08:00
MrZ_26
7867f55610 玩家属性新增minY,y_img更名imgY,修改锁延刷新机制 2020-08-08 02:39:29 +08:00
MrZ_26
9f6a3057f5 玩家act函数addL/R更名zangiL/R 2020-08-08 02:15:48 +08:00
MrZ_26
2424ba692e 调试模式下键盘功能制不完全失效 2020-08-08 01:53:56 +08:00
MrZ_26
0278f13583 旋转中心相对坐标向左下修正负一 2020-08-08 01:46:58 +08:00
MrZ_26
dc5aa83cfb 修复序列生成器 2020-08-08 01:38:46 +08:00
MrZ_26
dd32518ee3 按R重开重置濒死警告 2020-08-08 01:36:31 +08:00
MrZ_26
e9acad55da 光标点击动画 2020-08-06 16:03:50 +08:00
MrZ_26
e7191267be 新皮肤 2020-08-06 02:55:56 +08:00
MrZ_26
018687ad19 均匀音量调节 2020-08-06 02:50:28 +08:00
MrZ_26
8aa40bc200 新tip库 2020-08-06 02:48:31 +08:00
MrZ_26
7224a709b4 音乐微调 2020-08-06 02:47:43 +08:00
MrZ_26
79ccc353a1 删除测试用print,攻击统计误差修复 2020-08-05 01:06:17 +08:00
MrZ_26
139330b4c4 删除用于更新窗口的tickEvent,放在主循环内间隔检测 2020-08-05 01:00:46 +08:00
MrZ_26
0c13f412c4 历史记录页面按钮样式,网格按钮尺寸,增加回放按钮 2020-08-05 01:00:16 +08:00
MrZ_26
b27318eecf 在加载模式时检测是否有非法rank 2020-08-05 00:59:03 +08:00
MrZ_26
d888db9195 仅在开局和退出当前游戏时更新统计 2020-08-05 00:58:43 +08:00
MrZ_26
d7136d0f1c 更好地使用scr变量,debug用print独立,鼠标触发圆形波纹 2020-08-05 00:58:23 +08:00
MrZ_26
31f5875fe2 bgm重新排序 2020-08-05 00:28:20 +08:00
MrZ_26
0437bff488 修复GM模式通关怪异现象 2020-08-04 23:47:07 +08:00
MrZ_26
01154db8fa 换BGM 2020-08-04 23:46:44 +08:00
MrZ_26
31ff756bb1 新语言:yygq 2020-08-04 23:44:23 +08:00
62 changed files with 1142 additions and 400 deletions

Binary file not shown.

View File

@@ -201,8 +201,8 @@ back.matrix={
draw=function()
gc.scale(scr.k)
gc.clear(.15,.15,.15)
local Y=ceil(scr.h*scr.dpi/80)
for x=1,ceil(scr.w*scr.dpi/80)do
local Y=ceil(scr.H/80)
for x=1,ceil(scr.W/80)do
for y=1,Y do
gc.setColor(1,1,1,sin(x+matrixT[x][y]*t)*.1+.1)
gc.rectangle("fill",80*x,80*y,-80,-80)

View File

@@ -3,7 +3,7 @@ local rem=table.remove
local function fadeOut(id)
local src=BGM.list[id]
local v=src:getVolume()-.025*setting.bgm*.1
local v=src:getVolume()-.025*setting.bgm*.01
src:setVolume(v>0 and v or 0)
if v<=0 then
src:stop()
@@ -12,9 +12,10 @@ local function fadeOut(id)
end
local function fadeIn(id)
local src=BGM.list[id]
local v=min(src:getVolume()+.025*setting.bgm*.1,setting.bgm*.1)
local v=setting.bgm*.01
v=min(v,src:getVolume()+.025*v)
src:setVolume(v)
if v>=setting.bgm*.1 then return true end
if v>=setting.bgm*.01 then return true end
end
local BGM={
@@ -23,9 +24,11 @@ local BGM={
--playing=[src:playing SRC]
}
BGM.list={
"blank","way","race","newera","push","reason","infinite",
"blank",
"race","push","way","reason",
"newera","oxygen","infinite",
"secret7th","secret8th",
"shining terminal","oxygen","distortion","far",
"shining terminal","distortion","far",
"rockblock","cruelty","final","8-bit happiness","end",
"how feeling",
}
@@ -65,7 +68,7 @@ function BGM.play(s)
end
function BGM.freshVolume()
if BGM.playing then
local v=setting.bgm*.1
local v=setting.bgm*.01
if v>0 then
BGM.playing:setVolume(v)
if BGM.suspend then

View File

@@ -79,8 +79,8 @@ local files={
unlock= fs.newFile("unlock.dat"),
}
local File={}
function File.loadRecord(N)
local FILE={}
function FILE.loadRecord(N)
local F=fs.newFile(N..".dat")
if F:open("r")then
local s=loadstring(F:read())
@@ -93,7 +93,7 @@ function File.loadRecord(N)
end
end
end
function File.saveRecord(N,L)
function FILE.saveRecord(N,L)
local F=fs.newFile(N..".dat")
F:open("w")
local _,mes=F:write(dumpTable(L))
@@ -102,11 +102,11 @@ function File.saveRecord(N,L)
TEXT.show(text.recSavingError..(mes or"unknown error"),1140,650,20,"sudden",.5)
end
end
function File.delRecord(N)
function FILE.delRecord(N)
fs.remove(N..".dat")
end
function File.loadUnlock()
function FILE.loadUnlock()
local F=files.unlock
if F:open("r")then
local s=F:read()
@@ -119,7 +119,7 @@ function File.loadUnlock()
end
end
end
function File.saveUnlock()
function FILE.saveUnlock()
local F=files.unlock
F:open("w")
local _,mes=F:write(dumpTable(modeRanks))
@@ -129,7 +129,7 @@ function File.saveUnlock()
end
end
function File.loadData()
function FILE.loadData()
local F=files.data
if F:open("r")then
local s=F:read()
@@ -145,7 +145,7 @@ function File.loadData()
end
end
end
function File.saveData()
function FILE.saveData()
local F=files.data
F:open("w")
local _,mes=F:write(dumpTable(stat))
@@ -155,7 +155,7 @@ function File.saveData()
end
end
function File.loadSetting()
function FILE.loadSetting()
local F=files.setting
if F:open("r")then
local s=F:read()
@@ -170,7 +170,7 @@ function File.loadSetting()
end
end
end
function File.saveSetting()
function FILE.saveSetting()
local F=files.setting
F:open("w")
local _,mes=F:write(dumpTable(setting))
@@ -180,7 +180,7 @@ function File.saveSetting()
end
end
function File.loadKeyMap()
function FILE.loadKeyMap()
local F=files.keyMap
if F:open("r")then
local s=loadstring(F:read())
@@ -191,7 +191,7 @@ function File.loadKeyMap()
end
end
end
function File.saveKeyMap()
function FILE.saveKeyMap()
local F=files.keyMap
F:open("w")
local _,mes=F:write(dumpTable(keyMap))
@@ -201,7 +201,7 @@ function File.saveKeyMap()
end
end
function File.loadVK()
function FILE.loadVK()
local F=files.VK
if F:open("r")then
local s=loadstring(F:read())
@@ -212,7 +212,7 @@ function File.loadVK()
end
end
end
function File.saveVK()
function FILE.saveVK()
local F=files.VK
F:open("w")
local _,mes=F:write(dumpTable(VK_org))
@@ -221,4 +221,4 @@ function File.saveVK()
else TEXT.show(text.VKSavingError..(mes or"unknown error"),1140,650,20,"sudden",.5)
end
end
return File
return FILE

View File

@@ -328,7 +328,7 @@ function keyDown.custom(key)
elseif key=="q"then
SCN.goto("sequence")
elseif key=="e"then
SCN.swapTo("draw")
SCN.swapTo("draw","swipe")
elseif #key==1 then
local T=tonumber(key)
if T and T>=1 and T<=5 then
@@ -384,6 +384,7 @@ function keyDown.sequence(key)
preBag={}
sceneTemp.cur=0
sceneTemp.sure=0
SFX.play("finesseError",.7)
else
sceneTemp.sure=50
end
@@ -460,6 +461,7 @@ function keyDown.draw(key)
if sceneTemp.sure>20 then
for y=1,20 do for x=1,10 do preField[y][x]=0 end end
sceneTemp.sure=0
SFX.play("finesseError",.7)
else
sceneTemp.sure=50
end
@@ -468,7 +470,7 @@ function keyDown.draw(key)
preField[sy][sx]=pen
end
elseif key=="e"then
SCN.swapTo("custom")
SCN.swapTo("custom","swipe")
elseif key=="escape"then
SCN.back()
elseif key=="c"and kb.isDown("lctrl","rctrl")or key=="cC"then
@@ -616,10 +618,9 @@ function keyDown.pause(key)
SCN.goto("setting_sound")
elseif key=="r"then
TASK.clear("play")
mergeStat(stat,players[1].stat)
resetGameData()
SCN.swapTo("play","none")
elseif key=="p"and game.result then
elseif key=="p"and(game.result or game.replaying)then
TASK.removeTask_code(TICK.autoPause)
resetPartGameData(true)
SCN.swapTo("play","none")
@@ -779,11 +780,11 @@ function keyDown.history(key)
end
-------------------------------------------------------------
local lastX,lastY=0,0--Last clickDown pos
function love.mousepressed(x,y,k,t,num)
if t then return end
function love.mousepressed(x,y,k,touch,num)
if touch then return end
mouseShow=true
mx,my=xOy:inverseTransformPoint(x,y)
if devMode==1 then print(mx,my)end
if devMode==1 then DBP(mx,my)end
if SCN.swapping then return end
if mouseDown[SCN.cur]then
mouseDown[SCN.cur](mx,my,k)
@@ -794,6 +795,7 @@ function love.mousepressed(x,y,k,t,num)
WIDGET.press(mx,my)
end
lastX,lastY=mx,my
sysFX.newRipple(.3,mx,my,30)
end
function love.mousemoved(x,y,dx,dy,t)
if t then return end
@@ -810,10 +812,9 @@ function love.mousemoved(x,y,dx,dy,t)
WIDGET.moveCursor(mx,my)
end
end
function love.mousereleased(x,y,k,t,num)
if t then return end
function love.mousereleased(x,y,k,touch,num)
if touch or SCN.swapping then return end
mx,my=xOy:inverseTransformPoint(x,y)
if t or SCN.swapping then return end
if mouseUp[SCN.cur]then
mouseUp[SCN.cur](mx,my,k)
end
@@ -868,27 +869,18 @@ function love.touchreleased(id,x,y)
if touchUp[SCN.cur]then
touchUp[SCN.cur](id,x,y)
end
if(x-lastX)^2+(y-lastY)^2<26 and touchClick[SCN.cur]then
touchClick[SCN.cur](x,y,k)
if(x-lastX)^2+(y-lastY)^2<26 then
if touchClick[SCN.cur]then
touchClick[SCN.cur](x,y,k)
end
sysFX.newRipple(.3,x,y,30)
end
end
function love.keypressed(i)
mouseShow=false
if not devMode then
if i~="f8"then
if SCN.swapping then return end
if keyDown[SCN.cur]then keyDown[SCN.cur](i)
elseif i=="escape"then SCN.back()
else WIDGET.keyPressed(i)
end
else
devMode=1
TEXT.show("DEBUG ON",640,360,80,"fly",.8)
end
else
if devMode then
if i=="f5"then
print("DEBUG:")
DBP("DEBUG:")
elseif i=="f8"then devMode=nil TEXT.show("DEBUG OFF",640,360,80,"fly",.8)
elseif i=="f9"then devMode=1 TEXT.show("DEBUG 1",640,360,80,"fly",.8)
elseif i=="f10"then devMode=2 TEXT.show("DEBUG 2",640,360,80,"fly",.8)
@@ -910,7 +902,7 @@ function love.keypressed(i)
assert(false,"Techmino:挂了")
elseif i=="e"then
for k,v in next,_G do
print(k,v)
DBP(k,v)
end
elseif WIDGET.sel then
local W=WIDGET.sel
@@ -926,7 +918,22 @@ function love.keypressed(i)
elseif i=="]"then W.font=W.font+1
end
end
else
goto NORMAL
end
return
end
::NORMAL::
if i~="f8"then
if SCN.swapping then return end
if keyDown[SCN.cur]then keyDown[SCN.cur](i)
elseif i=="escape"then SCN.back()
else WIDGET.keyPressed(i)
end
else
devMode=1
TEXT.show("DEBUG ON",640,360,80,"fly",.8)
end
end
function love.keyreleased(i)
@@ -995,10 +1002,11 @@ function love.lowmemory()
collectgarbage()
end
function love.resize(w,h)
scr.w,scr.h=w,h
scr.w,scr.h,scr.dpi=w,h,gc.getDPIScale()
scr.W,scr.H=scr.w*scr.dpi,scr.h*scr.dpi
scr.r=h/w
scr.rad=(w^2+h^2)^.5
scr.dpi=gc.getDPIScale()
if scr.r>=.5625 then
scr.k=w/1280
scr.x,scr.y=0,(h-w*9/16)*.5
@@ -1014,13 +1022,12 @@ function love.resize(w,h)
end
function love.focus(f)
if f then
TASK.new(TICK.autoResize,{0})
love.timer.step()
elseif SCN.cur=="play"and setting.autoPause then
pauseGame()
end
end
local scs={1,2,1,2,1,2,1,2,1,2,1.5,1.5,.5,2.5}
local scs={.5,1.5,.5,1.5,.5,1.5,.5,1.5,.5,1.5,1,1,0,2}
local devColor={
color.white,
color.lMagenta,
@@ -1097,7 +1104,7 @@ function love.run()
local R=int(r)%7+1
_=SKIN.libColor[setting.skin[R]]
gc.setColor(_[1],_[2],_[3],min(1-abs(1-r%1*2),.3))
gc.draw(TEXTURE.miniBlock[R],mx,my,Timer()%3.1416*4,20,20,scs[2*R]-.5,#blocks[R][0]-scs[2*R-1]+.5)
gc.draw(TEXTURE.miniBlock[R],mx,my,Timer()%3.1416*4,20,20,scs[2*R],#blocks[R][0]-scs[2*R-1])
gc.setColor(1,1,1,.5)gc.circle("fill",mx,my,5)
gc.setColor(1,1,1)gc.circle("fill",mx,my,3)
end
@@ -1145,9 +1152,13 @@ function love.run()
end
--Fresh power info.
if Timer()-lastFreshPow>3 and setting.powerInfo and SCN.cur~="load"then
if Timer()-lastFreshPow>2 and setting.powerInfo and SCN.cur~="load"then
updatePowerInfo()
lastFreshPow=Timer()
_=gc.getWidth()
if _~=scr.w then
love.resize(_,gc.getHeight())
end
end
--Keep 60fps

View File

@@ -2,7 +2,7 @@ local langList={
{
anykey="按任意键继续",
newVersion="检测到更新!",
newBigVersion="检测到大更新!大量存档信息被改动",
newBigVersion="检测到大更新!大量存档信息已修改",
marking="游戏作者:MrZ_26\n任何视频/直播不得出现此水印\n任何转述声明无效",
lang="中文",
atkModeName={"随机","徽章","击杀","反击"},
@@ -23,8 +23,8 @@ local langList={
speedup="速度加快",
win="胜利",
finish="结束",
lose="失败",
finish="完成",
gameover="游戏结束",
pause="暂停",
pauseCount="暂停统计",
@@ -155,7 +155,7 @@ local langList={
"使用LOVE2D引擎",
"错误或者建议请附带截图发送到内测群或者作者邮箱~",
"仅通过内测群1080457319进行免费下载/更新",
"其他渠道获得游戏皆有被修改/加广告/植入病毒的风险,程序只申请了动&联网权限!",
"其他渠道获得游戏皆有被修改/加广告/植入病毒的风险,程序只申请了动&联网权限!",
"若由于被修改的本游戏产生的各种损失作者不负责(我怎么负责啊跟我有啥关系)",
"请从正规途径获得最新版,游戏现为免费,不过有打赏当然感谢啦~",
},
@@ -167,12 +167,12 @@ local langList={
"美术:MrZ, (Gnyar)",
"音乐:MrZ, (T0722)",
"音效/语音: MrZ, Miya",
"演出: 模电, 吉备宏纯",
"官网: 渣渣120",
"演出: 模电, HBM",
"测试:思竣 官网: 渣渣120",
"",
"特别感谢:",
"Flyz, Farter, 蕴空之灵,",
"茶管, 思竣, [所有内测人员]",
"茶管, [所有内测人员]",
},
used=[[
使用工具:
@@ -297,7 +297,7 @@ local langList={
stereo="立体声",
spawn="方块生成",
bgm="音乐",
vib="",
vib="",
voc="语音",
back="返回",
},
@@ -344,7 +344,7 @@ local langList={
hide="显示虚拟按键",
track="按键自动跟踪",
sfx="按键音效",
vib="按键",
vib="按键",
icon="图标",
tkset="跟踪设置",
alpha="透明度",
@@ -465,7 +465,7 @@ local langList={
{
anykey="按任意键继续",
newVersion="检测到更新!",
newBigVersion="检测到大更新!大量存档信息被改动",
newBigVersion="检测到大更新!大量存档信息已修改",
marking="游戏作者:MrZ_26\n任何视频/直播不得出现此水印\n任何转述声明无效",
lang="全中文",
atkModeName={"随机","徽章","击杀","反击"},
@@ -486,8 +486,8 @@ local langList={
speedup="速度加快",
win="胜利",
finish="结束",
lose="失败",
finish="完成",
gameover="游戏结束",
pause="暂停",
pauseCount="暂停统计",
@@ -615,7 +615,7 @@ local langList={
"",
"错误或者建议请附带截图发送到内测群或者作者邮箱~",
"仅通过内测群1080457319进行免费下载/更新",
"其他渠道获得游戏皆有被修改/加广告/植入病毒的风险,程序只申请了动&联网权限!",
"其他渠道获得游戏皆有被修改/加广告/植入病毒的风险,程序只申请了动&联网权限!",
"若由于被修改的本游戏产生的各种损失作者不负责(我怎么负责啊跟我有啥关系)",
"请从正规途径获得最新版,游戏现为免费,不过有打赏当然感谢啦~",
},
@@ -627,12 +627,12 @@ local langList={
"美术:MrZ, (T0722, Gnyar)",
"音乐:MrZ, (T0722)",
"音效/语音: MrZ, Miya",
"演出: 模电, 吉备宏纯",
"官网: 渣渣120",
"演出: 模电, HBM",
"测试:思竣 官网: 渣渣120",
"",
"特别感谢:",
"Flyz, Farter, 蕴空之灵,",
"茶管, 思竣, [所有内测人员]",
"茶管, [所有内测人员]",
},
used=[[
使用工具:
@@ -757,7 +757,7 @@ local langList={
stereo="立体声",
spawn="方块生成",
bgm="音乐",
vib="",
vib="",
voc="语音",
back="返回",
},
@@ -804,7 +804,7 @@ local langList={
hide="显示虚拟按键",
track="按键自动跟踪",
sfx="按键音效",
vib="按键",
vib="按键",
icon="图标",
tkset="跟踪设置",
alpha="透明度",
@@ -945,9 +945,9 @@ local langList={
maxspeed="Max speed!",
speedup="Speed up!",
win="WIN",
win="Win",
finish="Finish",
lose="LOSE",
gameover="Game Over",
pause="Pause",
pauseCount="Pauses:",
@@ -1084,12 +1084,12 @@ local langList={
"Art: MrZ, (Gnyar)",
"Music: MrZ, (T0722)",
"Voice/ Sound: MrZ, Miya",
"Performance: 模电 吉备宏纯",
"Web: 渣渣120",
"Performance: 模电 HBM",
"Test: 思竣 Web: 渣渣120",
"",
"Special Thanks:",
"Flyz, Farter, 蕴空之灵,",
"Teatube, 思竣, [All test staff]",
"Teatube, [All test staff]",
},
used="Tool used:\n\tBeepbox\n\tGFIE\n\tGoldwave\nLib used:\n\tCold_Clear[MinusKelvin]\n\tsimple-love-lights[dylhunn]",
support="Support author",
@@ -1396,7 +1396,7 @@ local langList={
win=": )",
finish="&",
lose="x",
gameover="x",
pause="=",
pauseCount="=:",
@@ -1529,12 +1529,12 @@ local langList={
"Art: MrZ, (Gnyar)",
"Music: MrZ, (T0722)",
"Voice/ Sound: MrZ, Miya",
"Performance: 模电 吉备宏纯",
"Web: 渣渣120",
"Performance: 模电 HBM",
"Test: 思竣 Web: 渣渣120",
"",
"Special Thanks:",
"Flyz, Farter, 蕴空之灵,",
"Teatube, 思竣, [All test staff]",
"Teatube, [All test staff]",
},
used="Tool used:\n\tBeepbox\n\tGFIE\n\tGoldwave\nLib used:\n\tCold_Clear[MinusKelvin]\n\tsimple-love-lights[dylhunn]",
support="Support author",
@@ -1816,6 +1816,469 @@ local langList={
["sprintPenta"]= {"Sprint", "Pentomino", "Puzzle-18"},
},
},
{
anykey="您开始了",
newVersion="感谢更新!",
newBigVersion="检测到大更新!大量存档信息已修改",
marking="游戏作者:MrZ_26\n任何视频/直播不得出现此水印\n任何转述声明无效",
lang="就这",
atkModeName={"随机","徽章","击杀","反击"},
royale_remain=function(n)return""..n..""end,
cmb={nil,"1连","2连","3连","4连","5连","6连","7连","8连","9连","10连!","11连!","12连!","13连!","14连!","15连!","16连!","17连!","18连!","19连!","MEGACMB"},
block=nil,spin="",
clear={"消一","消二","消三","消四","卧槽"},
mini="",b2b="牛逼",b3b="很牛逼",
PC="消干净了",HPC="消挺干净",
hold="暂存",next="下一个",
replaying="[回放]",
stage=function(n)return"关卡 "..n end,
great="不错的",
awesome="您很强",
continue="您继续",
maxspeed="速度封顶",
speedup="速度加快",
win="成了",
finish="可以的",
gameover="挂了",
pause="歇会",
pauseCount="歇多久了",
custom="随便玩",
customOption={
drop="落多快:",
lock="锁多快:",
wait="出多快:",
fall="消多快:",
next="看几个:",
hold="暂存:",
sequence="出啥:",
visible="看不看得见:",
target="要消多少:",
freshLimit="能动几下:",
opponent="打谁:",
bg="背景:",
bgm="歌:",
},
customVal={
drop={"0G","1/180G","1/60G","1/40G","1/30G","1/25G","1/20G","1/18G","1/16G","1/14G","1/12G","1/10G","1/9G","1/8G","1/7G","1/6G","1/5G","1/4G","1/3G","1/2G","1G","2G","4G","8G","20G"},
lock={0,1,2,3,4,5,6,7,8,9,10,12,14,16,18,20,25,30,40,60,180,""},
wait=nil,
fall=nil,
next=nil,
hold={"","","无限"},
sequence={"bag","his4","乱出","循环","就那几个"},
visible={"看得到","还行","看不到","瞎了"},
target={10,20,40,100,200,500,1000,""},
freshLimit={0,8,15,""},
opponent={"打空气","9S Lv1","9S Lv2","9S Lv3","9S Lv4","9S Lv5","CC Lv1","CC Lv2","CC Lv3","CC Lv4","CC Lv5","CC Lv6"},
},
sequence="自定义序列",
softdropdas="软降DAS:",
softdroparr="软降ARR:",
snapLevelName={"无吸附","10px吸附","20px吸附","40px吸附","60px吸附","80px吸附"},
setting_game="游戏设置",
setting_video="改画面",
setting_sound="改声音",
setting_control="改控制",
setting_skin="改外观",
preview="预览",
keyboard="键盘",joystick="手柄",
ctrlSetHelp="方向键选择/翻页,回车修改,esc返回",
musicRoom="音乐室",
nowPlaying="正在放:",
page="页面:",
ai_fixed="不能同时开启AI和固定序列",
ai_prebag="不能同时开启AI和自定义序列",
settingSaved="设置已保存",
settingSavingError="设置保存失败:",
keyMapSaved="键位设置已保存",
keyMapSavingError="键位保存失败:",
VKSaved="虚拟按键设置已保存",
VKSavingError="虚拟按键保存失败:",
statSavingError="统计保存失败:",
unlockSavingError="解锁保存失败:",
recSavingError="纪录保存失败:",
ai_fixed="不能同时开启AI和固定序列",
ai_prebag="不能同时开启AI和自定义序列",
switchSpawnSFX="请开启方块出生音效",
needRestart="重新开始以生效",
copySuccess="已复制到剪切板",
dataCorrupted="数据损坏",
VKTchW="触摸点权重",
VKOrgW="原始点权重",
VKCurW="当前点权重",
noScore="暂无成绩",
highScore="最佳成绩",
newRecord="打破纪录",
errorMsg="Techmino遇到了问题,需要重新启动.\n我们已收集了一些错误信息,你可以向作者进行反馈.",
acts={
"左移:","右移:",
"顺时针旋转:","逆时针旋转:","180°旋转:",
"硬降:","软降:",
"暂存:","功能键:",
"重新开始:",
"左瞬移:","右瞬移:","软降到底:","软降一格:","软降四格:","软降十格:",
"落在最左:","落在最右:","列在最左:","列在最右:",
},
load={[0]="加载完成","加载语音ing","加载音乐ing","加载音效ing","加载图片ing","加载模式ing","加载乱七八糟的东西ing"},
pauseStat={
"时间:",
"按键/旋转/暂存:",
"落块:",
"消行/挖掘:",
"攻击/挖掘攻击:",
"上涨/接收/抵消:",
"消除:",
"Spin:",
"B2B/B3B/PC/HPC:",
"Finesse:",
},
radar={"DEF","OFF","ATK","SEND","SPD","DIG"},
radarData={
"D'PM",
"OPM",
"APM",
"SPM",
"L'PM",
"DPM",
},
stat={
spin="spin0~3",
clear="clear1~4",
"开了几次:",
"玩了几把:",
"玩了多久:",
"按键/旋转/暂存:",
"方块/消行/攻击:",
"接收/抵消/上涨:",
"挖掘/挖掘攻击:",
"效率/挖掘效率:",
"多余操作/极简率:",
"满贯/大满贯:",
"全/半清:",
},
help={
"既然你能玩到这个游戏,应该也不需要什么帮助吧?",
"这只是一个普通的方块游戏,请勿称此游戏为某某某方块",
"从TO/C2/KOS/TGM3/JS等方块获得过灵感",
"",
"使用LOVE2D引擎",
"错误或者建议请附带截图发送到内测群或者作者邮箱~",
"仅通过内测群1080457319进行免费下载/更新",
"其他渠道获得游戏皆有被修改/加广告/植入病毒的风险,程序只申请了振动&联网权限!",
"若由于被修改的本游戏产生的各种损失作者不负责(我怎么负责啊跟我有啥关系)",
"请从正规途径获得最新版,游戏现为免费,不过有打赏当然感谢啦~",
},
staff={
"作者:MrZ 邮箱:1046101471@qq.com",
"使用LOVE2D引擎",
"",
"程序:MrZ, FinnTenzor",
"美术:MrZ, (Gnyar)",
"音乐:MrZ, (T0722)",
"音效/语音: MrZ, Miya",
"演出: 模电, HBM",
"测试:思竣 官网: 渣渣120",
"",
"特别感谢:",
"Flyz, Farter, 蕴空之灵,",
"茶管, [所有内测人员]",
},
used=[[
使用工具:
Beepbox
GFIE
Goldwave
使用库:
Cold_Clear[MinusKelvin]
simple-love-lights[dylhunn]
]],
support="支持作者",
group="官方QQ群(如果没有被暗改的话就是这个):1080457319",
WidgetText={
main={
play="开始",
setting="设置",
music="音乐室",
stat="统计信息",
help="帮助",
qplay="快速开始",
lang="言/A",
quit="退出",
},
mode={
setting="参数(E)",
start="开始",
back="返回",
},
music={
bgm="",
up="",
play="播放",
down="",
back="返回",
},
custom={
up="",
down="",
left="",
right="",
set1="40行(1)",
set2="1v1(2)",
set3="无尽(3)",
set4="隐形(4)",
set5="极限(5)",
seq="高级设置(Q)",
draw="初始场地(E)",
back="返回",
},
sequence={
Z="Z",S="S",J="J",L="L",T="T",O="O",I="I",
Z5="Z5",S5="S5",P="P",Q="Q",F="F",E="E",T5="T5",U="U",
V="V",W="W",X="X",J5="J5",L5="L5",R="R",Y="Y",N="N",H="H",I5="I5",
left="",
right="",
backsp="<X",
reset="R",
copy="复制",
paste="粘贴",
back="返回",
},
draw={
any="不定",
space="×",
clear="清除",
demo="不显示×",
copy="复制",
paste="粘贴",
custom="参数(E)",
back="返回",
},
play={
pause="暂停",
},
pause={
setting="设置(S)",
replay= "回放(P)",
resume= "继续(esc)",
restart="重新开始(R)",
quit= "退出(Q)",
},
setting_game={
graphic="←改画面",
sound="改声音→",
ctrl="改控制",
reTime="开局等待时间",
maxNext="最大预览数量",
autoPause="自动暂停",
layout="外观",
key="改键位",
touch="改触屏",
quickR="快速重新开始",
swap="组合键切换攻击模式",
fine="极简操作提示音",
back="返回",
},
setting_video={
sound="←改声音",
game="游戏设置→",
ghost="阴影",
smooth="平滑下落",
center="旋转中心",
grid="网格",
bagLine="包分界线",
lockFX="锁定特效等级",
dropFX="下落特效等级",
clearFX="消除特效等级",
shakeFX="晃动特效等级",
atkFX="攻击特效等级",
frame="绘制帧率",
text="消行文本",
warn="死亡预警",
fullscreen="全屏",
bg="背景",
power="电量显示",
back="返回",
},
setting_sound={
game="←游戏设置",
graphic="改画面→",
sfx="音效",
stereo="立体声",
spawn="出块",
bgm="",
vib="嗡嗡",
voc="语音",
back="返回",
},
setting_control={
das="DAS",arr="ARR",
sddas="软降DAS",sdarr="软降ARR",
ihs="提前Hold",
irs="提前旋转",
ims="提前移动",
reset="重来",
back="返回",
},
setting_key={
back="返回",
},
setting_skin={
prev="",next="",
prev1="",next1="",spin1="R",
prev2="",next2="",spin2="R",
prev3="",next3="",spin3="R",
prev4="",next4="",spin4="R",
prev5="",next5="",spin5="R",
prev6="",next6="",spin6="R",
prev7="",next7="",spin7="R",
skinR="重设配色",
faceR="重设方向",
back="返回",
},
setting_touch={
default="默认组合",
snap=function()return text.snapLevelName[sceneTemp.snap]end,
option="选项",
back="返回",
size="大小",
},
setting_touchSwitch={
b1= "左移:", b2="右移:", b3="右转:", b4="左转:",
b5= "180°转:", b6="硬降:", b7="软降:", b8="暂存:",
b9= "功能键:", b10="重新开始:",b11="左瞬移:", b12="右瞬移:",
b13="软降到底:",b14="软降一格:",b15="软降四格:", b16="软降十格:",
b17="落在最左:",b18="落在最右:",b19="列在最左:", b20="列在最右:",
norm="标准",
pro="专业",
hide="显示虚拟按键",
track="按键自动跟踪",
sfx="按键音效",
vib="按键振动",
icon="图标",
tkset="跟踪设置",
alpha="透明度",
back="返回",
},
setting_trackSetting={
VKDodge="自动避让",
back="返回",
},
setting_lang={
back="返回",
},--LangName added later
help={
staff="制作人员",
his="更新历史",
qq="作者QQ",
back="返回",
},
staff={
back="返回",
},
history={
prev="",
next="",
back="返回",
},
stat={
path="打开存储目录",
back="返回",
},
debug={
killWTM="关水印",
unlock="解锁全模式",
reset="重置?",
reset1="重置解锁/等级",
reset2="重置统计",
reset3="清空所有数据",
back="返回",
},
},
modes={
["sprint_10"]= {"竞速", "10L", "消10行"},
["sprint_20"]= {"竞速", "20L", "消20行"},
["sprint_40"]= {"竞速", "40L", "消40行"},
["sprint_100"]= {"竞速", "100L", "消100行"},
["sprint_400"]= {"竞速", "400L", "消400行"},
["sprint_1000"]= {"竞速", "1000L", "消1000行"},
["drought_normal"]= {"干旱", "100L", "哟,就不行了?"},
["drought_lunatic"]= {"干旱", "100L", "可牛逼了嗷"},
["marathon_normal"]= {"马拉松", "普通", "休闲模式"},
["marathon_hard"]= {"马拉松", "困难", "休闲模式"},
["solo_1"]= {"单挑", "简单", "鲨AI"},
["solo_2"]= {"单挑", "普通", "鲨AI"},
["solo_3"]= {"单挑", "困难", "鲨AI"},
["solo_4"]= {"单挑", "疯狂", "鲨AI"},
["solo_5"]= {"单挑", "极限", "鲨AI"},
["techmino49_easy"]= {"49人混战", "简单", "这我岂不是乱鲨"},
["techmino49_hard"]= {"49人混战", "困难", "这我岂不是乱鲨"},
["techmino49_ultimate"]={"49人混战", "极限", "你吃鸡率多少?"},
["techmino99_easy"]= {"99人混战", "简单", "这我岂不是乱鲨"},
["techmino99_hard"]= {"99人混战", "困难", "这我岂不是乱鲨"},
["techmino99_ultimate"]={"99人混战", "极限", "你吃鸡率多少?"},
["round_1"]= {"回合制", "简单", "下棋"},
["round_2"]= {"回合制", "普通", "下棋"},
["round_3"]= {"回合制", "困难", "下棋"},
["round_4"]= {"回合制", "疯狂", "下棋"},
["round_5"]= {"回合制", "极限", "下棋"},
["master_beginner"]= {"大师", "疯狂", "无脑20G"},
["master_advance"]= {"大师", "极限", "简单20G"},
["master_final"]= {"大师", "终点", "究极20G:拜拜了您嘞"},
["GM"]= {"宗师", "GM", "你行你上"},
["blind_easy"]= {"隐形", "半隐", "谁都能玩"},
["blind_normal"]= {"隐形", "全隐", "稍加练习即可"},
["blind_hard"]= {"隐形", "瞬隐", "和上一个一样"},
["blind_lunatic"]= {"隐形", "瞬隐+", "这个确实挺难的"},
["blind_ultimate"]= {"隐形", "啊这", "你准备好了吗"},
["blind_wtf"]= {"隐形", "不会吧", "还没准备好"},
["classic_fast"]= {"高速经典", "CTWC", "就这?简单"},
["survivor_easy"]= {"生存", "简单", "这都玩不下去?不会吧"},
["survivor_normal"]= {"生存", "普通", "呵呵,这都玩不过?"},
["survivor_hard"]= {"生存", "困难", "所以呢?"},
["survivor_lunatic"]= {"生存", "疯狂", "然后呢?"},
["survivor_ultimate"]= {"生存", "极限", "舒服了"},
["attacker_hard"]= {"进攻", "困难", "进攻练习"},
["attacker_ultimate"]= {"进攻", "极限", "进攻练习"},
["defender_normal"]= {"防守", "普通", "防守练习"},
["defender_lunatic"]= {"防守", "疯狂", "防守练习"},
["dig_hard"]= {"挖掘", "困难", "挖掘练习"},
["dig_ultimate"]= {"挖掘", "极限", "挖掘练习"},
["bigbang"]= {"大爆炸", "简单", "All-spin 入门教程\n未制作完成,落块即通"},
["c4wtrain_normal"]= {"C4W练习", "普通", "无 限 连 击"},
["c4wtrain_lunatic"]= {"C4W练习", "疯狂", "无 限 连 击"},
["pctrain_normal"]= {"全清训练", "普通", "随便打打"},
["pctrain_lunatic"]= {"全清训练", "疯狂", "就那几个题,没难度"},
["pcchallenge_normal"]= {"全清挑战", "普通", "100行内刷PC"},
["pcchallenge_hard"]= {"全清挑战", "困难", "100行内刷PC"},
["pcchallenge_lunatic"]={"全清挑战", "疯狂", "100行内刷PC"},
["tech_normal"]= {"科研", "普通", "禁止断B2B"},
["tech_normal+"]= {"科研", "普通+", "仅允许spin与PC"},
["tech_hard"]= {"科研", "困难", "禁止断B2B"},
["tech_hard+"]= {"科研", "困难+", "仅允许spin与PC"},
["tech_lunatic"]= {"科研", "疯狂", "禁止断B2B"},
["tech_lunatic+"]= {"科研", "疯狂+", "仅允许spin与PC"},
["tech_finesse"]= {"科研", "极简", "强制最简操作"},
["tech_finesse+"]= {"科研", "极简+", "禁止普通消除,强制最简操作"},
["tsd_easy"]= {"TSD挑战", "简单", "刷T2"},
["tsd_hard"]= {"TSD挑战", "困难", "刷T2"},
["tsd_ultimate"]= {"TSD挑战", "极限", "刷T2"},
["zen"]= {"", "200", "不限时200行"},
["ultra"]= {"限时打分", "挑战", "2分钟刷分"},
["infinite"]= {"无尽", "", "真的有人会玩这个?"},
["infinite_dig"]= {"无尽:挖掘", "", "闲得慌的话来挖"},
["custom_clear"]= {"自定义", "普通", "试验场"},
["custom_puzzle"]= {"自定义", "拼图", "宁就是方块艺术家"},
["sprintPenta"]= {"竞速", "五联块", "哦哟?你急了"},
},
},
}
local publicText={
block={
@@ -1843,6 +2306,7 @@ local publicWidgetText={
chi2="全中文",
eng="English",
str="?????",
yygq="就这?",
},
}
for key,list in next,publicWidgetText do
@@ -1865,7 +2329,7 @@ local drawableTextLoad={
"anykey",
"replaying",
"next","hold",
"win","finish","lose","pause",
"win","finish","gameover","pause",
"custom","sequence",
"setting_game",
"setting_video",
@@ -1892,6 +2356,7 @@ function LANG.set(l)
end
end
for _,s in next,drawableTextLoad do
print(s)
drawableText[s]:set(text[s])
end
collectgarbage()

View File

@@ -378,7 +378,7 @@ function Pnt.sequence()
--Confirm reset
if s.sure>0 then
gc.setColor(1,1,1,s.sure*.02)
gc.draw(drawableText.question,1035,570)
gc.draw(drawableText.question,980,470)
end
end
@@ -520,7 +520,7 @@ function Pnt.play()
gc.origin()
if restartCount>0 then
gc.setColor(0,0,0,restartCount*.05)
gc.rectangle("fill",0,0,scr.w*scr.dpi,scr.h*scr.dpi)
gc.rectangle("fill",0,0,scr.W,scr.H)
end
if game.warnLVL>0 then
gc.setColor(0,0,0,0)
@@ -545,7 +545,7 @@ function Pnt.pause()
gc.setColor(.15,.15,.15,_)
gc.push("transform")
gc.origin()
gc.rectangle("fill",0,0,scr.w*scr.dpi,scr.h*scr.dpi)
gc.rectangle("fill",0,0,scr.W,scr.H)
gc.pop()
--Pause Info
@@ -738,7 +738,7 @@ function Pnt.setting_skin()
for N=1,7 do
local face=setting.face[N]
local B=blocks[N][face]
local x,y=-25+140*N-scs[N][face][2]*30,325+scs[N][face][1]*30
local x,y=-55+140*N-scs[N][face][2]*30,355+scs[N][face][1]*30
local col=#B[1]
for i=1,#B do for j=1,col do
if B[i][j]then

View File

@@ -294,7 +294,10 @@ function sceneBack.load()
end
function sceneBack.pause()
love.keyboard.setKeyRepeat(true)
mergeStat(stat,players[1].stat)
if not game.replaying then
mergeStat(stat,players[1].stat)
end
FILE.saveData()
TASK.clear("play")
end
function sceneBack.setting_game()
@@ -364,26 +367,24 @@ local swap={
fade={30,15,function(t)
local t=t>15 and 2-t/15 or t/15
gc.setColor(0,0,0,t)
gc.rectangle("fill",0,0,scr.w*scr.dpi,scr.h*scr.dpi)
gc.rectangle("fill",0,0,scr.W,scr.H)
end},
fade_togame={120,20,function(t)
local t=t>20 and(120-t)/100 or t/20
gc.setColor(0,0,0,t)
gc.rectangle("fill",0,0,scr.w*scr.dpi,scr.h*scr.dpi)
gc.rectangle("fill",0,0,scr.W,scr.H)
end},
slowFade={180,90,function(t)
local t=t>90 and 2-t/90 or t/90
gc.setColor(0,0,0,t)
gc.rectangle("fill",0,0,scr.w*scr.dpi,scr.h*scr.dpi)
gc.rectangle("fill",0,0,scr.W,scr.H)
end},
swipe={30,15,function(t)
gc.setColor(0,0,0,1-abs(t-15)/15)
if t>15 then
t=t/15-1
gc.rectangle("fill",scr.w*scr.dpi,0,-scr.w*scr.dpi*(1-t),scr.h*scr.dpi)
else
gc.rectangle("fill",0,0,scr.w*scr.dpi*t/15,scr.h*scr.dpi)
end
t=t/30
gc.setColor(.1,.1,.1,1-abs(t-.5))
t=t*t*(3-2*t)*2-1
local w=scr.W
gc.rectangle("fill",t*w,0,w,scr.H)
end},
}--Scene swapping animations
function SCN.swapTo(tar,style)--Parallel scene swapping, cannot back

View File

@@ -34,10 +34,10 @@ function SFX.loadAll()
end
end
function SFX.fieldPlay(s,v,P)
SFX.play(s,v,(P.curX+P.sc[2]-6.5)*.15)
SFX.play(s,v,(P.curX+P.sc[2]-5.5)*.15)
end
function SFX.play(s,vol,pos,force)
if setting.sfx==0 and not force then return end
function SFX.play(s,vol,pos)
if setting.sfx==0 then return end
local S=SFX.list[s]--Source list
if not S then return end
local n=1
@@ -58,11 +58,31 @@ function SFX.play(s,vol,pos,force)
S:setPosition(0,0,0)
end
end
if not force then
S:setVolume((vol or 1)*setting.sfx*.1)
else
S:setVolume(vol*.1)
S:setVolume(((vol or 1)*setting.sfx*.01)^1.626)
S:play()
end
function SFX.fplay(s,vol,pos)
local S=SFX.list[s]--Source list
if not S then return end
local n=1
while S[n]:isPlaying()do
n=n+1
if not S[n]then
S[n]=S[1]:clone()
S[n]:seek(0)
break
end
end
S=S[n]--AU_SRC
if S:getChannelCount()==1 then
if pos then
pos=pos*setting.stereo*.1
S:setPosition(pos,1-pos^2,0)
else
S:setPosition(0,0,0)
end
end
S:setVolume((vol*.01)^1.626)
S:play()
end
function SFX.reset()

View File

@@ -3,6 +3,6 @@ extern float level;
vec4 effect(vec4 color,Image text,vec2 pos,vec2 scr_pos){
float dx=abs(scr_pos.x/w-0.5);
float dy=abs(scr_pos.y/h-0.5);
float a=(max(dx,dy)*2.-.626)*level;
float a=(max(dx*2.6,dy*1.8)-.626)*level;
return vec4(1.,0.,0.,a);
}

View File

@@ -1,31 +1,47 @@
local gc=love.graphics
local setColor=gc.setColor
local setWidth=gc.setLineWidth
local rect=gc.rectangle
local ins,rem=table.insert,table.remove
local fx={}
local FXupdate={}
function FXupdate.ripple(S,dt)
S.t=S.t+dt*S.rate
return S.t>=1
end
function FXupdate.rectRipple(S,dt)
S.t=S.t+dt*S.rate
return S.t>=1
end
function FXupdate.shade(S,dt)
S.t=S.t+dt*S.rate
return S.t>=1
end
local FXdraw={}
function FXdraw.ripple(S)
setWidth(2)
local t=S.t
setColor(1,1,1,1-t)
gc.circle("line",S.x,S.y,t*(2-t)*S.r)
end
function FXdraw.rectRipple(S)
setWidth(6)
setColor(1,1,1,1-S.t)
local r=(10*S.t)^1.2
rect("line",S[1]-r,S[2]-r,S[3]+2*r,S[4]+2*r)
gc.rectangle("line",S.x-r,S.y-r,S.w+2*r,S.h+2*r)
end
function FXdraw.shade(S)
setColor(S[1],S[2],S[3],1-S.t)
rect("fill",S[4],S[5],S[6],S[7],2)
setColor(S.r,S.g,S.b,1-S.t)
gc.rectangle("fill",S.x,S.y,S.w,S.h,2)
end
local sysFX={}
function sysFX.update(dt)
for i=#fx,1,-1 do
local S=fx[i]
S.t=S.t+dt*S.rate
if S.t>=1 then
for i=i,#fx do
fx[i]=fx[i+1]
end
if fx[i]:update(dt) then
rem(fx,i)
end
end
end
@@ -34,9 +50,33 @@ function sysFX.draw()
fx[i]:draw()
end
end
--0=ripple,x,y,w,h
--1=shade,r,g,b,x,y,w,h
function sysFX.new(type,duration,...)
fx[#fx+1]={draw=FXdraw[type],t=0,rate=1/duration,...}
function sysFX.newRipple(duration,x,y,r)
fx[#fx+1]={
update=FXupdate.ripple,
draw=FXdraw.ripple,
t=0,
rate=1/duration,
x=x,y=y,r=r,
}
end
function sysFX.newRectRipple(duration,x,y,w,h)
fx[#fx+1]={
update=FXupdate.rectRipple,
draw=FXdraw.rectRipple,
t=0,
rate=1/duration,
x=x,y=y,w=w,h=h,
}
end
function sysFX.newShade(duration,r,g,b,x,y,w,h)
fx[#fx+1]={
update=FXupdate.shade,
draw=FXdraw.shade,
t=0,
rate=1/duration,
r=r,g=g,b=b,
x=x,y=y,w=w,h=h,
}
end
return sysFX

View File

@@ -25,6 +25,13 @@ function Tmr.load()
M[k]=v
end
M.records=FILE.loadRecord(m.name)or M.score and{}
if M.score then
if modeRanks[M.name]==6 then
modeRanks[M.name]=0
end
else
modeRanks[M.name]=6
end
-- M.icon=gc.newImage("image/modeIcon/"..m.icon..".png")
-- M.icon=gc.newImage("image/modeIcon/custom.png")
elseif S.phase==6 then
@@ -237,7 +244,6 @@ function Tmr.play(dt)
restartCount=restartCount+1
if restartCount>20 then
TASK.clear("play")
mergeStat(stat,P1.stat)
resetPartGameData()
return
end
@@ -311,7 +317,15 @@ function Tmr.setting_control()
if T.das>0 then
T.das=T.das-1
if T.das==0 then
T.pos=T.pos+T.dir
if T.arr==0 then
T.pos=T.pos+7*T.dir
T.das=setting.das
T.arr=setting.arr
T.dir=-T.dir
T.wait=26
else
T.pos=T.pos+T.dir
end
end
else
T.arr=T.arr-1

View File

@@ -121,7 +121,7 @@ function VOC.play(s,chn)
if chn then
local L=voiceQueue[chn]
local _=VOC.list[s]
if not _ then print("no VOC called:"..s)return end
if not _ then DBP("no VOC called:"..s)return end
L[#L+1]=_[rnd(#_)]
L.s=1
--Add to queue[chn]

View File

@@ -25,13 +25,13 @@ function button:getCenter()
end
function button:FX()
local ATV=self.ATV
sysFX.new(
"ripple",
sysFX.newRectRipple(
.16,
self.x-ATV,
self.y-ATV,
self.w+2*ATV,
self.h+2*ATV
,5
)
end
function button:update()
@@ -68,7 +68,7 @@ function button:draw()
end
end
function button:getInfo()
print(format("x=%d,y=%d,w=%d,h=%d,font=%d",self.x+self.w*.5,self.y+self.h*.5,self.w,self.h,self.font))
DBP(format("x=%d,y=%d,w=%d,h=%d,font=%d",self.x+self.w*.5,self.y+self.h*.5,self.w,self.h,self.font))
end
local key={
@@ -118,7 +118,7 @@ function key:draw()
end
end
function key:getInfo()
print(format("x=%d,y=%d,w=%d,h=%d,font=%d",self.x+self.w*.5,self.y+self.h*.5,self.w,self.h,self.font))
DBP(format("x=%d,y=%d,w=%d,h=%d,font=%d",self.x+self.w*.5,self.y+self.h*.5,self.w,self.h,self.font))
end
local switch={
@@ -171,11 +171,11 @@ function switch:draw()
if t then
gc.setColor(1,1,1)
setFont(self.font)
gc.printf(t,x-412-ATV,y+20-self.font*.7-ATV*.5,400,"right")
gc.printf(t,x-412-ATV,y+20-self.font*.7,400,"right")
end
end
function switch:getInfo()
print(format("x=%d,y=%d,font=%d",self.x,self.y,self.font))
DBP(format("x=%d,y=%d,font=%d",self.x,self.y,self.font))
end
local slider={
@@ -207,22 +207,25 @@ end
function slider:draw()
local x,y=self.x,self.y
local ATV=self.ATV
local x2=x+self.w
gc.setColor(1,1,1,.5+ATV*.06)
--Units
gc.setColor(1,1,1,.5+ATV*.06)
gc.setLineWidth(2)
local x1,x2=x,x+self.w
for p=0,self.unit do
local x=x1+(x2-x1)*p/self.unit
gc.line(x,y+7,x,y-7)
if self.showUnit then
gc.setLineWidth(2)
for p=0,self.unit do
local x=x+(x2-x)*p/self.unit
gc.line(x,y+7,x,y-7)
end
end
--Axis
gc.setLineWidth(4)
gc.line(x1,y,x2,y)
gc.line(x,y,x2,y)
--Block
local bx,by,bw,bh=x1+(x2-x1)*self.pos/self.unit-10-ATV*.5,y-16-ATV,20+ATV,32+2*ATV
local bx,by,bw,bh=x+(x2-x)*self.pos/self.unit-10-ATV*.5,y-16-ATV,20+ATV,32+2*ATV
gc.setColor(.8,.8,.8)
gc.rectangle("fill",bx,by,bw,bh)
if ATV>0 then
@@ -236,11 +239,11 @@ function slider:draw()
if t then
gc.setColor(1,1,1)
setFont(self.font)
gc.printf(t,x-312-ATV,y-self.font*.7-ATV*.5,300,"right")
gc.printf(t,x-312-ATV,y-self.font*.7,300,"right")
end
end
function slider:getInfo()
print(format("x=%d,y=%d,w=%d",self.x,self.y,self.w))
DBP(format("x=%d,y=%d,w=%d",self.x,self.y,self.w))
end
local WIDGET={}
@@ -367,6 +370,7 @@ function WIDGET.newSlider(D)
},
unit= D.unit,
showUnit=not D.noUnit,
font= D.font,
change= D.change,
disp= D.disp,

View File

@@ -69,8 +69,8 @@ local virtualkeySet={
{16,970, 50,30},--down10
{17,1030, 50,30},--dropLeft
{18,1090, 50,30},--dropRight
{19,1150, 50,30},--addLeft
{20,1210, 50,30},--addRight
{19,1150, 50,30},--zangiLeft
{20,1210, 50,30},--zangiRight
},--PC key feedback(top&in a row)
}
@@ -119,7 +119,7 @@ local Widgets={
newButton({name="back", x=1200,y=655,w=120,h=80,color="white", font=40,code=BACK}),
},
music={
newSlider({name="bgm", x=760, y=80, w=400, unit=10, font=35,change=function()BGM.freshVolume()end,disp=SETval("bgm"),code=SETsto("bgm")}),
newSlider({name="bgm", x=760, y=80, w=400,unit=100, noUnit=true, font=35,change=function()BGM.freshVolume()end,disp=SETval("bgm"),code=SETsto("bgm")}),
newButton({name="up", x=1100, y=200, w=120,h=120, color="white", font=55,code=pressKey("up")}),
newButton({name="play", x=1100, y=340, w=120,h=120, color="white", font=35,code=pressKey("space"),hide=function()return setting.bgm==0 end}),
newButton({name="down", x=1100, y=480, w=120,h=120, color="white", font=55,code=pressKey("down")}),
@@ -203,7 +203,7 @@ local Widgets={
newSwitch({name="demo", x=755, y=640, font=30,disp=function()return sceneTemp.demo end,code=function()sceneTemp.demo=not sceneTemp.demo end}),
newButton({name="copy", x=920, y=640, w=120, h=120, color="lRed", font=35,code=pressKey("cC")}),
newButton({name="paste", x=1060, y=640, w=120, h=120, color="lBlue", font=35,code=pressKey("cV")}),
newButton({name="custom", x=110, y=80, w=140, h=80, color="white", font=35,code=function()SCN.goto("custom")end}),
newButton({name="custom", x=110, y=80, w=140, h=80, color="white", font=35,code=pressKey("e")}),
newButton({name="back", x=1200, y=640, w=120, h=120, color="white", font=35,code=BACK}),
},
play={
@@ -211,7 +211,7 @@ local Widgets={
},
pause={
newButton({name="setting", x=1120, y=70, w=240,h=90, color="lBlue", font=35,code=pressKey("s")}),
newButton({name="replay", x=640, y=250, w=240,h=100,color="lYellow",font=30,code=pressKey("p"),hide=function()return not game.result end}),
newButton({name="replay", x=640, y=250, w=240,h=100,color="lYellow",font=30,code=pressKey("p"),hide=function()return not(game.result or game.replaying)end}),
newButton({name="resume", x=640, y=367, w=240,h=100,color="lGreen", font=30,code=pressKey("escape")}),
newButton({name="restart", x=640, y=483, w=240,h=100,color="lRed", font=33,code=pressKey("r")}),
newButton({name="quit", x=640, y=600, w=240,h=100,color="lGrey", font=35,code=BACK}),
@@ -239,7 +239,7 @@ local Widgets={
newSwitch({name="ghost", x=250, y=180,font=35, disp=SETval("ghost"), code=SETrev("ghost")}),
newSwitch({name="smooth", x=250, y=260,font=25, disp=SETval("smooth"), code=SETrev("smooth")}),
newSwitch({name="center", x=500, y=180,font=35, disp=SETval("center"), code=SETrev("center")}),
newSwitch({name="grid", x=500, y=260,font=30, disp=SETval("grid"), code=SETrev("grid")}),
newSwitch({name="grid", x=500, y=260,font=35, disp=SETval("grid"), code=SETrev("grid")}),
newSwitch({name="bagLine", x=730, y=180,font=30, disp=SETval("bagLine"), code=SETrev("bagLine")}),
newSlider({name="lockFX", x=350, y=340,w=373,unit=3, font=32,disp=SETval("lockFX"), code=SETsto("lockFX")}),
newSlider({name="dropFX", x=350, y=400,w=373,unit=5, font=32,disp=SETval("dropFX"), code=SETsto("dropFX")}),
@@ -276,10 +276,10 @@ local Widgets={
setting_sound={
newButton({name="game", x=200, y=80,w=240,h=80,color="lCyan",font=35,code=function()SCN.swapTo("setting_game","swipe")end}),
newButton({name="graphic", x=1080, y=80,w=240,h=80,color="lCyan",font=35,code=function()SCN.swapTo("setting_video","swipe")end}),
newSlider({name="sfx", x=180, y=200,w=400,unit=10,font=35,change=function()SFX.play("blip_1")end, disp=SETval("sfx"), code=SETsto("sfx")}),
newSlider({name="stereo", x=180, y=500,w=400,unit=10,font=35,change=function()SFX.play("move",1,-1)SFX.play("lock",1,1)end, disp=SETval("stereo"), code=SETsto("stereo"),hide=function()return setting.sfx==0 end}),
newSlider({name="spawn", x=180, y=300,w=400,unit=10,font=30,change=function()SFX.play("spawn_1",setting.spawn,nil,true)end, disp=SETval("spawn"), code=SETsto("spawn")}),
newSlider({name="bgm", x=180, y=400,w=400,unit=10,font=35,change=function()BGM.freshVolume()end, disp=SETval("bgm"), code=SETsto("bgm")}),
newSlider({name="sfx", x=180, y=200,w=400,unit=100,noUnit=true,font=35,change=function()SFX.play("blip_1")end, disp=SETval("sfx"), code=SETsto("sfx")}),
newSlider({name="stereo", x=180, y=500,w=400,unit=10, font=35,change=function()SFX.play("move",1,-1)SFX.play("lock",1,1)end, disp=SETval("stereo"), code=SETsto("stereo"),hide=function()return setting.sfx==0 end}),
newSlider({name="spawn", x=180, y=300,w=400,unit=100,noUnit=true,font=30,change=function()SFX.fplay("spawn_1",setting.spawn)end, disp=SETval("spawn"), code=SETsto("spawn")}),
newSlider({name="bgm", x=180, y=400,w=400,unit=100,noUnit=true,font=35,change=function()BGM.freshVolume()end, disp=SETval("bgm"), code=SETsto("bgm")}),
newSlider({name="vib", x=750, y=200,w=400,unit=5, font=28,change=function()VIB(2)end, disp=SETval("vib"), code=SETsto("vib")}),
newSlider({name="voc", x=750, y=300,w=400,unit=10,font=32,change=function()VOC.play("nya")end, disp=SETval("voc"), code=SETsto("voc")}),
newButton({name="back", x=1140, y=650,w=200,h=80,color="white",font=40,code=BACK}),
@@ -436,6 +436,7 @@ local Widgets={
newButton({name="chi2", x=380, y=100,w=200,h=120,color="white",font=45,code=setLang(2)}),
newButton({name="eng", x=600, y=100,w=200,h=120,color="white",font=45,code=setLang(3)}),
newButton({name="str", x=820, y=100,w=200,h=120,color="white",font=45,code=setLang(4)}),
newButton({name="yygq", x=1040, y=100,w=200,h=120,color="white",font=45,code=setLang(5)}),
newButton({name="back", x=640, y=600,w=200,h=80,color="white",font=40,code=BACK}),
},
help={
@@ -448,8 +449,8 @@ local Widgets={
newButton({name="back", x=1160, y=630,w=150,h=80,color="white",font=40,code=BACK}),
},
history={
newButton({name="prev", x=1155, y=170,w=180,h=180,color="white",font=65,code=pressKey("up"),hide=function()return sceneTemp.pos==1 end}),
newButton({name="next", x=1155, y=400,w=180,h=180,color="white",font=65,code=pressKey("down"),hide=function()return sceneTemp.pos==#sceneTemp.text end}),
newKey({name="prev", x=1155, y=170,w=180,h=180,color="white",font=65,code=pressKey("up"),hide=function()return sceneTemp.pos==1 end}),
newKey({name="next", x=1155, y=400,w=180,h=180,color="white",font=65,code=pressKey("down"),hide=function()return sceneTemp.pos==#sceneTemp.text end}),
newButton({name="back", x=1155, y=600,w=180,h=90,color="white",font=40,code=BACK}),
},
stat={

View File

@@ -1,4 +1,4 @@
gameVersion="Alpha V0.10.0"
gameVersion="Alpha V0.10.2"
function love.conf(t)
t.identity="Techmino"--Saving folder
t.version="11.1"

BIN
font.ttf

Binary file not shown.

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

View File

@@ -8,13 +8,16 @@ Techmino is my first "huge project"
optimization is welcomed if you also love tetromino game
]]--
--?
function NULL()end
DBP=print--use this if need debugging print
--Global Setting & Vars
math.randomseed(os.time()*626)
love.keyboard.setKeyRepeat(true)
love.keyboard.setTextInput(false)
love.mouse.setVisible(false)
function NULL()end
system=love.system.getOS()
game={}
mapCam={
@@ -103,14 +106,18 @@ if fs.getInfo("tech_ultimate+.dat")then fs.remove("tech_ultimate+.dat")end
--Update modeRanks
R=modeRanks
if R[1]then
local L=R
for i=1,#L do
L[Modes[i].name],L[i]=L[i]
for k,v in next,R do
if type(k)=="number"then
R[Modes[k].name],R[k]=R[k]
break
end
elseif R.master_adavnce then
end
if R.master_adavnce then
R.master_advance,R.master_adavnce=R.master_adavnce
end
if not text.modes[stat.lastPlay]then
stat.lastPlay="sprint_10"
end
--Update data file
S=stat
@@ -122,16 +129,8 @@ if S.version~=gameVersion then
TEXT.show(text.newBigVersion,640,200,30,"fly",.3)
newVersionLaunch=true
fs.remove("sprintPenta.dat")
fs.remove("master_adavnce.dat")
fs.remove("master_beginner.dat")
for name,M in next,Modes do
if M.score then
if modeRanks[name]==6 then
modeRanks[name]=0
end
else
modeRanks[name]=6
end
end
end
R,S=nil

View File

@@ -29,6 +29,7 @@ return{
P.modeData.point=min(P.modeData.point+16,80)
P.modeData.event=sectionName[int(P.modeData.point*.1)+1]
P:win("finish")
return true
end
end,
bg="aura",bgm="far",

View File

@@ -1,4 +1,4 @@
local int,rnd=math.floor,math.random
local int=math.floor
return{
color=color.magenta,
env={
@@ -14,12 +14,12 @@ return{
local t
if D.event<20 then
t=1500-30*D.event--1500~900
B[p]= {pos=rnd(4,7),amount=12,countdown=t,cd0=t,time=0,sent=false,lv=3}
B[p+1]= {pos=rnd(3,8),amount=10,countdown=t,cd0=t,time=0,sent=false,lv=4}
B[p]= {pos=P:RND(4,7),amount=12,countdown=t,cd0=t,time=0,sent=false,lv=3}
B[p+1]= {pos=P:RND(3,8),amount=10,countdown=t,cd0=t,time=0,sent=false,lv=4}
else
t=900-10*(D.event-20)--900~600
B[p]= {pos=rnd(10),amount=14,countdown=t,cd0=t,time=0,sent=false,lv=4}
B[p+1]= {pos=rnd(4,7),amount=8,countdown=t,cd0=t,time=0,sent=false,lv=5}
B[p]= {pos=P:RND(10),amount=14,countdown=t,cd0=t,time=0,sent=false,lv=4}
B[p+1]= {pos=P:RND(4,7),amount=8,countdown=t,cd0=t,time=0,sent=false,lv=5}
end
B.sum=B.sum+22
P.stat.recv=P.stat.recv+22
@@ -34,7 +34,7 @@ return{
end
end
end,
bg="game4",bgm="push",
bg="game4",bgm="way",
},
pauseLimit=true,
load=function()

View File

@@ -1,4 +1,4 @@
local int,rnd,min=math.floor,math.random,math.min
local int,min=math.floor,math.min
return{
color=color.lYellow,
env={
@@ -13,18 +13,18 @@ return{
local s,t
if D.event<10 then
t=800-10*D.event--800~700
B[p]= {pos=rnd(5,6),amount=9,countdown=t,cd0=t,time=0,sent=false,lv=3}
B[p+1]= {pos=rnd(4,7),amount=11,countdown=t,cd0=t+62,time=0,sent=false,lv=4}
B[p]= {pos=P:RND(5,6),amount=9,countdown=t,cd0=t,time=0,sent=false,lv=3}
B[p+1]= {pos=P:RND(4,7),amount=11,countdown=t,cd0=t+62,time=0,sent=false,lv=4}
s=20
elseif D.event<20 then
t=800-10*D.event--700~600
B[p]= {pos=rnd(3,8),amount=11,countdown=t,cd0=t,time=0,sent=false,lv=4}
B[p+1]= {pos=rnd(4,7),amount=13,countdown=t,cd0=t+62,time=0,sent=false,lv=5}
B[p]= {pos=P:RND(3,8),amount=11,countdown=t,cd0=t,time=0,sent=false,lv=4}
B[p+1]= {pos=P:RND(4,7),amount=13,countdown=t,cd0=t+62,time=0,sent=false,lv=5}
s=24
else
t=600-15*(min(D.event-20,10))--600~450
B[p]= {pos=rnd(2)*9-8,amount=14,countdown=t,cd0=t,time=0,sent=false,lv=5}
B[p+1]= {pos=rnd(3,8),amount=14,countdown=t+62,cd0=t,time=0,sent=false,lv=5}
B[p]= {pos=P:RND(2)*9-8,amount=14,countdown=t,cd0=t,time=0,sent=false,lv=5}
B[p+1]= {pos=P:RND(3,8),amount=14,countdown=t+62,cd0=t,time=0,sent=false,lv=5}
s=28
end
B.sum=B.sum+s

View File

@@ -7,7 +7,7 @@ return{
dropPiece=PLY.reach_winCheck,
freshLimit=10,
target=200,
bg="glow",bgm="newera",
bg="glow",bgm="reason",
},
pauseLimit=true,
load=function()

View File

@@ -10,7 +10,7 @@ return{
dropPiece=PLY.reach_winCheck,
freshLimit=15,
target=200,
bg="rgb",bgm="secret7th",
bg="rgb",bgm="reason",
},
pauseLimit=true,
load=function()

View File

@@ -11,7 +11,7 @@ return{
dropPiece=PLY.reach_winCheck,
freshLimit=15,
target=200,
bg="rgb",bgm="secret8th",
bg="rgb",bgm="reason",
},
pauseLimit=true,
load=function()

View File

@@ -11,7 +11,7 @@ return{
dropPiece=PLY.reach_winCheck,
freshLimit=15,
target=200,
bg="rgb",bgm="secret7th",
bg="rgb",bgm="way",
},
pauseLimit=true,
load=function()

View File

@@ -13,7 +13,7 @@ return{
dropPiece=PLY.reach_winCheck,
freshLimit=15,
target=100,
bg="none",bgm="secret7th",
bg="none",bgm="way",
},
pauseLimit=true,
load=function()

View File

@@ -1,4 +1,4 @@
local rnd,min=math.random,math.min
local min=math.random,math.min
local function check_c4w(P)
for i=1,#P.clearedRow do
P.field[#P.field+1]=freeRow.get(13)
@@ -35,7 +35,7 @@ return{
P.visTime[i]=freeRow.get(20)
for x=4,7 do F[i][x]=0 end
end
local r=rnd(6)
local r=P:RND(6)
if r==1 then F[1][5],F[1][4],F[2][4]=13,13,13
elseif r==2 then F[1][6],F[1][7],F[2][7]=13,13,13
elseif r==3 then F[1][4],F[2][4],F[2][5]=13,13,13

View File

@@ -1,4 +1,4 @@
local rnd,min=math.random,math.min
local min=math.min
local function check_c4w(P)
for i=1,#P.clearedRow do
P.field[#P.field+1]=freeRow.get(13)
@@ -33,7 +33,7 @@ return{
P.visTime[i]=freeRow.get(20)
for x=4,7 do F[i][x]=0 end
end
local r=rnd(6)
local r=P:RND(6)
if r==1 then F[1][5],F[1][4],F[2][4]=13,13,13
elseif r==2 then F[1][6],F[1][7],F[2][7]=13,13,13
elseif r==3 then F[1][4],F[2][4],F[2][5]=13,13,13

View File

@@ -1,4 +1,4 @@
local int,rnd=math.floor,math.random
local int=math.floor
return{
color=color.red,
env={
@@ -14,7 +14,7 @@ return{
if P.modeData.counter>=t then
P.modeData.counter=0
for _=1,4 do
P.atkBuffer[#P.atkBuffer+1]={pos=rnd(10),amount=1,countdown=5*t,cd0=5*t,time=0,sent=false,lv=2}
P.atkBuffer[#P.atkBuffer+1]={pos=P:RND(10),amount=1,countdown=5*t,cd0=5*t,time=0,sent=false,lv=2}
end
P.atkBuffer.sum=P.atkBuffer.sum+4
P.stat.recv=P.stat.recv+4

View File

@@ -1,4 +1,4 @@
local int,rnd=math.floor,math.random
local int=math.floor
return{
color=color.green,
env={
@@ -14,7 +14,7 @@ return{
if P.modeData.counter>=t then
P.modeData.counter=0
for _=1,3 do
P.atkBuffer[#P.atkBuffer+1]={pos=rnd(2,9),amount=1,countdown=2*t,cd0=2*t,time=0,sent=false,lv=1}
P.atkBuffer[#P.atkBuffer+1]={pos=P:RND(2,9),amount=1,countdown=2*t,cd0=2*t,time=0,sent=false,lv=1}
end
P.atkBuffer.sum=P.atkBuffer.sum+3
P.stat.recv=P.stat.recv+3

View File

@@ -1,4 +1,4 @@
local max,rnd=math.max,math.random
local max=math.max
return{
color=color.magenta,
env={
@@ -10,13 +10,13 @@ return{
local D=P.modeData
D.counter=D.counter+1
if D.counter>=max(90,180-D.event)then
P:garbageRise(10,1,rnd(10))
P:garbageRise(10,1,P:RND(10))
P.stat.recv=P.stat.recv+1
D.counter=0
D.event=D.event+1
end
end,
bg="game2",bgm="push",
bg="game2",bgm="way",
},
pauseLimit=true,
load=function()

View File

@@ -1,4 +1,4 @@
local max,rnd=math.max,math.random
local max=math.max
return{
color=color.lYellow,
env={
@@ -9,13 +9,13 @@ return{
local D=P.modeData
D.counter=D.counter+1
if D.counter>=max(30,80-.3*D.event)then
P:garbageRise(13+D.event%5,1,rnd(10))
P:garbageRise(13+D.event%5,1,P:RND(10))
P.stat.recv=P.stat.recv+1
D.counter=0
D.event=D.event+1
end
end,
bg="game2",bgm="secret7th",
bg="game2",bgm="shining terminal",
},
pauseLimit=true,
load=function()

View File

@@ -1,4 +1,4 @@
local rnd,min,rem=math.random,math.min,table.remove
local min,rem=math.min,table.remove
return{
color=color.red,
env={
@@ -88,7 +88,7 @@ return{
::END::
freeRow.discard(height)
P:getNext(res[rnd(#res)])
P:getNext(res[P:RND(#res)])
end
end,
target=100,dropPiece=PLY.reach_winCheck,

View File

@@ -1,8 +1,8 @@
local format,rnd=string.format,math.random
local format=string.format
local function check_rise(P)
if #P.clearedRow==0 then
for i=1,8-P.garbageBeneath do
P:garbageRise(13,1,rnd(10))
P:garbageRise(13,1,P:RND(10))
end
end
end
@@ -19,7 +19,7 @@ return{
load=function()
PLY.newPlayer(1,340,15)
for _=1,8 do
players[1]:garbageRise(13,1,rnd(10))
players[1]:garbageRise(13,1,P:RND(10))
end
end,
mesDisp=function(P,dx,dy)

View File

@@ -7,7 +7,7 @@ return{
target=100,dropPiece=PLY.reach_winCheck,
freshLimit=15,
ospin=false,
bg="rgb",bgm="infinite",
bg="rgb",bgm="newera",
},
pauseLimit=true,
load=function()

View File

@@ -7,7 +7,7 @@ return{
target=100,dropPiece=PLY.reach_winCheck,
freshLimit=15,
ospin=false,
bg="rgb",bgm="infinite",
bg="rgb",bgm="newera",
},
pauseLimit=true,
load=function()

View File

@@ -1,4 +1,4 @@
local int,rnd=math.floor,math.random
local int=math.floor
local ins=table.insert
local pc_drop={50,45,40,35,30,26,22,18,15,12}
local pc_lock={55,50,45,40,36,32,30}
@@ -11,7 +11,7 @@ local function task_PC(P)
P.modeData.counter=P.modeData.counter+1
if P.modeData.counter==26 then
local base=PCbase[P.modeData.type]
P:pushLine(base[rnd(#base)],P.modeData.symmetry)
P:pushLine(base[P:RND(#base)],P.modeData.symmetry)
return true
end
end
@@ -24,9 +24,9 @@ local function newPC(P)
if c<5 then P:lose()end
end
if #P.field==0 then
local type=PCtype[P.stat.pc]or rnd(2,3)
local L=PClist[type][rnd(#PClist[1])]
local symmetry=rnd()>.5
local type=PCtype[P.stat.pc]or P:RND(2,3)
local L=PClist[type][P:RND(#PClist[1])]
local symmetry=P:RND()>.5
P.modeData.type=type
P.modeData.symmetry=symmetry
P:pushNext(L,symmetry)

View File

@@ -1,4 +1,3 @@
local rnd=math.random
local PCbase=require("parts/PCbase")
local PClist=require("parts/PClist")
local PCtype={
@@ -17,7 +16,7 @@ local function task_PC(P)
P.modeData.counter=P.modeData.counter+1
if P.modeData.counter==26 then
local base=PCbase[P.modeData.type]
P:pushLine(base[rnd(#base)],P.modeData.symmetry)
P:pushLine(base[P:RND(#base)],P.modeData.symmetry)
return true
end
end
@@ -30,9 +29,9 @@ local function newPC(P)
if c<5 then P:lose()end
end
if #P.field==0 then
local type=PCtype[P.stat.pc]or rnd(2,3)
local L=PClist[type][rnd(#PClist[1])]
local symmetry=rnd()>.5
local type=PCtype[P.stat.pc]or P:RND(2,3)
local L=PClist[type][P:RND(#PClist[1])]
local symmetry=P:RND()>.5
P.modeData.type=type
P.modeData.symmetry=symmetry
P:pushNext(L,symmetry)

View File

@@ -25,20 +25,16 @@ return{
end,
score=function(P)return{P.stat.time,P.stat.piece}end,
scoreDisp=function(D)return toTime(D[1]).." "..D[2].." Pieces"end,
comp=function(a,b)return a[2]>b[2]or a[2]==b[2]and a[1]<b[1]end,
comp=function(a,b)return a[1]<b[1]or(a[1]==b[1] and a[2]<b[2])end,
getRank=function(P)
local T=P.stat.row
if T<5 then
return
elseif T<40 then
return 0
end
T=P.stat.time
if P.stat.row<40 then return end
local T=P.stat.time
return
T<=76 and 5 or
T<=90 and 4 or
T<=150 and 3 or
T<=260 and 2 or
1
T<=500 and 1 or
0
end,
}

View File

@@ -1,4 +1,4 @@
local max,rnd=math.max,math.random
local max=math.max
return{
color=color.cyan,
env={
@@ -8,7 +8,7 @@ return{
if not(P.control and SCN.cur=="play")then return end
P.modeData.counter=P.modeData.counter+1
if P.modeData.counter>=max(60,150-2*P.modeData.event)and P.atkBuffer.sum<4 then
P.atkBuffer[#P.atkBuffer+1]={pos=rnd(10),amount=1,countdown=30,cd0=30,time=0,sent=false,lv=1}
P.atkBuffer[#P.atkBuffer+1]={pos=P:RND(10),amount=1,countdown=30,cd0=30,time=0,sent=false,lv=1}
P.atkBuffer.sum=P.atkBuffer.sum+1
P.stat.recv=P.stat.recv+1
if P.modeData.event==45 then P:showTextF(text.maxspeed,0,-140,100,"appear",.6)end

View File

@@ -1,4 +1,4 @@
local max,rnd=math.max,math.random
local max=math.max
return{
color=color.magenta,
env={
@@ -11,9 +11,9 @@ return{
if P.modeData.counter>=max(60,180-2*P.modeData.event)and B.sum<15 then
B[#B+1]=
P.modeData.event%3<2 and
{pos=rnd(10),amount=1,countdown=0,cd0=0,time=0,sent=false,lv=1}
{pos=P:RND(10),amount=1,countdown=0,cd0=0,time=0,sent=false,lv=1}
or
{pos=rnd(10),amount=3,countdown=60,cd0=60,time=0,sent=false,lv=2}
{pos=P:RND(10),amount=3,countdown=60,cd0=60,time=0,sent=false,lv=2}
local R=(P.modeData.event%3<2 and 1 or 3)
B.sum=B.sum+R
P.stat.recv=P.stat.recv+R

View File

@@ -1,4 +1,4 @@
local max,rnd=math.max,math.random
local max=math.max
return{
color=color.red,
env={
@@ -9,7 +9,7 @@ return{
P.modeData.counter=P.modeData.counter+1
if P.modeData.counter>=max(60,150-P.modeData.event)and P.atkBuffer.sum<20 then
local t=max(60,90-P.modeData.event)
P.atkBuffer[#P.atkBuffer+1]={pos=rnd(10),amount=4,countdown=t,cd0=t,time=0,sent=false,lv=3}
P.atkBuffer[#P.atkBuffer+1]={pos=P:RND(10),amount=4,countdown=t,cd0=t,time=0,sent=false,lv=3}
P.atkBuffer.sum=P.atkBuffer.sum+4
P.stat.recv=P.stat.recv+4
if P.modeData.event==60 then P:showTextF(text.maxspeed,0,-140,100,"appear",.6)end
@@ -17,7 +17,7 @@ return{
P.modeData.event=P.modeData.event+1
end
end,
bg="glow",bgm="newera",
bg="glow",bgm="secret8th",
},
pauseLimit=true,
load=function()

View File

@@ -1,4 +1,4 @@
local max,rnd=math.max,math.random
local max=math.max
return{
color=color.green,
env={
@@ -10,10 +10,10 @@ return{
if P.modeData.counter>=max(90,180-2*P.modeData.event)and P.atkBuffer.sum<8 then
local d=P.modeData.event+1
P.atkBuffer[#P.atkBuffer+1]=
d%4==0 and{pos=rnd(10),amount=1,countdown=60,cd0=60,time=0,sent=false,lv=1}or
d%4==1 and{pos=rnd(10),amount=2,countdown=70,cd0=70,time=0,sent=false,lv=1}or
d%4==2 and{pos=rnd(10),amount=3,countdown=80,cd0=80,time=0,sent=false,lv=2}or
d%4==3 and{pos=rnd(10),amount=4,countdown=90,cd0=90,time=0,sent=false,lv=3}
d%4==0 and{pos=P:RND(10),amount=1,countdown=60,cd0=60,time=0,sent=false,lv=1}or
d%4==1 and{pos=P:RND(10),amount=2,countdown=70,cd0=70,time=0,sent=false,lv=1}or
d%4==2 and{pos=P:RND(10),amount=3,countdown=80,cd0=80,time=0,sent=false,lv=2}or
d%4==3 and{pos=P:RND(10),amount=4,countdown=90,cd0=90,time=0,sent=false,lv=3}
P.atkBuffer.sum=P.atkBuffer.sum+d%4+1
P.stat.recv=P.stat.recv+d%4+1
if P.modeData.event==45 then P:showTextF(text.maxspeed,0,-140,100,"appear",.6)end

View File

@@ -1,4 +1,4 @@
local max,rnd=math.max,math.random
local max=math.max
return{
color=color.lYellow,
env={
@@ -12,10 +12,10 @@ return{
if P.modeData.counter>=max(300,600-10*P.modeData.event)and P.atkBuffer.sum<20 then
local t=max(300,480-12*P.modeData.event)
local p=#P.atkBuffer+1
P.atkBuffer[p] ={pos=rnd(10),amount=4,countdown=t,cd0=t,time=0,sent=false,lv=2}
P.atkBuffer[p+1]={pos=rnd(10),amount=4,countdown=t,cd0=t,time=0,sent=false,lv=3}
P.atkBuffer[p+2]={pos=rnd(10),amount=6,countdown=1.2*t,cd0=1.2*t,time=0,sent=false,lv=4}
P.atkBuffer[p+3]={pos=rnd(10),amount=6,countdown=1.5*t,cd0=1.5*t,time=0,sent=false,lv=5}
P.atkBuffer[p] ={pos=P:RND(10),amount=4,countdown=t,cd0=t,time=0,sent=false,lv=2}
P.atkBuffer[p+1]={pos=P:RND(10),amount=4,countdown=t,cd0=t,time=0,sent=false,lv=3}
P.atkBuffer[p+2]={pos=P:RND(10),amount=6,countdown=1.2*t,cd0=1.2*t,time=0,sent=false,lv=4}
P.atkBuffer[p+3]={pos=P: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
P.stat.recv=P.stat.recv+20
if P.modeData.event==31 then P:showTextF(text.maxspeed,0,-140,100,"appear",.6)end

View File

@@ -15,7 +15,7 @@ return{
freshLimit=15,
target=200,
dropPiece=tech_check_hard,
bg="matrix",bgm="secret8th",
bg="matrix",bgm="newera",
},
load=function()
PLY.newPlayer(1,340,15)

View File

@@ -15,7 +15,7 @@ return{
freshLimit=15,
target=200,
dropPiece=tech_check_easy,
bg="matrix",bgm="secret8th",
bg="matrix",bgm="newera",
},
load=function()
PLY.newPlayer(1,340,15)

View File

@@ -15,7 +15,7 @@ return{
freshLimit=15,
target=200,
dropPiece=tech_check_hard,
bg="matrix",bgm="secret7th",
bg="matrix",bgm="push",
},
load=function()
PLY.newPlayer(1,340,15)

View File

@@ -15,7 +15,7 @@ return{
freshLimit=15,
target=200,
dropPiece=tech_check_easy,
bg="matrix",bgm="secret7th",
bg="matrix",bgm="push",
},
load=function()
PLY.newPlayer(1,340,15)

View File

@@ -15,7 +15,7 @@ return{
drop=1e99,lock=1e99,
target=200,
dropPiece=tech_check_hard,
bg="matrix",bgm="newera",
bg="matrix",bgm="way",
},
load=function()
PLY.newPlayer(1,340,15)

View File

@@ -15,7 +15,7 @@ return{
drop=1e99,lock=1e99,
target=200,
dropPiece=tech_check_easy,
bg="matrix",bgm="newera",
bg="matrix",bgm="way",
},
load=function()
PLY.newPlayer(1,340,15)

View File

@@ -16,7 +16,7 @@ local Timer=love.timer.getTime
-- 6~10:hD,sD,H,A,R,
-- 11~13:LL,RR,DD
local blockPos={4,4,4,4,4,5,4}
local scs={{1,2},{1,2},{1,2},{1,2},{1,2},{1.5,1.5},{0.5,2.5}}
local scs={{0,1},{0,1},{0,1},{0,1},{0,1},{.5,.5},{-.5,1.5}}
-------------------------------------------------Cold clear
local CCblockID={4,3,6,5,1,2,0}
if system=="Windows"then

View File

@@ -6,6 +6,25 @@ local sub,find=string.sub,string.find
local char,byte=string.char,string.byte
local ins,rem=table.insert,table.remove
local default_setting={
"das","arr",
"sddas","sdarr",
"ihs","irs","ims",
"maxNext",
"swap",
-- "face",
}
local function copyGameSetting()
local S={face={}}
for _,v in next,default_setting do
S[v]=setting[v]
end
for i=1,25 do
S.face[i]=setting.face[i]
end
return S
end
function destroyPlayers()
for i=#players,1,-1 do
local P=players[i]
@@ -161,6 +180,7 @@ function mergeStat(stat,delta)
end
end
end
function randomTarget(P)--Return a random opponent for P
if #players.alive>1 then
local R
@@ -229,13 +249,14 @@ function royaleLevelup()
local P=players.alive[i]
P.gameEnv.drop=int(P.gameEnv.drop*.3)
if P.gameEnv.drop==0 then
P.curY=P.y_img
P.curY=P.imgY
P.gameEnv._20G=true
if P.AI_mode=="CC"then CC_switch20G(P)end
end
end
end
end
function pauseGame()
if not SCN.swapping then
restartCount=0--Avoid strange darkness
@@ -267,6 +288,10 @@ function loadGame(M,ifQuickPlay)
SFX.play("enter")
end
function resetGameData()
if players[1]and not game.replaying then
mergeStat(stat,players[1].stat)
end
game.frame=150-setting.reTime*15
game.result=false
game.pauseTime=0
@@ -276,6 +301,7 @@ function resetGameData()
game.warnLVL=0
game.recording=true
game.replaying=false
game.setting=copyGameSetting()
game.rec={}
math.randomseed(tm.getTime())
game.seed=rnd(261046101471026)
@@ -309,8 +335,14 @@ function resetGameData()
collectgarbage()
end
function resetPartGameData(replaying)
if players[1]and not game.replaying then
mergeStat(stat,players[1].stat)
end
game.result=false
game.garbageSpeed=1
game.warnLVL0=0
game.warnLVL=0
if replaying then
game.frame=0
game.recording=false
@@ -321,6 +353,7 @@ function resetPartGameData(replaying)
game.pauseCount=0
game.recording=true
game.replaying=false
game.setting=copyGameSetting()
game.rec={}
math.randomseed(tm.getTime())
game.seed=rnd(1046101471,2662622626)

View File

@@ -4,6 +4,7 @@ if setting.lang==1 or setting.lang==2 then
"ZS JL T O I",
"VVVVVV好玩!",
"uid:225238922",
"tetralegends也很好玩!",
"tetr.js也很好玩!",
"tetr.io也很好玩!",
"Techminohaowan",
@@ -13,9 +14,10 @@ if setting.lang==1 or setting.lang==2 then
"osu好玩!",
"O spin Triple!",
"nullpomino也很好玩!",
"Naki 可爱",
"Naki 可爱!",
"Miya:喵!",
"Miya 可爱!",
"Lua天下第一",
"LrL RlR LLr RRl RRR LLL FFF RfR RRf rFF",
"Let-The-Bass-Kick!",
"l-=-1",
@@ -36,7 +38,6 @@ if setting.lang==1 or setting.lang==2 then
"注意到\"旋转\"到底对方块做了些什么吗?",
"有疑问? 先看设置有没有你想要的",
"有建议的话可以把信息反馈给作者~",
"音乐都是瞎写的,觉得不好听就把BGM关了罢",
"学会使用两个旋转键, 三个更好",
"享受特色旋转系统!",
"无聊翻翻设置是好习惯",
@@ -56,6 +57,7 @@ if setting.lang==1 or setting.lang==2 then
"每个虚拟按键都可以隐藏/显示",
"每个块的出现方向可以自定义",
"没专业美术,程序员审美警告",
"没学过编曲,音乐都是自己凭感觉写的,觉得不好听就设置里关了吧",
"联网还没做呢, 别急",
"键位是可以自定义的",
"合群了就会消失, 但是消失不代表没有意义",
@@ -65,8 +67,9 @@ if setting.lang==1 or setting.lang==2 then
"低帧率会降低游戏体验",
"戴上耳机以获得最佳体验",
"大满贯10连击消四全清!",
"打好块没有捷径,多练",
"车车人在此",
"茶娘可爱",
"茶娘 可爱!",
"草(日本语)",
"不要在上课时玩游戏!",
"不要盯着bug不放",
@@ -75,6 +78,7 @@ if setting.lang==1 or setting.lang==2 then
"别问游戏名怎么取的,问就是随便想的",
"本游戏难度上限很高, 做好心理准备",
"本游戏可不是休闲游戏",
"报时机器人:新的一天开始了",
"626r/s",
"40行世界纪录:15.654s",
"4+4+4+4+2+2+1=17",
@@ -90,6 +94,7 @@ if setting.lang==1 or setting.lang==2 then
"<方块研究所>有一个Nspire-CX版本!",
"↑↑↓↓←→←→BABA",
"(RUR'U')R'FR2U'R'U'(RUR'F')",
-- "Z酱 可爱!",
}
elseif setting.lang==3 then
L={
@@ -107,6 +112,7 @@ elseif setting.lang==3 then
"This game can be very hard,be mentally perpared",
"Tetris journey has network battle!",
"Terraria is fun!",
"Tetralegends is fun!",
"Techmino=Technique+Tetromino",
"Techmino is so fun!",
"Techmino has a Nspire-CX edition!",
@@ -117,7 +123,7 @@ elseif setting.lang==3 then
"REGRET!!",
"Powered by love2d",
"Playing too much = taking drugs",
"osu is fun!",
"OSU is fun!",
"Only offline game now",
"OHHHHHHHHHHHHHH",
"O spin triple!",
@@ -127,13 +133,13 @@ elseif setting.lang==3 then
"Miya so cute!",
"Minesweeper is fun!",
"Minecraft is fun!",
"Lua No.1",
"LrL RlR LLr RRl RRR LLL FFF RfR RRf rFF",
"lower fps causes lower game experience",
"Lower fps causes lower game experience",
"Let-The-Bass-Kick!",
"l-=-1",
"Is B2B2B2B possible?",
"Initial Rotation etc. can save your life",
"iced so bully",
"Hello world!",
"Headphones for better experience",
"Have you noticed what does \"rotating\" do to block?",
@@ -146,7 +152,7 @@ elseif setting.lang==3 then
"DO NOT PRESS F10",
"Do not play game in class!",
"Disappearing doesn't mean useless",
"diao so bully",
"Diao so bully",
"COOL!!",
"CLASSIC SEXY RUSSIAN BLOCKS",
"BT cannon=beta",
@@ -159,7 +165,7 @@ elseif setting.lang==3 then
"Also try Tetr.io!",
"Also try Jstris!",
"Also try Cultris II!",
"Also try Bullpomino!",
"Also try Nullpomino!",
"ALLSPIN!",
"少女祈禱中",
"40L WR: 15.654s",
@@ -186,5 +192,75 @@ elseif setting.lang==4 then
s=s..L[math.random(#L)]
end
return s
elseif setting.lang==5 then
local R=math.random()
if R<.05 then
local time={
"大半夜的在这干啥呢?不睡觉是会猝死的",
"大半夜的在这干啥呢?不睡觉是会猝死的",
"现在打块你是认真的?",
"现在打块你是认真的?",
"早起是好的,但是你不应该打块",
"早起是好的,但是你不应该打块",
"早饭吃好了?",
"早饭吃好了?",
"九点多了,没自己的事情要做?",
"十点多了,没自己的事情要做?",
"十一点多了,午饭有的吃么",
"十二点多了,午饭有的吃么",
"累了累了,现在不想说你",
"累了累了,现在不想说你",
"累了累了,现在不想说你",
"累了累了,现在不想说你",
"累了累了,现在不想说你",
"晚饭吃好了?",
"晚饭吃好了?",
"累了累了,现在不想说你",
"累了累了,现在不想说你",
"好睡了,作息健康活得久",
"大半夜的在这干啥呢?不睡觉是会猝死的",
}
return time[os.date("%H")]
elseif true or R<.1 then
local int=math.floor
L={
"平均"..int(stat.row/stat.time*60).."LPM,那可真强呢",
"平均"..int(stat.atk/stat.time*60).."APM,好厉害哦",
"平均"..(int(stat.atk/stat.row*10)*.1).."效,你看这数据能看么",
"平均"..(int(stat.atk/stat.row*10)*.1).."效,我就不说你多菜了",
"才玩"..stat.game.."把,跟几十万局的没法比",
"才玩"..stat.game.."把,玩了不下几万局的人可不在少数",
"才玩了"..int(stat.time/3600).."小时,人家总时长是你不知道多少倍",
"才玩了"..int(stat.time/3600).."小时,别人总时长跟你都不在一个数量级",
}
else
L={
"Diao?上次被我c4w秒了的那人?",
"隐形难吗?那个节目上的谁,水平那么菜也打得还行,就是你菜",
"一口一个wtcl还不赶紧去练,你是不思进取还是不想好好说话?",
"我一个滑铲就挖了个11renPC",
"我曾经在极度愤怒的时候15秒消了40行",
"天天F3F3,怕别人不知道你菜?",
"天天催更催更,你咋不来帮忙开发啊,真以为作者很强催催啥都有?",
"设置都看过一遍了吗?明明都能调还嫌这嫌那,可牛逼了您",
"人只用一只手都能玩,你呢?",
"没那水平别天天整什么花里胡哨的,人玩几年你想几天赶上?",
"满口PCDT信天翁,还会点别的么?",
"叫你多练消四不听,现在要速度没速度,spin打完地形一塌糊涂,开心了?",
"叫你多练就多练,想着几天变神仙,当自己是谁?",
"还搁这玩手机呢,作业做完了?",
"除了雨宫太阳你还认识谁?Jonas知道吗?Ajanba听过吗?",
"不会吧不会吧,真的还有人不能随手Tspin?",
"60lpm?拍硬降刷的吧",
"4pps不是人均水平?",
"40行还要40多秒,就这?",
"20G很难?是个人都能玩吧",
"20连pc不是随手?",
"100apm?定式刷的吧",
"0202年了,还在玩这种小孩子玩的游戏?",
"天天卖弱,你一定把把150apm吧?",
"别会个c4w就以为自己多强,这是基本功罢了",
}
end
end
return L[math.random(#L)]

View File

@@ -99,14 +99,14 @@ local TRS={
},--J
{},--L
{
[01]={{-1, 0},{-1, 1},{ 0,-2},{-1,-2},{-1,-1}},
[10]={{ 1, 0},{ 1,-1},{ 0, 2},{ 1, 2},{ 0,-1},{ 1, 1}},
[03]={{ 1, 0},{ 1, 1},{ 0,-2},{ 1,-2}},
[01]={{-1, 0},{-1, 1},{ 0,-2},{-1,-2},{ 0, 1}},
[10]={{ 1, 0},{ 1,-1},{ 0, 2},{ 1, 2},{ 0,-1}},
[03]={{ 1, 0},{ 1, 1},{ 0,-2},{ 1,-2},{ 0, 1}},
[30]={{-1, 0},{-1,-1},{ 0, 2},{-1, 2},{ 0,-1}},
[12]={{ 1, 0},{ 1,-1},{ 0,-1},{-1,-1},{ 0, 2},{ 1, 2}},
[21]={{-1, 0},{ 0,-2},{-1,-2},{ 1, 1}},
[21]={{-1, 0},{ 0,-2},{-1,-2},{ 1, 1},{ 1, 0}},
[32]={{-1, 0},{-1,-1},{ 0,-1},{ 1,-1},{ 0, 2},{-1, 2}},
[23]={{ 1, 0},{ 0,-2},{ 1,-2},{-1, 1}},
[23]={{ 1, 0},{ 0,-2},{ 1,-2},{-1, 1},{-1, 0}},
[02]={{-1, 0},{ 1, 0},{ 0, 1}},
[20]={{ 1, 0},{-1, 0},{ 0,-1}},
[13]={{ 0,-1},{ 0, 1},{ 1, 0},{ 0,-2},{ 0, 2}},
@@ -114,10 +114,10 @@ local TRS={
},--T
function(P,d)
if P.human then SFX.fieldPlay("rotate",nil,P)end
if P.gameEnv.easyFresh then P:freshLockDelay()end
P:freshLockDelay()
if not P.gameEnv.ospin then return end
local x,y=P.curX,P.curY
if y==P.y_img and((P:solid(x-1,y)or P:solid(x-1,y+1)))and(P:solid(x+2,y)or P:solid(x+2,y+1))then
if y==P.imgY and((P:solid(x-1,y)or P:solid(x-1,y+1)))and(P:solid(x+2,y)or P:solid(x+2,y+1))then
local D=P.spinSeq%100*10+d
P.spinSeq=D
if D<100 then return end
@@ -186,23 +186,23 @@ local TRS={
{
[01]={{-1, 0},{ 1, 0},{-1, 1},{ 0,-2},{ 0,-3}},
[10]={{ 1, 0},{ 1,-1},{-1, 0},{ 0, 2},{ 0, 3}},
[03]={{ 1, 0},{ 1,-1}, { 0, 1},{ 0,-2},{ 0,-3}},
[30]={{-1, 0},{-1, 1},{ 1, 0},{ 0,-1},{ 0, 2},{ 0, 3}},
[03]={{ 1, 0},{ 1,-1},{ 0, 1},{ 0,-2},{ 0,-3}},
[30]={{-1, 1},{ 1, 0},{ 0,-1},{ 0, 2},{ 0, 3}},
[12]={{ 1, 0},{ 0,-1},{-1, 0},{ 0, 2}},
[21]={{-1, 0},{ 0, 1},{ 1, 0},{ 0,-2}},
[32]={{-1, 0},{-1, 1},{ 0, 1},{ 0,-1},{ 1, 0},{ 0, 2},{-2, 0}},
[23]={{ 1, 0},{ 1,-1},{ 0,-1},{ 0, 1},{-1, 0},{ 0,-2},{ 2, 0}},
[02]={{ 1, 0},{-1, 0},{ 0, 1}},
[20]={{-1, 0},{ 1, 0},{ 0,-1}},
[13]={{ 0,-1},{ 1, 0},{ 0, 1}},
[31]={{ 0,-1},{-1, 0},{ 0, 1}},
[32]={{-1, 0},{ 0, 1},{-1, 1},{ 1, 0},{ 0, 2},{-2, 0}},
[23]={{ 1, 0},{ 1,-1},{ 0,-1},{-1, 0},{ 0,-2},{ 2, 0}},
[02]={{ 1, 0},{-1, 0},{-1,-1}},
[20]={{-1, 0},{ 1, 0},{ 1, 1}},
[13]={{ 0,-1},{-1, 1},{ 0, 1}},
[31]={{ 0,-1},{ 1,-1},{ 0, 1}},
},--F
{},--E
{
[01]={{ 0,-1},{-1,-1},{ 1,-1},{ 1, 0},{ 1,-3},{-1, 0},{ 0, 2},{-1, 2}},
[10]={{ 1, 0},{ 0,-1},{-1,-1},{ 0,-2},{ 0,-3},{ 1,-2},{ 0, 1}},
[01]={{ 0,-1},{-1,-1},{ 1, 1},{ 1, 0},{ 1,-3},{-1, 0},{ 0, 2},{-1, 2}},
[10]={{ 1, 0},{ 0,-1},{-1,-1},{ 0,-2},{-1, 1},{ 0,-3},{ 1,-2},{ 0, 1}},
[03]={{ 0,-1},{ 1,-1},{-1,-1},{-1, 0},{-1,-3},{ 1, 0},{ 0, 2},{ 1, 2}},
[30]={{-1, 0},{ 0,-1},{ 1,-1},{ 0,-2},{ 0,-3},{-1,-2},{ 0, 1}},
[30]={{-1, 0},{ 0,-1},{ 1,-1},{ 0,-2},{ 1, 1},{ 0,-3},{-1,-2},{ 0, 1}},
[12]={{ 1, 0},{-1, 0},{ 0,-2},{ 0,-3},{ 0, 1},{-1, 1}},
[21]={{ 1,-1},{-1, 0},{ 1, 0},{ 0,-1},{ 0, 2},{ 0, 3}},
[32]={{-1, 0},{ 1, 0},{ 0,-2},{ 0,-3},{ 0, 1},{ 1, 1}},
@@ -213,10 +213,10 @@ local TRS={
[31]={{-1, 0},{ 1, 1},{ 2, 0}},
},--T5
{
[01]={{-1, 0},{-1, 1},{ 0,-2},{-1,-1},{-1,-2}},
[10]={{ 1, 0},{ 1,-1}},
[03]={{ 1, 0},{ 1, 1},{ 0,-2},{ 1,-1},{ 1,-2}},
[30]={{-1, 0},{-1,-1}},
[01]={{-1, 0},{-1, 1},{ 0,-2},{-1,-2},{-1,-3}},
[10]={{ 1, 0},{ 1,-1},{ 0, 2},{ 1, 2},{ 1, 3}},
[03]={{ 1, 0},{ 1, 1},{ 0,-2},{ 1,-2},{ 1,-3}},
[30]={{-1, 0},{-1,-1},{ 0,-2},{-1, 2},{-1, 3}},
[12]={{ 1, 0},{ 1,-1},{ 1, 1}},
[21]={{-1,-1},{-1, 1},{-1,-1}},
[32]={{-1, 0},{-1,-1},{-1, 1}},
@@ -256,7 +256,7 @@ local TRS={
},--W
function(P,d)
if P.human then SFX.fieldPlay("rotate",nil,P)end
if P.gameEnv.easyFresh then P:freshLockDelay()end
P:freshLockDelay()
local iki=XspinList[d]
for test=1,#iki do
local x,y=P.curX+iki[test][1],P.curY+iki[test][2]

View File

@@ -199,7 +199,7 @@ drawableText={
replaying=T(20),
next=T(40),hold=T(40),
win=T(120),finish=T(120),
lose=T(120),pause=T(120),
gameover=T(100),pause=T(120),
custom=T(80),sequence=T(80),
setting_game=T(80),setting_video=T(80),setting_sound=T(80),

View File

@@ -1,4 +1,5 @@
local gc=love.graphics
local mt=love.math
local Timer=love.timer.getTime
local int,ceil,abs,rnd,max,min=math.floor,math.ceil,math.abs,math.random,math.max,math.min
local ins,rem=table.insert,table.remove
@@ -311,6 +312,7 @@ local function Pupdate_alive(P,dt)
end end
end
--Moving pressed
if P.movDir~=0 then
local das,arr=P.gameEnv.das,P.gameEnv.arr
local mov=P.moving
@@ -372,6 +374,7 @@ local function Pupdate_alive(P,dt)
P.moving=mov
end
--Drop pressed
if P.keyPressing[7]and not P.keyPressing[9]then
local d=P.downing-P.gameEnv.sddas
P.downing=P.downing+1
@@ -390,6 +393,8 @@ local function Pupdate_alive(P,dt)
else
P.downing=0
end
--Falling animation
if P.falling>=0 then
P.falling=P.falling-1
if P.falling>=0 then
@@ -400,33 +405,40 @@ local function Pupdate_alive(P,dt)
P.clearingRow={}
end
end
--Try spawn new block
if not P.control then goto stop end
if P.waiting==0 then P:popNext()end
if P.waiting>=0 then
P.waiting=P.waiting-1
goto stop
end
--Natural block falling
if P.cur then
if P.curY~=P.y_img then
if P.curY~=P.imgY then
local D=P.dropDelay
if D>1 then
P.dropDelay=D-1
goto stop
end
if D==1 then
P.curY=P.curY-1
else
local _=P.curY-P.y_img--Max fall dist
local _=P.curY-P.imgY--Max fall dist
D=1/D--Fall dist
if D<_ then
P.curY=P.curY-D
assert(P.curY==int(P.curY),"y:"..P.curY.." fall:"..D.." D_env:"..P.gameEnv.drop)
-- assert(P.curY==int(P.curY),"y:"..P.curY.." fall:"..D.." D_env:"..P.gameEnv.drop)
else
P.curY=P.y_img
P.curY=P.imgY
end
end
P:freshMinY()
P.spinLast=false
if P.y_img~=P.curY then
if P.imgY~=P.curY then
P.dropDelay=P.gameEnv.drop
elseif P.AI_mode=="CC"then
CC_updateField(P)
@@ -434,9 +446,6 @@ local function Pupdate_alive(P,dt)
CC_switch20G(P)
end
end
if P.freshTime<=P.gameEnv.freshLimit then
P.lockDelay=P.gameEnv.lock
end
else
P.lockDelay=P.lockDelay-1
if P.lockDelay>=0 then goto stop end
@@ -620,12 +629,12 @@ local function Pdraw_norm(P)
gc.setColor(1,1,1,.3)
for i=1,P.r do for j=1,P.c do
if P.cur.bk[i][j]then
drawPixel(i+P.y_img-1,j+P.curX-1,curColor)
drawPixel(i+P.imgY-1,j+P.curX-1,curColor)
end
end end
end
local dy=P.gameEnv.smooth and P.y_img~=P.curY and (min(P.dropDelay,1e99)/P.gameEnv.drop-1)*30 or 0
local dy=P.gameEnv.smooth and P.imgY~=P.curY and (min(P.dropDelay,1e99)/P.gameEnv.drop-1)*30 or 0
gc.translate(0,-dy)
local trans=P.lockDelay/P.gameEnv.lock
if P.gameEnv.block then
@@ -655,12 +664,12 @@ local function Pdraw_norm(P)
--Rotate center
if P.gameEnv.center then
gc.setColor(1,1,1,trans)
local x=30*(P.curX+P.sc[2]-1)-15
gc.draw(IMG.spinCenter,x,600-30*(P.curY+P.sc[1]-1)+15,nil,nil,nil,4,4)
local x=30*(P.curX+P.sc[2])-15
gc.draw(IMG.spinCenter,x,600-30*(P.curY+P.sc[1])+15,nil,nil,nil,4,4)
if P.gameEnv.ghost then
gc.translate(0,dy)
gc.setColor(1,1,1,.5)
gc.draw(IMG.spinCenter,x,600-30*(P.y_img+P.sc[1]-1)+15,nil,nil,nil,4,4)
gc.draw(IMG.spinCenter,x,600-30*(P.imgY+P.sc[1])+15,nil,nil,nil,4,4)
goto E
end
end
@@ -675,6 +684,16 @@ local function Pdraw_norm(P)
gc.setColor(P.frameColor)
gc.rectangle("line",-1,-11,302,612)--Boarder
--LockDelay indicator
if P.lockDelay>=0 then
gc.rectangle("fill",0,602,300*P.lockDelay/P.gameEnv.lock,6)--Lock delay indicator
end
_=10
for i=1,min(P.gameEnv.freshLimit-P.freshTime,15)do
gc.circle("fill",_,615,5)
_=_+20
end
--Buffer line
local h=0
for i=1,#P.atkBuffer do
@@ -914,7 +933,7 @@ local function Pdraw_demo(P)
gc.setColor(1,1,1,.3)
for i=1,P.r do for j=1,P.c do
if P.cur.bk[i][j]then
drawPixel(i+P.y_img-1,j+P.curX-1,curColor)
drawPixel(i+P.imgY-1,j+P.curX-1,curColor)
end
end end
@@ -994,7 +1013,7 @@ end
function player.createBeam(P,R,send,time,target,color,clear,spin,combo)
local x1,y1,x2,y2
if P.small then x1,y1=P.centerX,P.centerY
else x1,y1=P.x+(30*(P.curX+P.sc[2]-1)-30+15+150)*P.size,P.y+(600-30*(P.curY+P.sc[1]-1)+15+70)*P.size
else x1,y1=P.x+(30*(P.curX+P.sc[2])-30+15+150)*P.size,P.y+(600-30*(P.curY+P.sc[1])+15+70)*P.size
end
if R.small then x2,y2=R.centerX,R.centerY
else x2,y2=R.x+308*R.size,R.y+450*R.size
@@ -1064,10 +1083,9 @@ end
--------------------------</FX>--------------------------
--------------------------<Method>--------------------------
function player.RND(P,n)
local _=P.randomSeed
P.randomSeed=int(_/2.626+626262626)
return _%n+1
function player.RND(P,a,b)
local R=P.randGen
return R:random(a,b)
end
local function getNewStatTable()
@@ -1138,7 +1156,7 @@ function player.attack(P,R,send,time,...)
B[i+1]=B[i]
end
B[k]={
pos=rnd(10),
pos=P:RND(10),
amount=send,
countdown=time,
cd0=time,
@@ -1181,7 +1199,7 @@ function player.garbageRise(P,color,amount,pos)
P.fieldBeneath=P.fieldBeneath+amount*30
P.curY=P.curY+amount
P.garbageBeneath=P.garbageBeneath+amount
P.y_img=P.y_img+amount
P.imgY=P.imgY+amount
for i=1,#P.clearingRow do
P.clearingRow[i]=P.clearingRow[i]+amount
end
@@ -1215,7 +1233,7 @@ function player.pushLine(P,L,mir)
end
P.fieldBeneath=P.fieldBeneath+120
P.curY=P.curY+#L
P.y_img=P.y_img+#L
P.imgY=P.imgY+#L
P:freshgho()
end
function player.pushNext(P,L,mir)
@@ -1273,34 +1291,57 @@ function player.changeAtk(P,R)
end
function player.freshgho(P)
if not P.cur then return end
P.y_img=min(#P.field+1,P.curY)
P.imgY=min(#P.field+1,P.curY)
if P.gameEnv._20G or P.keyPressing[7]and P.gameEnv.sdarr==0 then
while not P:ifoverlap(P.cur.bk,P.curX,P.y_img-1)do
P.y_img=P.y_img-1
local _=P.imgY
--Move ghost to bottom
while not P:ifoverlap(P.cur.bk,P.curX,P.imgY-1)do
P.imgY=P.imgY-1
end
--Cancel spinLast
if _~=P.imgY then
P.spinLast=false
end
if P.curY>P.y_img then
--Create FX if dropped
if P.curY>P.imgY then
if P.gameEnv.dropFX then
P:createDropFX(P.curX,P.curY+1,P.curX+P.c-1,P.y_img+P.r-1)
P:createDropFX(P.curX,P.curY+1,P.curX+P.c-1,P.imgY+P.r-1)
end
if P.gameEnv.shakeFX then
P.fieldOff.vy=P.gameEnv.shakeFX*.5
end
P.curY=P.y_img
P.curY=P.imgY
end
else
while not P:ifoverlap(P.cur.bk,P.curX,P.y_img-1)do
P.y_img=P.y_img-1
while not P:ifoverlap(P.cur.bk,P.curX,P.imgY-1)do
P.imgY=P.imgY-1
end
end
end
function player.freshLockDelay(P)
if P.lockDelay<P.gameEnv.lock then
P.dropDelay=P.gameEnv.drop
P.freshTime=P.freshTime+1
if P.freshTime<=P.gameEnv.freshLimit then
P.lockDelay=P.gameEnv.lock
--Return when fall-fresh but no fall
if not P.gameEnv.easyFresh and P.curY>=P.minY then
return
end
local d,d0=P.lockDelay,P.gameEnv.lock
if d<d0 and(P.freshTime<P.gameEnv.freshLimit or P.curY<P.minY)then
if P.lockDelay<P.gameEnv.lock then
P.dropDelay=P.gameEnv.drop
end
P.freshTime=P.freshTime+1
P.lockDelay=min(d+d0*.6,d0)
end
end
function player.freshMinY(P)
if P.curY<P.minY then
P.freshTime=max(P.freshTime-1,0)
P.minY=P.curY
P.lockDelay=P.gameEnv.lock
end
end
function player.lock(P)
@@ -1329,20 +1370,24 @@ function player.spin(P,d,ifpre)
SFX.fieldPlay(ifpre and"prerotate"or "rotate",nil,P)
return
end
for test=1,P.freshTime<=1.2*P.gameEnv.freshLimit and #iki or 1 do
for test=1,#iki do
local x,y=ix+iki[test][1],iy+iki[test][2]
if not P:ifoverlap(icb,x,y)then
ix=x;iy=y
if not P:ifoverlap(icb,x,y)and(P.freshTime<=P.gameEnv.freshLimit or iki[test][2]<0)then
ix,iy=x,y
if P.gameEnv.dropFX then
P:createDropFX(P.curX,P.curY+P.r-1,P.curX+P.c-1,P.curY)
end
local y0=P.curY
P.curX,P.curY,P.dir=ix,iy,idir
P.sc,P.cur.bk=scs[P.cur.id][idir],icb
P.r,P.c=ir,ic
P.spinLast=test==2 and 0 or 1
if not ifpre then P:freshgho()end
if P.gameEnv.easyFresh or y0>P.curY then P:freshLockDelay()end
P:freshLockDelay()
P:freshMinY()
if iki[test][2]>0 then
P.freshTime=P.freshTime+1
end
if P.human then
SFX.fieldPlay(ifpre and"prerotate"or P:ifoverlap(P.cur.bk,P.curX,P.curY+1)and P:ifoverlap(P.cur.bk,P.curX-1,P.curY)and P:ifoverlap(P.cur.bk,P.curX+1,P.curY)and"rotatekick"or"rotate",nil,P)
end
@@ -1365,18 +1410,37 @@ function player.resetBlock(P)
P.curX=int(6-P.c*.5)
local y=21+ceil(P.fieldBeneath/30)
P.curY=y
P.minY=y+sc[2]
local _=P.keyPressing
--IMS
if P.gameEnv.ims and(P.keyPressing[1]and P.movDir==-1 or P.keyPressing[2]and P.movDir==1)and P.moving>=P.gameEnv.das then
if P.gameEnv.ims and(_[1]and P.movDir==-1 or _[2]and P.movDir==1)and P.moving>=P.gameEnv.das then
local x=P.curX+P.movDir
if not P:ifoverlap(C.bk,x,y)then
P.curX=x
end
end
--IRS
if P.gameEnv.irs then
if _[5]then
P:spin(2,true)
else
if _[3]then
if _[4]then
P:spin(2,true)
else
P:spin(1,true)
end
elseif _[4]then
P:spin(3,true)
end
end
end
--Spawn SFX
if P.human and id<8 then
SFX.play("spawn_"..id,setting.spawn,nil,true)
SFX.fplay("spawn_"..id,setting.spawn)
end
end
function player.hold(P,ifpre)
@@ -1451,8 +1515,8 @@ function player.popNext(P)--Pop next queue to hand
BOT.addNext(P.AI_bot,CCblockID[next.id])
end
end
local _=P.keyPressing
--IHS
if _[8]and P.gameEnv.hold and P.gameEnv.ihs then
P:hold(true)
@@ -1463,23 +1527,6 @@ function player.popNext(P)--Pop next queue to hand
P.dropDelay,P.lockDelay,P.freshTime=P.gameEnv.drop,P.gameEnv.lock,0
--IRS
if P.gameEnv.irs then
if _[5]then
P:spin(2,true)
else
if _[3]then
if _[4]then
P:spin(2,true)
else
P:spin(1,true)
end
elseif _[4]then
P:spin(3,true)
end
end
end
if P.cur then
if P:ifoverlap(P.cur.bk,P.curX,P.curY)then P:lock()P:lose()end
P:freshgho()
@@ -1509,7 +1556,6 @@ function player.cancel(P,N)--Cancel Garbage
bf.sum=bf.sum-O
A.sent,A.time=true,0
if N>0 then goto R end
print(A.amount)
else
off=off+N
A.amount=A.amount-N
@@ -1538,7 +1584,7 @@ function player.drop(P)--Place piece
--Tri-corner
if P.cur.id<6 then
local x,y=P.curX+P.sc[2]-1,P.curY+P.sc[1]-1
local x,y=P.curX+P.sc[2],P.curY+P.sc[1]
local c=0
if P:solid(x-1,y+1)then c=c+1 end
if P:solid(x+1,y+1)then c=c+1 end
@@ -1788,7 +1834,7 @@ function player.drop(P)--Place piece
end
::checkB2Breduce::
if not(dospin or cc==4)then
if not(dospin or cc>3)then
P.b2b=max(P.b2b-250,0)
P:showText(text.clear[cc],0,-30,27+cc*3,"appear",(8-cc)*.3)
atk=cc-.5
@@ -1909,7 +1955,7 @@ function player.drop(P)--Place piece
STAT.piece=STAT.piece+1
STAT.row=STAT.row+cc
if atk>0 then
STAT.atk=STAT.atk+int(atk)
STAT.atk=STAT.atk+atk
if send>0 then
STAT.send=STAT.send+int(send)
end
@@ -2139,9 +2185,9 @@ function player.lose(P)
P:showTextF(P.modeData.event,0,120,60,"appear",.26,.9)
end
P.gameEnv.keepVisible=P.gameEnv.visible~="show"
P:showTextF(text.lose,0,0,90,"appear",.26,.9)
P:showTextF(text.gameover,0,0,60,"appear",.26,.9)
if P.human then
game.result="lose"
game.result="gameover"
SFX.play("fail")
VOC.play("lose")
if modeEnv.royaleMode then
@@ -2187,10 +2233,9 @@ function player.act.moveLeft(P,auto)
elseif P.control and P.waiting==-1 then
if P.cur and not P:ifoverlap(P.cur.bk,P.curX-1,P.curY)then
P.curX=P.curX-1
local y0=P.curY
P:freshgho()
if P.gameEnv.easyFresh or y0~=P.curY then P:freshLockDelay()end
if P.human and P.curY==P.y_img then SFX.play("move")end
P:freshLockDelay()
if P.human and P.curY==P.imgY then SFX.play("move")end
if not auto then P.moving=0 end
P.spinLast=false
else
@@ -2213,10 +2258,9 @@ function player.act.moveRight(P,auto)
elseif P.control and P.waiting==-1 then
if P.cur and not P:ifoverlap(P.cur.bk,P.curX+1,P.curY)then
P.curX=P.curX+1
local y0=P.curY
P:freshgho()
if P.gameEnv.easyFresh or y0~=P.curY then P:freshLockDelay()end
if P.human and P.curY==P.y_img then SFX.play("move")end
P:freshLockDelay()
if P.human and P.curY==P.imgY then SFX.play("move")end
if not auto then P.moving=0 end
P.spinLast=false
else
@@ -2254,11 +2298,11 @@ function player.act.hardDrop(P)
end
P.keyPressing[6]=false
elseif P.control and P.waiting==-1 and P.cur then
if P.curY~=P.y_img then
if P.curY~=P.imgY then
if P.gameEnv.dropFX then
P:createDropFX(P.curX,P.curY+1,P.curX+P.c-1,P.y_img+P.r-1)
P:createDropFX(P.curX,P.curY+1,P.curX+P.c-1,P.imgY+P.r-1)
end
P.curY=P.y_img
P.curY=P.imgY
P.spinLast=false
if P.gameEnv.shakeFX then
P.fieldOff.vy=P.gameEnv.shakeFX*.6
@@ -2281,8 +2325,9 @@ function player.act.softDrop(P)
else
P.downing=1
if P.control and P.waiting==-1 and P.cur then
if P.curY~=P.y_img then
if P.curY~=P.imgY then
P.curY=P.curY-1
P:freshMinY()
P.spinLast=false
end
end
@@ -2304,7 +2349,7 @@ function player.act.restart(P)
end
function player.act.insLeft(P,auto)
if P.gameEnv.nofly or not P.cur then return end
local x0,y0=P.curX,P.curY
local x0=P.curX
while not P:ifoverlap(P.cur.bk,P.curX-1,P.curY)do
P.curX=P.curX-1
if P.gameEnv.dropFX then
@@ -2312,8 +2357,8 @@ function player.act.insLeft(P,auto)
end
P:freshgho()
end
if x0~=P.curX then
if P.gameEnv.easyFresh or y0~=P.curY then P:freshLockDelay()end
if P.curX~=x0 then
P:freshLockDelay()
P.spinLast=false
end
if P.gameEnv.shakeFX then
@@ -2327,7 +2372,7 @@ function player.act.insLeft(P,auto)
end
function player.act.insRight(P,auto)
if P.gameEnv.nofly or not P.cur then return end
local x0,y0=P.curX,P.curY
local x0=P.curX
while not P:ifoverlap(P.cur.bk,P.curX+1,P.curY)do
P.curX=P.curX+1
if P.gameEnv.dropFX then
@@ -2335,8 +2380,8 @@ function player.act.insRight(P,auto)
end
P:freshgho()
end
if x0~=P.curX then
if P.gameEnv.easyFresh or y0~=P.curY then P:freshLockDelay()end
if P.curX~=x0 then
P:freshLockDelay()
P.spinLast=false
end
if P.gameEnv.shakeFX then
@@ -2349,40 +2394,44 @@ function player.act.insRight(P,auto)
end
end
function player.act.insDown(P)
if P.curY~=P.y_img and P.cur then
if P.curY~=P.imgY and P.cur then
if P.gameEnv.dropFX then
P:createDropFX(P.curX,P.curY+1,P.curX+P.c-1,P.y_img+P.r-1)
P:createDropFX(P.curX,P.curY+1,P.curX+P.c-1,P.imgY+P.r-1)
end
if P.gameEnv.shakeFX then
P.fieldOff.vy=P.gameEnv.shakeFX*.5
end
P.curY,P.lockDelay,P.spinLast=P.y_img,P.gameEnv.lock,false
P.curY,P.lockDelay,P.spinLast=P.imgY,P.gameEnv.lock,false
P:freshMinY()
end
end
function player.act.down1(P)
if P.curY~=P.y_img and P.cur then
if P.curY~=P.imgY and P.cur then
P.curY=P.curY-1
P:freshMinY()
P.spinLast=false
end
end
function player.act.down4(P)
for _=1,4 do
if P.curY~=P.y_img and P.cur then
if P.curY~=P.imgY and P.cur then
P.curY=P.curY-1
P:freshMinY()
P.spinLast=false
else
break
return
end
end
end
function player.act.down10(P)
if P.cur then
for _=1,10 do
if P.curY~=P.y_img then
if P.curY~=P.imgY then
P.curY=P.curY-1
P:freshMinY()
P.spinLast=false
else
break
return
end
end
end
@@ -2397,14 +2446,14 @@ function player.act.dropRight(P)
P.act.insRight(P)
P.act.hardDrop(P)
end
function player.act.addLeft(P)
function player.act.zangiLeft(P)
if P.gameEnv.nofly or not P.cur then return end
P.act.insLeft(P)
P.act.insDown(P)
P.act.insRight(P)
P.act.hardDrop(P)
end
function player.act.addRight(P)
function player.act.zangiRight(P)
if P.gameEnv.nofly or not P.cur then return end
P.act.insRight(P)
P.act.insDown(P)
@@ -2418,7 +2467,7 @@ T={
A.rot180 ,A.hardDrop, A.softDrop, A.hold,
A.func ,A.restart, A.insLeft, A.insRight,
A.insDown ,A.down1, A.down4, A.down10,
A.dropLeft ,A.dropRight, A.addLeft, A.addRight
A.dropLeft ,A.dropRight, A.zangiLeft,A.zangiRight
}for i=1,20 do A[i]=T[i]end;A,T=nil
--------------------------</Control>--------------------------
@@ -2457,7 +2506,7 @@ local function newEmptyPlayer(id,x,y,size)
P.draw=Pdraw_norm
P.bonus={}--Text objects
end
P.randomSeed=game.seed
P.randGen=mt.newRandomGenerator(game.seed)
P.small=false
P.life=0
@@ -2489,7 +2538,7 @@ local function newEmptyPlayer(id,x,y,size)
--P.sc,P.dir={0,0},0--SpinCenterCoord, direction
--P.r,P.c=0,0--row, col
--P.hd={...},same as P.cur
P.curX,P.curY,P.y_img=0,0,0--x,y,ghostY
-- P.curX,P.curY,P.imgY,P.minY=0,0,0,0--x,y,ghostY
P.holded=false
P.next={}
@@ -2529,11 +2578,13 @@ local function loadGameEnv(P)--Load gameEnv
--Load game settings
for k,v in next,gameEnv0 do
if modeEnv[k]~=nil then
v=modeEnv[k]
v=modeEnv[k] --Mode setting
elseif game.setting[k]~=nil then
v=game.setting[k] --Game setting
elseif setting[k]~=nil then
v=setting[k]
v=setting[k] --Global setting
end
ENV[k]=v
ENV[k]=v --Default setting
end
end
local function applyGameEnv(P)--Finish gameEnv processing

View File

@@ -18,6 +18,8 @@ local list={
"paper(mrz)",
"classic(_)",
"brick(notypey)",
"retro(notypey)",
"retro_grey(notypey)",
"text_bone(mrz)",
"colored_bone(mrz)",
"white_bone(mrz)",

View File

@@ -1,9 +1,9 @@
local N1,N2={1,2},{2,1}
local N3,N4={2,2},{1.5,1.5}
local I1,I2={0.5,2.5},{2.5,0.5}
local I3,I4={1.5,2.5},{2.5,1.5}
local V4={2.5,2.5}
local L1,L2={1,3},{3,1}
local N1,N2={0,1},{1,0}
local N3,N4={1,1},{.5,.5}
local I1,I2={-.5,1.5},{1.5,-.5}
local I3,I4={.5,1.5},{1.5,.5}
local V4={1.5,1.5}
local L1,L2={0,2},{2,0}
local scs={
--Tetramino
{[0]=N1,N2,N3,N3},--Z

View File

@@ -67,6 +67,7 @@ function Tick.throwBadge(data)--{ifAI,Sender,timer}
end
function Tick.autoPause(data)
data[1]=data[1]+1
if SCN.cur~="play"then return end
if data[1]==120 then
if SCN.cur=="play"then
pauseGame()
@@ -74,14 +75,4 @@ function Tick.autoPause(data)
return true
end
end
function Tick.autoResize(data)
data[1]=data[1]+1
if data[1]==62 then
local w,h=gc.getWidth(),gc.getHeight()
if w<h then
love.resize(w,h)
end
return true
end
end
return Tick

View File

@@ -56,6 +56,7 @@ Future outlook:
mine sweeper
tank battle
new AI: task-Z
self protection
cool backgrounds
'Encrypt'(compile to byte code)
better drop FX
@@ -69,6 +70,39 @@ Future outlook:
more graphic FXs & 3D features & animations
network game
0.10.2: 锁延修复 Lock Delay Fixed
改动:
锁延机制再修正
"失败"字样改为"游戏结束"
修复:
改设置后回放错误
字库缺字
0.10.1: 细节更新 Details update
新内容:
新语言:就这?
新语言配套阴阳怪气Tips
光标点击动画
锁延机制修正
锁延和可刷新次数可视化
两个新皮肤
改动:
BGM重新分配
rockblock音乐微调
无刻度滑条
音量曲线调整
代码:
玩家act函数addL/R更名zangiL/R
玩家属性y_img更名imgY
旋转中心坐标向左下修正负一
修复:
改设置后回放错误
0.10.0的错误序列生成器
按R重开后濒死预警不消失
GM模式通关一直触发win
手机端屏幕方向错误(也许修复了)
控制设置das/arr预览错误
0.10.0: 回放更新 Replay Update
新内容:
更新后跳转到此页面
@@ -82,7 +116,7 @@ Future outlook:
Chinese update log
控件动效优化
极简错误音效调整
模电吉备历史性同框
模电HBM历史性同框
spin消3的分数下调
暂停界面数据显示格式和布局微调
初心/上级20G评级要求改动,清除高分榜
@@ -91,11 +125,12 @@ Future outlook:
代码:
帧率控制代码调整,运行可能更流畅(反正不会比以前卡)
修改部分玩家方法名
统一注释位置,所有注释开头大写
注释更规范了
修复:
一些文本小错误
自定义序列相关的闪退
按键跟踪设置界面闪退
五联块成绩排序错误
pc训练方块ghost浮空
i平放顶层消1的奇怪行为
玩家掉出屏幕过程中绘制场地时剪裁不正确