Compare commits

...

16 Commits

Author SHA1 Message Date
MrZ626
1fa7bf9c27 修复房间内玩家连接状态相关代码一处概率报错 2021-05-14 22:23:05 +08:00
MrZ626
b50e01e4cf 修改更新历史,更新版本号 2021-05-14 22:23:05 +08:00
MrZ626
7abf9b0d0c 增加自定义游戏锁延刷新次数挡位 2021-05-14 22:23:04 +08:00
MrZ626
504c6f46c3 新增无尽pc挑战模式,微调其他pc模式的数据展示 2021-05-14 22:23:04 +08:00
MrZ626
78b1dcc949 减少生存模式最高两个难度的锁延刷新次数 2021-05-14 20:40:13 +08:00
MrZ626
9b0c859593 把三个设置项改成默认开启 2021-05-14 20:22:57 +08:00
MrZ626
c9a3075d0a 修复联网房间内潜在的报错可能 2021-05-14 20:20:54 +08:00
MrZ626
953b17ee88 textBox控件在隐藏时也会自动滚动 2021-05-14 20:20:54 +08:00
MrZ626
95bc979da7 主菜单点联网游戏按钮尝试连接时会有文字提示,房间内可以显示其他玩家的ws(stream)连接状态 2021-05-14 20:20:54 +08:00
MrZ626
622b1a5e25 主菜单点击联网游戏按钮尝试连接时会有文字提示 2021-05-14 18:58:44 +08:00
MrZ626
0c66ca1bdc 调整干旱2模式的标题 2021-05-14 16:25:42 +08:00
MrZ626
67323c4d93 yygq语言的tips改为深灰色移入普通语言 2021-05-14 16:25:42 +08:00
MrZ626
e2b0069947 调整统计文件保存时机,左上角不再弹出保存成功提醒 2021-05-14 12:11:56 +08:00
MrZ626
5697a201ef 简化LOG.print的功能和使用 2021-05-14 11:35:34 +08:00
MrZ626
c6115e3417 修复聊天窗带空格的消息会被截断 2021-05-14 10:29:52 +08:00
MrZ626
0ad122ce01 string扩展模块新增trim方法 2021-05-14 10:23:16 +08:00
51 changed files with 342 additions and 244 deletions

View File

@@ -50,7 +50,7 @@ function BGM.init(list)
Sources[list[i]]:setLooping(true)
Sources[list[i]]:setVolume(0)
else
LOG.print("No BGM file: "..list[i],5,COLOR.O)
LOG.print("No BGM file: "..list[i],5,'warn')
end
if not skip and i~=count then
coroutine.yield()

View File

@@ -21,7 +21,7 @@ function FILE.load(name)
return s
end
end
LOG.print(name.." "..text.loadError,COLOR.R)
LOG.print(name.." "..text.loadError,'error')
end
end
function FILE.save(data,name,mode)
@@ -50,7 +50,7 @@ function FILE.save(data,name,mode)
F:flush()F:close()
if success then
if not mode:find'q'then
LOG.print(text.saveDone,COLOR.G)
LOG.print(text.saveDone,'message')
end
else
LOG.print(text.saveError..(mes or"unknown error"),'error')

View File

@@ -204,7 +204,7 @@ local function noDevkeyPressed(key)
if key=="f1"then
PROFILE.switch()
elseif key=="f2"then
LOG.print(("System:%s[%s]\nluaVer:%s\njitVer:%s\njitVerNum:%s"):format(SYSTEM,jit.arch,_VERSION,jit.version,jit.version_num))
LOG.print(("System:%s[%s]\nluaVer:%s\njitVer:%s\njitVerNum:%s"):format(SYSTEM,jit.arch,_VERSION,jit.version,jit.version_num),'message')
elseif key=="f3"then
for _=1,8 do
local P=PLY_ALIVE[rnd(#PLY_ALIVE)]
@@ -217,11 +217,11 @@ local function noDevkeyPressed(key)
elseif key=="f5"then if WIDGET.sel then print(WIDGET.sel)end
elseif key=="f6"then for k,v in next,_G do print(k,v)end
elseif key=="f7"then if love._openConsole then love._openConsole()end
elseif key=="f8"then devMode=nil LOG.print("DEBUG OFF",COLOR.Y)
elseif key=="f9"then devMode=1 LOG.print("DEBUG 1",COLOR.Y)
elseif key=="f10"then devMode=2 LOG.print("DEBUG 2",COLOR.Y)
elseif key=="f11"then devMode=3 LOG.print("DEBUG 3",COLOR.Y)
elseif key=="f12"then devMode=4 LOG.print("DEBUG 4",COLOR.Y)
elseif key=="f8"then devMode=nil LOG.print("DEBUG OFF")
elseif key=="f9"then devMode=1 LOG.print("DEBUG 1")
elseif key=="f10"then devMode=2 LOG.print("DEBUG 2")
elseif key=="f11"then devMode=3 LOG.print("DEBUG 3")
elseif key=="f12"then devMode=4 LOG.print("DEBUG 4")
elseif key=="\\"then _G["\100\114\97\119\70\87\77"]=NULL
elseif devMode==2 then
if WIDGET.sel then
@@ -251,7 +251,7 @@ function love.keypressed(key)
return
elseif key=="f8"then
devMode=1
LOG.print("DEBUG ON",COLOR.Y)
LOG.print("DEBUG ON")
elseif key=="f11"then
switchFullscreen()
elseif not SCN.swapping then
@@ -278,12 +278,13 @@ end
function love.joystickadded(JS)
ins(joysticks,JS)
LOG.print("Joystick added",'message')
end
function love.joystickremoved(JS)
local i=TABLE.find(joysticks,JS)
if i then
rem(joysticks,i)
LOG.print("Joystick removed",COLOR.Y)
LOG.print("Joystick removed",'message')
end
end
local keyMirror={

View File

@@ -4,7 +4,7 @@ return function(name,libName)
if r1 and r2 then
return r2
else
LOG.print("Cannot load "..name..": "..(r2 or r3),'warn',COLOR.R)
LOG.print("Cannot load "..name..": "..(r2 or r3),'warn')
end
elseif SYSTEM=="Android"then
local fs=love.filesystem
@@ -12,35 +12,35 @@ return function(name,libName)
local libFunc=package.loadlib(SAVEDIR.."/lib/"..libName.Android,libName.libFunc)
if libFunc then
LOG.print(name.." lib loaded",'warn',COLOR.G)
LOG.print(name.." lib loaded",'message')
else
for i=1,#platform do
local soFile=fs.read('data',"libAndroid/"..platform[i].."/"..libName.Android)
local soFile,_,_,mes1=fs.read('data',"libAndroid/"..platform[i].."/"..libName.Android)
if soFile then
local success,message=fs.write("lib/"..libName.Android,soFile)
local success,mes2=fs.write("lib/"..libName.Android,soFile)
if success then
libFunc,message=package.loadlib(SAVEDIR.."/lib/"..libName.Android,libName.libFunc)
libFunc,mes2=package.loadlib(SAVEDIR.."/lib/"..libName.Android,libName.libFunc)
if libFunc then
LOG.print(name.." lib loaded",'warn',COLOR.G)
LOG.print(name.." lib loaded",'message')
break
else
LOG.print("Cannot load "..name..": "..message,'warn',COLOR.R)
LOG.print("Cannot load "..name..": "..mes2,'error')
end
else
LOG.print("Write "..name.."-"..platform[i].." to saving failed: "..message,'warn',COLOR.R)
LOG.print(("Write %s-%s to saving failed: %s"):format(name,platform[i],mes2),'error')
end
else
LOG.print("Read "..name.."-"..platform[i].." failed",'warn',COLOR.R)
LOG.print(("Read %s-%s to saving failed: %s"):format(name,platform[i],mes1),'error')
end
end
if not libFunc then
LOG.print("Cannot load "..name,'warn',COLOR.R)
LOG.print("Cannot load "..name,'error')
return
end
end
return libFunc()
else
LOG.print("No "..name.." for "..SYSTEM,'warn',COLOR.R)
LOG.print("No "..name.." for "..SYSTEM,'error')
return
end
return true

View File

@@ -35,36 +35,26 @@ function LOG.draw()
end
end
end
function LOG.print(text,T,C)--text,type/time/color,color
local time
local his
if T=='warn'then
C=C or COLOR.Y
his=true
time=180
function LOG.print(text,T)--text,type/time/color,color
local color=COLOR.Z
local time,his
if T=='message'then
color=COLOR.N
his,time=true,180
elseif T=='warn'then
color=COLOR.Y
his,time=true,180
elseif T=='error'then
C=C or COLOR.R
his=true
time=210
elseif T=='message'then
C=C or COLOR.N
his=true
color=COLOR.R
his,time=true,210
elseif type(T)=='number'then
C=C or COLOR.Z
time=T
elseif type(T)=='table'then
C=T
elseif not C then
C=COLOR.Z
end
if his then
ins(debugMesHistory,SCN.cur..": "..tostring(text))
end
ins(debugMesList,{text=tostring(text),r=C[1],g=C[2],b=C[3],blink=30,time=time or 120})
if his then ins(debugMesHistory,SCN.cur..": "..tostring(text))end
ins(debugMesList,{text=tostring(text),r=color[1],g=color[2],b=color[3],blink=30,time=time or 120})
end
function LOG.copy()
local str=table.concat(debugMesHistory,"\n")
love.system.setClipboardText(str)
LOG.print("Log copied",COLOR.B)
love.system.setClipboardText(table.concat(debugMesHistory,"\n"))
LOG.print("Log copied",'message')
end
return LOG

View File

@@ -141,10 +141,10 @@ function profile.switch()
profile.stop()
love.system.setClipboardText(PROFILE.report())
PROFILE.reset()
LOG.print("profile report copied!")
LOG.print("profile report copied!",'message')
else
PROFILE.start()
LOG.print("profile start!")
LOG.print("profile start!",'message')
end
switch=not switch
end

View File

@@ -17,7 +17,7 @@ function SFX.init(list)
if love.filesystem.getInfo(N)then
Sources[list[i]]={love.audio.newSource(N,'static')}
else
LOG.print("No SFX file: "..N,5,COLOR.O)
LOG.print("No SFX file: "..N,5)
end
if not skip and i~=count then
coroutine.yield()

View File

@@ -16,6 +16,12 @@ do--function STRING.shiftChar(c)
end
end
function STRING.trim(str)
if not str:find("%S")then return""end
str=str:sub((str:find("%S"))):reverse()
return str:sub((str:find("%S"))):reverse()
end
function STRING.split(s,sep,regex)
local L={}
local p1,p2=1--start,target

View File

@@ -48,15 +48,15 @@ function THEME.set(theme)
elseif theme=='xmas'then
BG.setDefault('snow')
BGM.setDefault('xmas')
LOG.print("==============",COLOR.R)
LOG.print("Merry Christmas!",COLOR.Z)
LOG.print("==============",COLOR.R)
LOG.print("==============")
LOG.print("Merry Christmas!")
LOG.print("==============")
elseif theme=='sprfes'then
BG.setDefault('firework')
BGM.setDefault("spring festival")
LOG.print(" ★☆☆★",COLOR.R)
LOG.print("新年快乐!",COLOR.Z)
LOG.print(" ★☆☆★",COLOR.R)
LOG.print(" ★☆☆★")
LOG.print("新年快乐!")
LOG.print(" ★☆☆★")
elseif theme=='zday1'then
BG.setDefault('lanterns')
BGM.setDefault("empty")

View File

@@ -45,7 +45,7 @@ function VOC.init(list)
if n==1 then
if not loadVoiceFile(list[i],list[i])then
LOG.print("No VOICE file: "..list[i],5,COLOR.O)
LOG.print("No VOICE file: "..list[i],5)
end
end
if not Source[list[i]][1]then Source[list[i]]=nil end

View File

@@ -896,7 +896,7 @@ function textBox:update()
end
function textBox:push(t)
ins(self.texts,t)
if self.scrollPos==#self.texts-1 and not self.hide then
if self.scrollPos==#self.texts-1 then
self.scrollPos=#self.texts
else
self.new=true

View File

@@ -1,7 +1,7 @@
VERSION={
code=1407,
string="Alpha V0.14.7",
name="烈日 Burn",
code=1408,
string="Alpha V0.14.8",
name="冰激凌 Icecream",
}
function love.conf(t)
t.identity='Techmino'--Saving folder

View File

@@ -167,7 +167,7 @@ SFX.init((function()
if fs.getRealDirectory("media/SFX/"..v)~=SAVEDIR then
table.insert(L,v:sub(1,-5))
else
LOG.print("Dangerous file : %SAVE%/media/SFX/"..v)
LOG.print("Dangerous file : %SAVE%/media/SFX/"..v,'warn')
end
end
return L
@@ -178,7 +178,7 @@ BGM.init((function()
if fs.getRealDirectory("media/BGM/"..v)~=SAVEDIR then
table.insert(L,v:sub(1,-5))
else
LOG.print("Dangerous file : %SAVE%/media/BGM/"..v)
LOG.print("Dangerous file : %SAVE%/media/BGM/"..v,'warn')
end
end
return L

View File

@@ -4,6 +4,8 @@ local int=math.floor
local char,byte=string.char,string.byte
local ins=table.insert
local BAG,FIELD,MISSION,CUSTOMENV,GAME=BAG,FIELD,MISSION,CUSTOMENV,GAME
local DATA={}
--Sep symbol: 33 (!)
--Safe char: 34~126
@@ -14,7 +16,6 @@ local DATA={}
Example: "abcdefg" is [SZJLTOI], "a^aDb)" is [Z*63,Z*37,S*10]
]]
function DATA.copySequence()
local BAG=BAG
local str=""
local count=1
@@ -111,24 +112,22 @@ function DATA.pasteBoard(str,page)--Paste [str] data to [page] board
if not page then page=1 end
if not FIELD[page]then FIELD[page]=DATA.newBoard()end
local F=FIELD[page]
local _,__
--Decode
if not str:find("%S")then return end
str=str:sub((str:find("%S"))):reverse()
str=str:sub((str:find("%S"))):reverse()
_,str=pcall(data.decode,'string','base64',str)
if not _ then return end
_,str=pcall(data.decompress,'string','zlib',str)
if not _ then return end
local res
str=STRING.trim(str)
res,str=pcall(data.decode,'string','base64',str)
if not res then return end
res,str=pcall(data.decompress,'string','zlib',str)
if not res then return end
local fX,fY=1,1--*ptr for Field(r*10+(c-1))
local p=1
while true do
_=byte(str,p)--1byte
local b=byte(str,p)--1byte
--Str end
if not _ then
if not b then
if fX~=1 then
return
else
@@ -136,11 +135,11 @@ function DATA.pasteBoard(str,page)--Paste [str] data to [page] board
end
end
__=_%32-1--Block id
if __>26 then return end--Illegal blockid
_=int(_/32)--Mode id
local id=b%32-1--Block id
if id>26 then return end--Illegal blockid
b=int(b/32)--Mode id
F[fY][fX]=__
F[fY][fX]=id
if fX<10 then
fX=fX+1
else
@@ -178,7 +177,6 @@ end
]]
function DATA.copyMission()
local _
local MISSION=MISSION
local str=""
local count=1
@@ -364,7 +362,7 @@ do--function DATA.saveRecording()
--Filtering modes that cannot be saved
for _,v in next,noRecList do
if GAME.curModeName:find(v)then
LOG.print("Cannot save recording of this mode now!",COLOR.N)
LOG.print("Cannot save recording of this mode now!",'warn')
return
end
end
@@ -388,7 +386,7 @@ do--function DATA.saveRecording()
FILE.save(REPLAY,'conf/replay')
return true
else
LOG.print("Save failed: File already exists")
LOG.print("Save failed: File already exists",'error')
end
end
end

View File

@@ -245,7 +245,6 @@ function loadGame(M,ifQuickPlay,ifNet)--Load a mode and go to game scene
end
function gameOver()--Save record
if GAME.replaying then return end
FILE.save(STAT,'conf/data')
local M=GAME.curMode
local R=M.getRank
if R then
@@ -434,9 +433,10 @@ do--function resetGameData(args)
end
function resetGameData(args,seed)
if not args then args=""end
if PLAYERS[1]and not GAME.replaying and(PLAYERS[1].frameRun>400 or GAME.result)then
if PLAYERS[1]and not GAME.replaying and(PLAYERS[1].frameRun>300 or GAME.result)then
mergeStat(STAT,PLAYERS[1].stat)
STAT.todayTime=STAT.todayTime+PLAYERS[1].stat.time
FILE.save(STAT,'conf/data','q')
end
GAME.result=false

View File

@@ -282,9 +282,9 @@ SETTING={--Settings
text=true,
score=true,
warn=true,
bufferWarn=false,
highCam=false,
nextPos=false,
bufferWarn=true,
highCam=true,
nextPos=true,
fullscreen=true,
bg=true,
powerInfo=false,

View File

@@ -93,6 +93,8 @@ return{
loginFailed="Failed to log in.",
accessSuccessed="Access Granted.",
accessFailed="Access Denied.",
wsConnecting="Websocket: Connecting",
wsSuccessed="WebSocket: Connected.",
wsFailed="WebSocket: Connection Failed.",
wsClose="WebSocket Closed: ",
@@ -106,7 +108,8 @@ return{
joinRoom="has joined the room.",
leaveRoom="has left the room.",
ready="READY",
set="SET",
connStream="CONNECTING",
waitStream="WAITING",
champion="$1 won",
chatRemain="Online",
chatStart="------Beginning of log------",
@@ -694,7 +697,7 @@ return{
['dig_400l']= {"Dig", "400L", "Dig 400 garbage lines."},
['dig_1000l']= {"Dig", "1000L", "Dig 1000 garbage lines."},
['drought_n']= {"Drought", "100L", "There are no I-pieces."},
['drought_l']= {"Drought", "100L", "W T F"},
['drought_l']= {"Drought+", "100L", "W T F"},
['marathon_n']= {"Marathon", "NORMAL", "200-line marathon with accelerating speed."},
['marathon_h']= {"Marathon", "HARD", "200-line high-speed marathon."},
['solo_e']= {"Battle", "EASY", "Defeat the AI!"},
@@ -747,6 +750,7 @@ return{
['pc_n']= {"PC Challenge", "NORMAL", "Get PCs within 100 lines!"},
['pc_h']= {"PC Challenge", "HARD", "Get PCs within 100 lines!"},
['pc_l']= {"PC Challenge", "LUNATIC", "Get PCs within 100 lines!"},
['pc_inf']= {"Infinite PC Challenge","", "Get PCs as much as you can"},
['tech_n']= {"Tech", "NORMAL", "Try to keep the\nBack-to-Back chain!"},
['tech_n_plus']= {"Tech", "NORMAL+", "Spins & PCs only."},
['tech_h']= {"Tech", "HARD", "Try to keep the\nBack-to-Back chain!"},

View File

@@ -93,6 +93,8 @@ return{
loginFailed="Erreur de connexion",
accessSuccessed="Autorisé avec succès !",
accessFailed="Autorisation échouée",
-- wsConnecting="Websocket: Connecting",
wsSuccessed="WebSocket: connecté",
wsFailed="WebSocket: connection échouée",
-- wsClose="WebSocket Closed: ",
@@ -106,7 +108,8 @@ return{
joinRoom="a rejoint le salon.",
leaveRoom="a quitté le salon.",
-- ready="READY",
-- set="SET",
-- connStream="CONNECTING",
-- waitStream="WAITING",
champion="$1 a gagné",
chatRemain="En ligne : ",
chatStart="--------Début des logs--------",
@@ -605,7 +608,7 @@ return{
['dig_400l']= {"Dig", "400L", "Creusez 400 lines"},
['dig_1000l']= {"Dig", "1000L", "Creusez 1000 lines"},
['drought_n']= {"Drought", "100L", "Pas de pièce I !"},
['drought_l']= {"Drought", "100L", "WTF ??!!"},
['drought_l']= {"Drought+", "100L", "WTF ??!!"},
['marathon_n']= {"Marathon", "NORMAL", "Marathon de 200 lignes."},
['marathon_h']= {"Marathon", "DIFFICILE", "Marathon de 200 lignes à très haute vitesse"},
['solo_e']= {"Battle", "FACILE", "Battez l'IA !"},
@@ -658,6 +661,7 @@ return{
['pc_n']= {"PC Challenge", "NORMAL", "Obtenez un PC dans les prochaines 100 lignes !"},
['pc_h']= {"PC Challenge", "DIFFICILE", "Obtenez un PC dans les prochaines 100 lignes !"},
['pc_l']= {"PC Challenge", "LUNATIQUE", "Obtenez un PC dans les prochaines 100 lignes !"},
['pc_inf']= {"Infinite PC Challenge","", "Get PCs as much as you can"},--TODO
['tech_n']= {"Tech", "NORMAL", "Gardez le B2B !"},
['tech_n_plus']= {"Tech", "NORMAL+", "Spin & PC uniquement"},
['tech_h']= {"Tech", "DIFFICILE", "Gardez le B2B !"},

View File

@@ -93,6 +93,8 @@ return{
loginFailed="Falha na autenticação",
accessSuccessed="Autorizado com sucesso!",
accessFailed="Falha na autorização",
-- wsConnecting="Websocket: Connecting",
wsSuccessed="WebSocket: conectado",
wsFailed="WebSocket: falha na conexão",
wsClose="WebSocket closed: ",
@@ -106,7 +108,8 @@ return{
joinRoom="Entrou a sala.",
leaveRoom="Saiu da sala.",
-- ready="READY",
-- set="SET",
-- connStream="CONNECTING",
-- waitStream="WAITING",
-- champion="$1 won",
chatRemain="Online",
chatStart="------Começo do log------",
@@ -690,7 +693,7 @@ return{
['dig_400l']= {"Cave", "400L", "Cave 400 linhas de lixo."},
['dig_1000l']= {"Cave", "1000L", "Cave 1000 linhas de lixo."},
['drought_n']= {"Drought", "100L", "Sem peça I !"},
['drought_l']= {"Drought", "100L", "WTF"},
['drought_l']= {"Drought+", "100L", "WTF"},
['marathon_n']= {"Maratona", "NORMAL", "200-line Maratona com velocidade aumentando."},
['marathon_h']= {"Maratona", "DIFÍCIL", "200-line Maratona com velocidade alta."},
['solo_e']= {"Batalha", "FÁCIL", "Derrote a inteligência!"},
@@ -743,6 +746,7 @@ return{
['pc_n']= {"Desafio PC", "NORMAL", "Obtenha PCs em 100 linhas!"},
['pc_h']= {"Desafio PC", "DIFÍCIL", "Obtenha PCs em 100 linhas!"},
['pc_l']= {"Desafio PC", "LUNÁTICO", "Obteha PCs em 100 linhas!"},
['pc_inf']= {"Infinite PC Challenge","", "Get PCs as much as you can"},--TODO
['tech_n']= {"Tech", "NORMAL", "Não quebre o B2B!"},
['tech_n_plus']= {"Tech", "NORMAL+", "Apenas spins e PC"},
['tech_h']= {"Tech", "HARD", "Keep the B2B chain!"},

View File

@@ -93,6 +93,8 @@ return{
loginFailed="Error al ingresar",
accessSuccessed="¡Autorizado exitoso!",
accessFailed="Error al autorizar",
-- wsConnecting="Websocket: Connecting",
wsSuccessed="WebSocket: conectado",
wsFailed="WebSocket: conexión fallida",
wsClose="WebSocket cerrado: ",
@@ -106,7 +108,8 @@ return{
joinRoom="entró a la sala.",
leaveRoom="salió de la sala.",
-- ready="READY",
-- set="SET",
-- connStream="CONNECTING",
-- waitStream="WAITING",
champion="$1 ganó!",
chatRemain="Usuarios en línea: ",
chatStart="------Comienzo del historial------",
@@ -603,7 +606,7 @@ return{
['dig_400l']= {"Queso", "400L", "Limpia 400 líneas de queso."},
['dig_1000l']= {"Queso", "1000L", "Limpia 1000 líneas de queso."},
['drought_n']= {"Sequía", "100L", "¡Sin piezas I!"},
['drought_l']= {"Sequía", "100L", "Guat de foc..."},
['drought_l']= {"Sequía+", "100L", "Guat de foc..."},
['marathon_n']= {"Maratón", "Normal", "Maratón de 200 líneas con velocidad en aumento."},
['marathon_h']= {"Maratón", "Difícil", "Maratón de 200 líneas a velocidad máxima."},
['solo_e']= {"VS.", "Fácil", "¡Derrota a la CPU!"},
@@ -655,6 +658,7 @@ return{
['pc_n']= {"Desafío de PCs", "Normal", "¡Consigue los PCs que puedas en 100 líneas!"},
['pc_h']= {"Desafío de PCs", "Difícil", "¡Consigue los PCs que puedas en 100 líneas!"},
['pc_l']= {"Desafío de PCs", "Lunático", "¡Consigue los PCs que puedas en 100 líneas!"},
['pc_inf']= {"Infinite PC Challenge","", "Get PCs as much as you can"},--TODO
['tech_n']= {"Tech", "Normal", "¡Mantén el B2B!"},
['tech_n_plus']= {"Tech", "Normal+", "¡Sólo se permiten Spins y PCs!"},
['tech_h']= {"Tech", "Difícil", "¡Mantén el B2B!"},

View File

@@ -204,7 +204,7 @@ return{
['dig_400l']= {"挖掘", "400L", "挖400行"},
['dig_1000l']= {"挖掘", "1000L", "挖1000行"},
['drought_n']= {"干旱", "100L", "放轻松,简单得很"},
['drought_l']= {"干旱", "100L", "有趣的要来了"},
['drought_l']= {"干旱+", "100L", "有趣的要来了"},
['marathon_n']= {"马拉松", "普通", "休闲模式"},
['marathon_h']= {"马拉松", "困难", "休闲模式"},
['solo_e']= {"单挑", "简单", "鲨AI"},
@@ -257,6 +257,7 @@ return{
['pc_n']= {"全清挑战", "普通", "100行内刷PC"},
['pc_h']= {"全清挑战", "困难", "100行内刷PC"},
['pc_l']= {"全清挑战", "疯狂", "100行内刷PC"},
['pc_inf']= {"无尽全清挑战", "", "你这水平还是先别玩了"},
['tech_n']= {"科研", "普通", "禁止断B2B"},
['tech_n_plus']= {"科研", "普通+", "仅允许spin与PC"},
['tech_h']= {"科研", "困难", "禁止断B2B"},
@@ -275,44 +276,11 @@ return{
['zen']= {"", "200", "不限时200行"},
['ultra']= {"限时打分", "挑战", "2分钟刷分"},
['infinite']= {"无尽", "", "真的有人会玩这个?"},
['infinite_dig']= {"无尽:挖掘", "", "闲得慌的话来挖"},
['infinite_dig']= {"无尽:挖掘", "", "闲得慌来挖"},
['sprintFix']= {"竞速", "无移动"},
['sprintLock']= {"竞速", "无旋转"},
['marathon_bfmax']= {"马拉松", "极限"},
['custom_clear']= {"自定义", "普通"},
['custom_puzzle']= {"自定义", "拼图"},
},
getTip={refuseCopy=true,
"100apm?你倒是不用开局定式连续打几把",
"10连pc不是随手?",
"20G很难?是个人都能玩吧。",
"20TSD不难吧。",
"3pps不是人均水平?",
"40行还要40多秒,就这?",
"别会个c4w就以为自己多强,这是基本功罢了。",
"别人只用一只手都能玩,你呢?",
"不会吧不会吧,真的还有人不能随手Tspin?",
"除了雨宫太阳你还认识谁?Jonas知道吗?Ajanba听过吗?",
"还搁这玩手机呢,作业做完了?",
"极限20G不是随手通?",
"叫你多练就多练,想着几天变神仙,当自己是谁?",
"先练基础不听,现在速度没有,Tspin完地形一塌糊涂,开心吗?",
"经典块跟现代块是两个游戏,别拿多少年前水平秀优越,请从头练起。",
"卖弱不是谦虚,请看场合。",
"卖弱是要遭报应的",
"满口PCDT信天翁,还会点别的么?",
"没那水平别天天整什么花里胡哨的,人玩几年你想几天赶上?",
"全隐40行全消四很难吗??",
"少玩点,多眨眨眼,不听瞎了别怪我没提醒你",
"设置都看过一遍了吗?明明都有还嫌功能少,谁的问题?",
"谁说一定要强的人才叫卖弱?不是最菜就一定在有人眼中是卖弱",
"双旋和极简尽早学起来…懒得学以后亏的是自己",
"天天催更催更,你咋不来帮忙开发啊,真以为作者很强催催啥都有?",
"天天卖弱,你一定把把150apm吧?",
"问怎么练就好好问,别就一句话怎么变强,鬼知道你现在什么水平",
"一口一个wtcl还不赶紧去练,你是不思进取还是不想好好说话?",
"隐形很难?上电视那个水平一般都打成那样,属实自己不行看不起别人",
"隐形哪难了,你练了吗?没练几个小时在这里说难是嫌葡萄酸?",
"这不是休闲游戏…别怪关卡要求太高,就是你菜,请多练。",
},
}

View File

@@ -93,6 +93,8 @@ return{
loginFailed="登录失败",
accessSuccessed="身份验证成功",
accessFailed="身份验证失败",
wsConnecting="正在连接WS",
wsSuccessed="WS连接成功",
wsFailed="WS连接失败",
wsClose="WS被断开: ",
@@ -106,7 +108,8 @@ return{
joinRoom="进入房间",
leaveRoom="离开房间",
ready="各就各位!",
set="预备!",
connStream="正在连接",
waitStream="等待其他人连接",
champion="$1 获胜",
chatRemain="人数:",
chatStart="------消息的开头------",
@@ -695,7 +698,7 @@ return{
['dig_400l']= {"挖掘", "400L", "挖掘400行"},
['dig_1000l']= {"挖掘", "1000L", "挖掘1000行"},
['drought_n']= {"干旱", "100L", "你I没了"},
['drought_l']= {"干旱", "100L", "后 妈 发 牌"},
['drought_l']= {"干旱+", "100L", "后 妈 发 牌"},
['marathon_n']= {"马拉松", "普通", "200行加速马拉松"},
['marathon_h']= {"马拉松", "困难", "200行高速马拉松"},
['solo_e']= {"单挑", "简单", "打败AI"},
@@ -748,6 +751,7 @@ return{
['pc_n']= {"全清挑战", "普通", "100行内刷PC"},
['pc_h']= {"全清挑战", "困难", "100行内刷PC"},
['pc_l']= {"全清挑战", "疯狂", "100行内刷PC"},
['pc_inf']= {"无尽全清挑战", "", "你能连续做多少PC?"},
['tech_n']= {"科研", "普通", "禁止断B2B"},
['tech_n_plus']= {"科研", "普通+", "仅允许spin与PC"},
['tech_h']= {"科研", "困难", "禁止断B2B"},
@@ -806,15 +810,14 @@ return{
"6next 1hold!",
"6next 6hold?!",
"7宽三SZ架空捐了解一下",
"9999in1",
"626in1",
"按钮风格进化史",
"把手机调到特殊的日期也许会发生什么",
"报时机器人:新的一天开始了",
"背景影响游玩?可以去设置关闭",
"本游戏不是产品,是作品(至少目前是…)",
"本游戏不是产品,是作品(至少目前是,嗯…)",
"本游戏的一部分内容是国际合作的!",
"本游戏的B2B是气槽机制,和传统的开关机制不一样哦",
"本游戏可不是休闲游戏。",
"本游戏内置了几个休(ying)闲(he)小游戏哦~入口就藏在这个菜单",
"本游戏在设计的时候受到了大量其他块游甚至一些音游的启发",
"必须要软降才能到达的位置都会判定为极简操作",
@@ -828,7 +831,7 @@ return{
"彩色消除即将到来!",
"草(日本语)",
"成就系统在做了!",
"触发游戏报错后日志文件会越来越大(不过顶多几K)",
"触发游戏报错后日志文件会越来越大(不过顶多几K)",
"触摸板打osu也很好!",
"凑数tip什么时候能站起来!",
"打好块跟学习一样没有捷径,多练。",
@@ -857,6 +860,7 @@ return{
"感觉自己速度到上限了?试着把das调低一点",
"感谢群友帮忙想tip",
"感谢Orzmic为这个tip显示框提出意见",
"感谢Phigros提供部分tip模板(",
"刚接触方块的话多玩玩就行,40行两分钟以外没啥好针对性练习的",
"刚开始练全隐形可以尽量堆平,留一列消四",
"隔断消除即将到来!",
@@ -865,7 +869,6 @@ return{
"更小的DAS和ARR拥有更高的操作上限(能控制得了的话)",
"更新内容在游戏里和群公告都有写!",
"攻击生效速度(从快到慢):消二/三,消四,spin,高连击",
"官网在做了",
"还能写些什么tip呢",
"好像还没人能用脚打块打到一定水平",
"好像可以把手机倒过来打场地旋转180...那还是不建议违反规则",
@@ -897,6 +900,7 @@ return{
"你可以从统计页面打开游戏存档目录",
"你们考虑过Z酱的感受吗?没有!你们只考虑你自己。",
"你说彩蛋?嗯…算是有,可以找找",
"你有一个好",
"你知道吗:看主页机器人玩可能比较费电",
"你知道吗:全程不使用任何旋转键完成40行模式是有可能的",
"你知道吗:全程不使用左右移动键完成40行模式是有可能的",
@@ -966,6 +970,7 @@ return{
"作者40行sub26了",
"作者电脑上装了10个方块",
"作者浏览器收藏夹里有6个方块",
"做,做碌鸠啊做,打块先啦!",
"做点击特效的时候真没想抄Phigros!想法另有出处,做完了才突然发现好像(",
"ALLSPIN!",
"Am G F G",
@@ -1010,6 +1015,7 @@ return{
"sin2α=2SαCα",
"sofunhowtoget",
"Staff名单里飘过的是赞助榜单,喜欢本游戏的话可以给我们打赞助支持开发哦~",
"STSD必死",
"SΔABC=√(h(h-a)(h-b)(h-c)), h=(a+b+c)/2",
"Techmino = Technique + tetromino",
"Techmino 好玩!",
@@ -1063,19 +1069,13 @@ return{
{C.G,"快捷键: Ctrl+W=关闭当前标签页"},
{C.G,"快捷键: shift+del=永久删除文件 (技术人员别杠)"},
{C.G,"GREEN"},
{C.H,"感谢Phigros提供部分tip模板("},
{C.H,"暂定段位:9"},
{C.H,"REGRET!!"},
{C.J,"JADE"},
{C.L,"LIME"},
{C.lC,"26连T2来一个?"},
{C.lC,"Xspin",C.Z,"是啥"},
{C.lH,"腱鞘炎警告"},
{C.lH,"没学过编曲,音乐都是自己瞎写的,觉得不好听就去设置关了吧"},
{C.lH,"秘密数字:626"},
{C.lH,"你有一个好"},
{C.lH,"STSD必死"},
{C.lH,"Techmino没有抽卡没有氪金,太良心了"},
{C.lP,"秘密数字:626"},
{C.lP,"Naki",C.Z," 可爱!"},
{C.lR,"Z ",C.lG,"S ",C.lS,"J ",C.lO,"L ",C.lP,"T ",C.lY,"O ",C.lC,"I"},
{C.lS,"茶娘",C.Z," 可爱!"},
@@ -1116,5 +1116,41 @@ return{
{C.Z,"效率药水",C.H," 效率提升 (8:00)"},
{C.Z,"协调药水",C.H," MD减少 II(1:30)"},
-- "Z酱 可爱!",
{C.dH,"100apm?你倒是不用开局定式连续打几把"},
{C.dH,"10连pc不是随手?"},
{C.dH,"20G很难?是个人练练都能玩吧。"},
{C.dH,"20TSD不是轻松?"},
{C.dH,"3pps不是人均水平?"},
{C.dH,"40行还要40多秒,就这?"},
{C.dH,"别动不动大惊小怪,就你没见过"},
{C.dH,"别会个c4w就以为自己多强,基本功罢了。"},
{C.dH,"别人用跳舞毯打得都比你好"},
{C.dH,"别人只用一只手都能玩,你呢?"},
{C.dH,"除了雨宫太阳你还认识谁?Jonas知道吗?Ajanba听过吗?"},
{C.dH,"还搁这玩手机呢,作业做完了?"},
{C.dH,"极限20G不是随手通?"},
{C.dH,"腱鞘炎警告"},
{C.dH,"叫你多练就多练,想着几天变神仙,当自己是谁?"},
{C.dH,"经典块跟现代块是两个游戏,别拿多少年前水平秀优越,请从头练起。"},
{C.dH,"卖弱不是谦虚,请看场合。"},
{C.dH,"卖弱是要遭报应的"},
{C.dH,"满口PCDT信天翁,还会点别的么?"},
{C.dH,"没那水平别天天整什么花里胡哨的,人家玩了几年你想几天赶上?"},
{C.dH,"没学过编曲,音乐都是自己瞎写的,觉得不好听就去设置关了吧"},
{C.dH,"全隐40行全消四很难吗??"},
{C.dH,"少玩点游戏,多注意眨眼和休息,瞎了别怪我没提醒你"},
{C.dH,"设置都看过一遍了吗?明明都有还在那嫌弃,谁的问题?"},
{C.dH,"谁说一定要强的人才叫卖弱?不是最菜就一定在有人眼中是卖弱"},
{C.dH,"双旋和极简尽早学起来…懒得学以后亏的是自己"},
{C.dH,"天天催更催更,你咋不来帮忙开发啊,真以为作者很强催啥都能有?"},
{C.dH,"天天卖弱,你一定把把150apm吧?"},
{C.dH,"问怎么练就好好问,别就一句话怎么变强,鬼知道你现在什么水平"},
{C.dH,"先练基础不听,现在速度没有,Tspin完地形一塌糊涂,开心吗?"},
{C.dH,"一口一个wtcl还不赶紧去练,你是不思进取还是不想好好说话?"},
{C.dH,"隐形很难?上电视那个水平一般都打成那样,属实自己不行看不起别人"},
{C.dH,"隐形哪难了,你练了吗?没专门练几个小时就说难也太没耐心了吧"},
{C.dH,"有问题建议先找找是不是自己的问题,那么多人怎么就你事多?"},
{C.dH,"这不是休闲游戏…别怪关卡要求太高,就是你菜,请多练。"},
{C.dH,"Techmino没有抽卡没有氪金没有逼肝,良不良心自己没点数?"},
}
}

View File

@@ -153,7 +153,7 @@ return{
['dig_400l']= {"挖掘", "400L", "挖掘400行"},
['dig_1000l']= {"挖掘", "1000L", "挖掘1000行"},
['drought_n']= {"干旱", "100行", "你I没了"},
['drought_l']= {"干旱", "100行", "后 妈 发 牌"},
['drought_l']= {"干旱+", "100行", "后 妈 发 牌"},
['marathon_n']= {"马拉松", "普通", "200行加速马拉松"},
['marathon_h']= {"马拉松", "困难", "200行高速马拉松"},
['solo_e']= {"单挑", "简单", "打败机器人"},
@@ -206,6 +206,7 @@ return{
['pc_n']= {"全清挑战", "普通", "100行内刷全清"},
['pc_h']= {"全清挑战", "困难", "100行内刷全清"},
['pc_l']= {"全清挑战", "疯狂", "100行内刷全清"},
['pc_inf']= {"无尽全清挑战", "", "你能连续做多少PC?"},
['tech_n']= {"科研", "普通", "禁止断B2B"},
['tech_n_plus']= {"科研", "普通+", "仅允许回旋与全清"},
['tech_h']= {"科研", "困难", "禁止断B2B"},

View File

@@ -77,12 +77,13 @@ return{
{name='c4wtrain_n', x=700, y=-400, size=40,shape=1,icon="pc",unlock={'c4wtrain_l'}},
{name='c4wtrain_l', x=900, y=-400, size=40,shape=1,icon="pc"},
{name='pctrain_n', x=700, y=-220, size=40,shape=1,icon="pc", unlock={'pctrain_l','pc_n'}},
{name='pctrain_l', x=900, y=-220, size=40,shape=1,icon="pc"},
{name='pctrain_n', x=700, y=-250, size=40,shape=1,icon="pc", unlock={'pctrain_l','pc_n'}},
{name='pctrain_l', x=900, y=-250, size=40,shape=1,icon="pc"},
{name='pc_n', x=800, y=-100, size=40,shape=1,icon="pc", unlock={'pc_h'}},
{name='pc_h', x=1000, y=-100, size=40,shape=3,icon="pc", unlock={'pc_l'}},
{name='pc_l', x=1200, y=-100, size=40,shape=2,icon="pc"},
{name='pc_n', x=800, y=-110, size=40,shape=1,icon="pc", unlock={'pc_h'}},
{name='pc_h', x=950, y=-110, size=40,shape=3,icon="pc", unlock={'pc_l','pc_inf'}},
{name='pc_l', x=1100, y=-110, size=40,shape=3,icon="pc"},
{name='pc_inf', x=1100, y=-250, size=40,shape=2,icon="pc"},
{name='tech_n', x=400, y=-150, size=40,shape=1,icon="tech", unlock={'tech_n_plus','tech_h','tech_finesse'}},
{name='tech_n_plus', x=600, y=160, size=40,shape=3,icon="tech", unlock={'tsd_e','backfire_n'}},

View File

@@ -16,7 +16,7 @@ return{
load=function()
PLY.newPlayer(1)
if SETTING.sfx_spawn==0 then
LOG.print(text.switchSpawnSFX,COLOR.Y)
LOG.print(text.switchSpawnSFX,'warn')
end
end,
mesDisp=function(P)

View File

@@ -15,11 +15,11 @@ return{
mesDisp=function(P)
setFont(45)
local R=100-P.stat.row
mStr(R>=0 and R or 0,69,250)
mStr(R>=0 and R or 0,69,220)
setFont(75)
mStr(P.stat.pc,69,350)
mText(drawableText.pc,69,432)
setFont(70)
mStr(P.stat.pc,69,300)
mText(drawableText.pc,69,380)
end,
score=function(P)return{P.stat.pc,P.stat.time}end,
scoreDisp=function(D)return D[1].." PCs "..STRING.time(D[2])end,

46
parts/modes/pc_inf.lua Normal file
View File

@@ -0,0 +1,46 @@
return{
color=COLOR.red,
env={
drop=20,lock=60,
fall=10,
dropPiece=function(P)
if P.lastPiece.pc then
P.gameEnv.heightLimit=4
if P.stat.pc%10==0 then
P.gameEnv.drop=math.max(P.gameEnv.drop-1,1)
end
else
P.gameEnv.heightLimit=P.gameEnv.heightLimit-P.lastPiece.row
end
if #P.field>P.gameEnv.heightLimit then
P:lose()
end
end,
freshLimit=8,
heightLimit=4,
ospin=false,
bg='rgb',bgm='truth',
},
pauseLimit=true,
load=function()
PLY.newPlayer(1)
end,
mesDisp=function(P)
setFont(70)
mStr(P.stat.pc,69,300)
mText(drawableText.pc,69,380)
end,
score=function(P)return{P.stat.pc,P.stat.time}end,
scoreDisp=function(D)return D[1].." PCs "..STRING.time(D[2])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 L=P.stat.pc
return
L>=100 and 5 or
L>=70 and 4 or
L>=40 and 3 or
L>=20 and 2 or
L>=10 and 1 or
L>=5 and 0
end,
}

View File

@@ -15,11 +15,11 @@ return{
mesDisp=function(P)
setFont(45)
local R=100-P.stat.row
mStr(R>=0 and R or 0,69,250)
mStr(R>=0 and R or 0,69,220)
setFont(75)
mStr(P.stat.pc,69,350)
mText(drawableText.pc,69,432)
setFont(70)
mStr(P.stat.pc,69,300)
mText(drawableText.pc,69,380)
end,
score=function(P)return{P.stat.pc,P.stat.time}end,
scoreDisp=function(D)return D[1].." PCs "..STRING.time(D[2])end,

View File

@@ -13,11 +13,11 @@ return{
mesDisp=function(P)
setFont(45)
local R=100-P.stat.row
mStr(R>=0 and R or 0,69,250)
mStr(R>=0 and R or 0,69,220)
setFont(75)
mStr(P.stat.pc,69,350)
mText(drawableText.pc,69,432)
setFont(70)
mStr(P.stat.pc,69,300)
mText(drawableText.pc,69,380)
end,
score=function(P)return{P.stat.pc,P.stat.time}end,
scoreDisp=function(D)return D[1].." PCs "..STRING.time(D[2])end,

View File

@@ -63,9 +63,9 @@ return{
check(PLAYERS[1])
end,
mesDisp=function(P)
setFont(75)
mStr(P.stat.pc,69,330)
mText(drawableText.pc,69,412)
setFont(70)
mStr(P.stat.pc,69,300)
mText(drawableText.pc,69,380)
end,
score=function(P)return{P.stat.pc,P.stat.time}end,
scoreDisp=function(D)return D[1].." PCs "..STRING.time(D[2])end,

View File

@@ -54,9 +54,9 @@ return{
check(PLAYERS[1])
end,
mesDisp=function(P)
setFont(75)
mStr(P.stat.pc,69,330)
mText(drawableText.pc,69,412)
setFont(70)
mStr(P.stat.pc,69,300)
mText(drawableText.pc,69,380)
end,
score=function(P)return{P.stat.pc,P.stat.time}end,
scoreDisp=function(D)return D[1].." PCs "..STRING.time(D[2])end,

View File

@@ -2,7 +2,7 @@ return{
color=COLOR.magenta,
env={
drop=30,lock=60,
freshLimit=10,
freshLimit=5,
task=function(P)
while true do
YIELD()

View File

@@ -2,7 +2,7 @@ return{
color=COLOR.red,
env={
drop=30,lock=60,
freshLimit=10,
freshLimit=5,
task=function(P)
while true do
YIELD()

View File

@@ -20,8 +20,9 @@ local NET={
},
allReady=false,
connectingStream=false,
streamRoomID=false,
waitingStream=false,
serverGaming=false,
streamRoomID=false,
UserCount="_",
PlayCount="_",
@@ -298,21 +299,21 @@ function NET.updateWS_app()
end
end
if VERSION.code<res.newestCode then
LOG.print(text.oldVersion:gsub("$1",res.newestName),180,COLOR.N)
LOG.print(text.oldVersion:gsub("$1",res.newestName),180,'message')
end
LOG.print(res.notice,300,COLOR.N)
LOG.print(res.notice,300,'message')
elseif res.action==0 then--Get new version info
--?
elseif res.action==1 then--Get notice
--?
elseif res.action==2 then--Register
if res.type=='Self'or res.type=='Server'then
LOG.print(res.data.message,300,COLOR.N)
LOG.print(res.data.message,300,'message')
if SCN.cur=='register'then
SCN.back()
end
else
LOG.print(res.reason or"Registration failed",300,COLOR.N)
LOG.print(res.reason or"Registration failed",300,'message')
end
NET.unlock('register')
elseif res.action==3 then--Get player counts
@@ -351,14 +352,14 @@ function NET.updateWS_user()
FILE.save(USER,'conf/user','q')
if SCN.cur=='login'then SCN.back()end
end
LOG.print(text.loginSuccessed)
LOG.print(text.loginSuccessed,'message')
--Get self infos
NET.getUserInfo(USER.uid)
NET.unlock('wsc_user')
elseif res.action==0 then--Get accessToken
NET.accessToken=res.accessToken
LOG.print(text.accessSuccessed)
LOG.print(text.accessSuccessed,'message')
NET.wsconn_play()
elseif res.action==1 then--Get userInfo
USERS.updateUserData(res.data)
@@ -482,14 +483,18 @@ function NET.updateWS_stream()
local d=res.data
if res.type=='Connect'then
NET.unlock('wsc_stream')
elseif res.action==0 then--Game start
NET.connectingStream=false
NET.waitingStream=true
netPLY.setConnect(USER.uid)
netPLY.freshStreamConn(res.data.connected)
elseif res.action==0 then--Game start
NET.waitingStream=false
if SCN.socketRead then SCN.socketRead('go',d)end
NET.roomInfo.start=true
elseif res.action==1 then--Game finished
--?
elseif res.action==2 then--Player join
--?
netPLY.setConnect(d.uid)
elseif res.action==3 then--Player leave
--?
elseif res.action==4 then--Player died

View File

@@ -87,6 +87,7 @@ end
function netPLY.clear()for _=1,netPLY.getCount()do rem(PLY)end end
function netPLY.add(p)
p.connected=false
ins(PLY,p.uid==USER.uid and 1 or #PLY+1,p)
local a=rnd()*6.2832
p.x,p.y,p.w,p.h=640+2600*cos(a),360+2600*sin(a),47,47
@@ -101,7 +102,6 @@ function netPLY.rawgetPLY(i)return PLY[i]end
function netPLY.getUsername(uid)return getPLY(uid).username end
function netPLY.getSID(uid)return getPLY(uid).sid end
function netPLY.getSelfReady()return PLY[1].ready end
function netPLY.setPlayerObj(ply,p)ply.p=p end
function netPLY.setConf(uid,config)getPLY(uid).config=config end
function netPLY.setReady(uid,ready)
@@ -126,9 +126,23 @@ function netPLY.setReady(uid,ready)
end
end
end
function netPLY.resetReady()
function netPLY.setConnect(uid)
for _,p in next,PLY do
if p.uid==uid then
p.connected=true
return
end
end
end
function netPLY.freshStreamConn(list)
for _,p in next,list do
getPLY(p.uid).connected=true
end
end
function netPLY.resetState()
for i=1,#PLY do
PLY[i].ready=false
PLY[i].connected=false
end
end
@@ -165,7 +179,7 @@ function netPLY.draw()
local p=PLY[i]
gc.translate(p.x,p.y)
--Rectangle
gc.setColor(COLOR[p.ready and'G'or'Z'])
gc.setColor(COLOR[p.connected and"N"or p.ready and'A'or'Z'])
gc.setLineWidth(2)
gc.rectangle('line',0,0,p.w,p.h)

View File

@@ -116,16 +116,16 @@ local function tapBoard(x,y,key)
if checkBoard(b)then
state=2
time=TIME()-startTime
if time<1 then LOG.print("不是人",COLOR.lB)
elseif time<2 then LOG.print("还是人",COLOR.lB)
elseif time<3 then LOG.print("神仙",COLOR.lB)
elseif time<5 then LOG.print("太强了",COLOR.lB)
elseif time<7.5 then LOG.print("很强",COLOR.lB)
elseif time<10 then LOG.print("可以的",COLOR.lB)
elseif time<20 then LOG.print("马上入门了",COLOR.lB)
elseif time<30 then LOG.print("入门不远了",COLOR.lB)
elseif time<60 then LOG.print("多加练习",COLOR.lB)
else LOG.print("第一次玩?加油",COLOR.lB)
if time<1 then LOG.print("不是人")
elseif time<2 then LOG.print("还是人")
elseif time<3 then LOG.print("神仙")
elseif time<5 then LOG.print("太强了")
elseif time<7.5 then LOG.print("很强")
elseif time<10 then LOG.print("可以的")
elseif time<20 then LOG.print("马上入门了")
elseif time<30 then LOG.print("入门不远了")
elseif time<60 then LOG.print("多加练习")
else LOG.print("第一次玩?加油")
end
SFX.play('win')
return

View File

@@ -82,7 +82,7 @@ function scene.keyDown(key)
str=str.."!"
if #MISSION>0 then str=str..DATA.copyMission()end
sys.setClipboardText(str.."!"..DATA.copyBoards().."!")
LOG.print(text.exportSuccess,COLOR.G)
LOG.print(text.exportSuccess,'message')
elseif key=="v"and kb.isDown("lctrl","rctrl")or key=="cV"then
local str=sys.getClipboardText()
local args=STRING.split(str:sub((str:find(":")or 0)+1),"!")
@@ -98,9 +98,9 @@ function scene.keyDown(key)
if args[i]:find("%S")and not DATA.pasteBoard(args[i],i-3)and i<#args then goto THROW_fail end
end
freshMiniFieldVisible()
LOG.print(text.importSuccess,COLOR.G)
LOG.print(text.importSuccess,'message')
do return end
::THROW_fail::LOG.print(text.dataCorrupted,COLOR.R)
::THROW_fail::LOG.print(text.dataCorrupted,'error')
elseif key=="escape"then
FILE.save(CUSTOMENV,'conf/customEnv','q')
SCN.back()

View File

@@ -1,6 +1,6 @@
local sList={
visible={"show","easy","slow","medium","fast","none"},
freshLimit={0,8,15,1e99},
freshLimit={0,1,2,4,6,8,10,12,15,30,1e99},
opponent={"X","9S Lv.1","9S Lv.2","9S Lv.3","9S Lv.4","9S Lv.5","CC Lv.1","CC Lv.2","CC Lv.3","CC Lv.4","CC Lv.5"},
life={0,1,2,3,5,10,15,26,42,87,500},
pushSpeed={1,2,3,5,15},

View File

@@ -216,21 +216,21 @@ function scene.keyDown(key)
SFX.play('fall',.8)
elseif key=="c"and kb.isDown("lctrl","rctrl")or key=="cC"then
sys.setClipboardText("Techmino Field:"..DATA.copyBoard(page))
LOG.print(text.exportSuccess,COLOR.G)
LOG.print(text.exportSuccess,'message')
elseif key=="v"and kb.isDown("lctrl","rctrl")or key=="cV"then
local str=sys.getClipboardText()
local p=str:find(":")--ptr*
if p then
if not str:sub(1,p-1):find("Field")then
LOG.print(text.pasteWrongPlace)
LOG.print(text.pasteWrongPlace,'warn')
end
str=str:sub(p+1)
end
if DATA.pasteBoard(str,page)then
LOG.print(text.importSuccess,COLOR.G)
LOG.print(text.importSuccess,'message')
else
print(text.dataCorrupted)
LOG.print(text.dataCorrupted,COLOR.R)
LOG.print(text.dataCorrupted,'error')
end
elseif key=="pageup"then
page=max(page-1,1)

View File

@@ -71,22 +71,22 @@ function scene.keyDown(key)
elseif key=="c"and kb.isDown("lctrl","rctrl")or key=="cC"then
if #MISSION>0 then
sys.setClipboardText("Techmino Target:"..DATA.copyMission())
LOG.print(text.exportSuccess,COLOR.G)
LOG.print(text.exportSuccess,'message')
end
elseif key=="v"and kb.isDown("lctrl","rctrl")or key=="cV"then
local str=sys.getClipboardText()
local p=str:find(":")--ptr*
if p then
if not str:sub(1,p-1):find("Target")then
LOG.print(text.pasteWrongPlace)
LOG.print(text.pasteWrongPlace,'warn')
end
str=str:sub(p+1)
end
if DATA.pasteMission(str)then
LOG.print(text.importSuccess,COLOR.G)
LOG.print(text.importSuccess,'message')
cur=#MISSION
else
LOG.print(text.dataCorrupted,COLOR.R)
LOG.print(text.dataCorrupted,'error')
end
elseif key=="escape"then
SCN.back()

View File

@@ -85,22 +85,22 @@ function scene.keyDown(key)
elseif key=="c"and kb.isDown("lctrl","rctrl")or key=="cC"then
if #BAG>0 then
sys.setClipboardText("Techmino SEQ:"..DATA.copySequence())
LOG.print(text.exportSuccess,COLOR.G)
LOG.print(text.exportSuccess,'message')
end
elseif key=="v"and kb.isDown("lctrl","rctrl")or key=="cV"then
local str=sys.getClipboardText()
local p=str:find(":")--ptr*
if p then
if not str:sub(1,p-1):find("SEQ")then
LOG.print(text.pasteWrongPlace)
LOG.print(text.pasteWrongPlace,'warn')
end
str=str:sub(p+1)
end
if DATA.pasteSequence(str)then
LOG.print(text.importSuccess,COLOR.G)
LOG.print(text.importSuccess,'message')
cur=#BAG
else
LOG.print(text.dataCorrupted,COLOR.R)
LOG.print(text.dataCorrupted,'error')
end
elseif key=="escape"then
SCN.back()

View File

@@ -6,9 +6,9 @@ local savePW=false
local function login()
local email,password=emailBox:getText(),passwordBox:getText()
if not STRING.simpEmailCheck(email)then
LOG.print(text.wrongEmail)return
LOG.print(text.wrongEmail,'warn')return
elseif #password==0 then
LOG.print(text.noPassword)return
LOG.print(text.noPassword,'warn')return
end
NET.wsconn_user_pswd(email,password)
if savePW then

View File

@@ -77,6 +77,7 @@ function scene.keyDown(key)
else
TEXT.show(text.noInternet,640,450,60,'flicker')
NET.wsconn_app()
LOG.print(text.wsConnecting,'message')
SFX.play('finesseError')
end
end

View File

@@ -46,7 +46,6 @@ function scene.touchDown(x,y)
end
function scene.touchUp(x,y)
if not playing or noTouch then return end
local n=VK.on(x,y)
if n then
PLAYERS[1]:releaseKey(n)
@@ -54,7 +53,7 @@ function scene.touchUp(x,y)
end
end
function scene.touchMove(x,y)
if not playing then netPLY.mouseMove(x,y)end
if not playing then netPLY.mouseMove(x,y)return end
if touchMoveLastFrame or noTouch then return end
touchMoveLastFrame=true
@@ -83,7 +82,7 @@ function scene.keyDown(key)
NET.signal_quit()
else
lastBackTime=TIME()
LOG.print(text.sureQuit,COLOR.O)
LOG.print(text.sureQuit,'warn')
end
elseif key=="return"then
if inputBox.hide then
@@ -92,7 +91,7 @@ function scene.keyDown(key)
TASK.new(function()YIELD()WIDGET.sel=inputBox end)
enableTextInput()
else
local mes=inputBox:getText():match"%S+"
local mes=STRING.trim(inputBox:getText())
if mes and #mes>0 then
NET.sendMessage(mes)
inputBox:clear()
@@ -107,7 +106,7 @@ function scene.keyDown(key)
WIDGET.sel=inputBox
WIDGET.keyPressed(key)
elseif playing then
if noKey then return end
if not playing or noKey then return end
local k=keyMap.keyboard[key]
if k and k>0 then
PLAYERS[1]:pressKey(k)
@@ -124,7 +123,7 @@ function scene.keyDown(key)
end
end
function scene.keyUp(key)
if noKey then return end
if not playing or noKey then return end
local k=keyMap.keyboard[key]
if k and k>0 then
PLAYERS[1]:releaseKey(k)
@@ -133,13 +132,9 @@ function scene.keyUp(key)
end
function scene.gamepadDown(key)
if key=="back"then
if TIME()-lastBackTime<1 then
NET.signal_quit()
else
lastBackTime=TIME()
LOG.print(text.sureQuit,COLOR.O)
end
scene.keyDown("escape")
else
if not playing then return end
local k=keyMap.joystick[key]
if k and k>0 then
PLAYERS[1]:pressKey(k)
@@ -148,6 +143,7 @@ function scene.gamepadDown(key)
end
end
function scene.gamepadUp(key)
if not playing then return end
local k=keyMap.joystick[key]
if k and k>0 then
PLAYERS[1]:releaseKey(k)
@@ -179,13 +175,13 @@ function scene.socketRead(cmd,d)
if not playing then
playing=true
love.keyboard.setKeyRepeat(false)
netPLY.resetReady()
netPLY.resetState()
netPLY.mouseMove(0,0)
lastUpstreamTime=0
upstreamProgress=1
resetGameData('n',d.seed)
else
LOG.print("Redundant [Go]",30,COLOR.G)
LOG.print("Redundant [Go]",'warn')
end
elseif cmd=='finish'then
playing=false
@@ -208,7 +204,7 @@ function scene.socketRead(cmd,d)
if res then
DATA.pumpRecording(stream,P.stream)
else
LOG.print("Bad stream from "..P.username.."#"..P.uid)
LOG.print("Bad stream from "..P.username.."#"..P.uid,30)
end
end
end
@@ -269,12 +265,16 @@ function scene.draw()
netPLY.draw()
--Ready & Set mark
gc.setColor(.1,1,0,.9)
setFont(60)
if NET.connectingStream then
mStr(text.set,640,10)
elseif NET.allReady then
mStr(text.ready,640,10)
setFont(50)
if NET.allReady then
gc.setColor(0,1,.5,.9)
mStr(text.ready,640,15)
elseif NET.connectingStream then
gc.setColor(.1,1,.8,.9)
mStr(text.connStream,640,15)
elseif NET.waitingStream then
gc.setColor(0,.8,1,.9)
mStr(text.waitStream,640,15)
end
--Room info.

View File

@@ -31,7 +31,7 @@ scene.widgetList={
SCN.back()
end
else
LOG.print(text.sureQuit,COLOR.O)
LOG.print(text.sureQuit,'warn')
lastLogoutTime=TIME()
end
end},

View File

@@ -19,6 +19,7 @@ function scene.sceneInit()
BG.set()
NET.allReady=false
NET.connectingStream=false
NET.waitingStream=false
scrollPos=0
selected=1
fetchRoom()
@@ -74,7 +75,7 @@ function scene.keyDown(k)
elseif k=="return"then
if NET.getlock('fetchRoom')or not NET.roomList[selected]then return end
if NET.roomList[selected].private then
LOG.print("Can't enter private room now")
LOG.print("Can't enter private room now",'message')
return
end
NET.enterRoom(NET.roomList[selected])--,password

View File

@@ -122,7 +122,7 @@ function scene.sceneBack()
STAT.todayTime=STAT.todayTime+PLAYERS[1].stat.time
if not GAME.replaying and(PLAYERS[1].frameRun>400 or GAME.result)and not GAME.result then
mergeStat(STAT,PLAYERS[1].stat)
FILE.save(STAT,'conf/data')
FILE.save(STAT,'conf/data','q')
end
end

View File

@@ -6,13 +6,13 @@ local function register()
local password= WIDGET.active.password:getText()
local password2=WIDGET.active.password2:getText()
if #username==0 then
LOG.print(text.noUsername)return
LOG.print(text.noUsername,'warn')return
elseif not STRING.simpEmailCheck(email)then
LOG.print(text.wrongEmail)return
LOG.print(text.wrongEmail,'warn')return
elseif #password==0 or #password2==0 then
LOG.print(text.noPassword)return
LOG.print(text.noPassword,'warn')return
elseif password~=password2 then
LOG.print(text.diffPassword)return
LOG.print(text.diffPassword,'warn')return
end
NET.register(username,email,password)
end

View File

@@ -10,7 +10,7 @@ local function dumpCB(T)
)
)
)
LOG.print(text.exportSuccess)
LOG.print(text.exportSuccess,'message')
end
local function parseCB()
local _
@@ -18,9 +18,9 @@ local function parseCB()
--Decode
_,s=pcall(love.data.decode,'string','base64',s)
if not _ then LOG.print(text.dataCorrupted,COLOR.R)return end
if not _ then LOG.print(text.dataCorrupted,'error')return end
_,s=pcall(love.data.decompress,'string','zlib',s)
if not _ then LOG.print(text.dataCorrupted,COLOR.R)return end
if not _ then LOG.print(text.dataCorrupted,'error')return end
s=loadstring(s)
if s then

View File

@@ -188,7 +188,7 @@ scene.widgetList={
B.x,B.y,B.r=T[2],T[3],T[4]
end
end
LOG.print(("[ %d ]"):format(defaultSetSelect))
LOG.print(("==[ %d ]=="):format(defaultSetSelect))
defaultSetSelect=defaultSetSelect%5+1
selected=false
end},

View File

@@ -18,12 +18,25 @@ return STRING.split([=[
区分各种消除(隔断/架空/混合/彩色/穿墙)
更复杂的垃圾行(数量/等待时间/抵消倍率/洞数/连接/炸弹/厚度)
可调场地宽度; 左右三按键; 手势操作; 特殊控件(虚拟摇杆等); 切换高低镜头键
DAS系统和Deepdrop系统更细节的选项; spike计数器; 攻击总缓冲显示
成就系统; 更强的主题系统; 多方块; 3D背景; TGM3的开局无限hold调整序列
DAS系统和Deepdrop系统更细节的选项; spike计数器
成就系统; 更强的主题系统; 多方块; 3D背景
工程编译到字节码; task-Z(新AI); 开房机制修改
等级系统; 旁观; 收集向抽奖玩法
录像回放菜单; 跳帧开关; 教学关; 超60帧; 热更新
0.14.8: 冰激凌 Icecream
新增:
新增无尽pc挑战模式
联网对战游戏开始前可以显示其他玩家的连接状态
改动:
增加自定义游戏锁延刷新次数挡位
减少生存模式最高两个难度的锁延刷新次数
代码:
简化LOG模块用法
textBox控件在隐藏时也会自动滚动
修复:
聊天窗带空格的消息会被截断
0.14.7: 烈日 Burn
新增:
屏幕下方版本号常驻显示
@@ -51,6 +64,7 @@ return STRING.split([=[
控制台支持滚轮和键盘导航
缩短联网ping间隔和自我认定掉线时间
调整rnd出块算法的一些细节
更新naki立绘
代码:
控件系统hide机制大改
场景模块支持拖拽文件(夹)事件