Compare commits
30 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
b04131b408 | ||
|
|
e93ef851ac | ||
|
|
4d7f2e6698 | ||
|
|
abf827bc2b | ||
|
|
ee25d35220 | ||
|
|
eef8e594a2 | ||
|
|
5edeffbda4 | ||
|
|
af4df9c2e2 | ||
|
|
ac18ad2fcd | ||
|
|
1d293bb186 | ||
|
|
99611910de | ||
|
|
632c88c5f8 | ||
|
|
a3d6155096 | ||
|
|
af3fc34098 | ||
|
|
dbd261fbf1 | ||
|
|
19a7a322c5 | ||
|
|
36cf0aaf8e | ||
|
|
32b0937ad9 | ||
|
|
13b176d515 | ||
|
|
81aab6bdb3 | ||
|
|
23abf14888 | ||
|
|
79f49fab4d | ||
|
|
e732aae87b | ||
|
|
cf3ca2e9e0 | ||
|
|
1030330add | ||
|
|
b82e3b873b | ||
|
|
b0f885ab2c | ||
|
|
2758a2eb03 | ||
|
|
6c012aa0ad | ||
|
|
52a3c01829 |
@@ -78,7 +78,7 @@ end
|
||||
|
||||
local list_dark={"dRed","dFire","dOrange","dYellow","dLame","dGrass","dGreen","dWater","dCyan","dSky","dSea","dBlue","dPurple","dGrape","dMagenta","dPink"}
|
||||
local len_list_dark=#list_dark
|
||||
function COLOR.random_bright()
|
||||
function COLOR.random_dark()
|
||||
return COLOR[list_dark[rnd(len_list_dark)]]
|
||||
end
|
||||
|
||||
@@ -89,5 +89,23 @@ function COLOR.rainbow(phase)
|
||||
sin(phase+2.0944)*.4+.6,
|
||||
sin(phase-2.0944)*.4+.6
|
||||
end
|
||||
function COLOR.rainbow_light(phase)
|
||||
return
|
||||
sin(phase)*.2+.7,
|
||||
sin(phase+2.0944)*.2+.7,
|
||||
sin(phase-2.0944)*.2+.7
|
||||
end
|
||||
function COLOR.rainbow_dark(phase)
|
||||
return
|
||||
sin(phase)*.2+.4,
|
||||
sin(phase+2.0944)*.2+.4,
|
||||
sin(phase-2.0944)*.2+.4
|
||||
end
|
||||
function COLOR.rainbow_grey(phase)
|
||||
return
|
||||
sin(phase)*.16+.5,
|
||||
sin(phase+2.0944)*.16+.5,
|
||||
sin(phase-2.0944)*.16+.5
|
||||
end
|
||||
|
||||
return COLOR
|
||||
@@ -12,7 +12,7 @@ function FILE.load(name)
|
||||
return s()
|
||||
else
|
||||
LOG.print(name.." "..text.loadError,COLOR.red)
|
||||
return{}
|
||||
return
|
||||
end
|
||||
else
|
||||
local res=json.decode(s)
|
||||
@@ -20,7 +20,7 @@ function FILE.load(name)
|
||||
return res
|
||||
else
|
||||
LOG.print(name.." "..text.loadError,COLOR.red)
|
||||
return{}
|
||||
return
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
@@ -29,7 +29,6 @@ local int,rnd,abs=math.floor,math.random,math.abs
|
||||
local min=math.min
|
||||
local ins,rem=table.insert,table.remove
|
||||
local SCR=SCR
|
||||
local setFont=setFont
|
||||
|
||||
local mx,my,mouseShow=-20,-20,false
|
||||
local touching=nil--First touching ID(userdata)
|
||||
@@ -306,7 +305,7 @@ function love.receiveData(id,data)end
|
||||
local lastGCtime=0
|
||||
function love.lowmemory()
|
||||
if love.timer.getTime()-lastGCtime>2.6 then
|
||||
lastGCtime=love.timer.getTime
|
||||
lastGCtime=TIME()
|
||||
collectgarbage()
|
||||
LOG.print("[Auto GC] Low Memory!","warn")
|
||||
end
|
||||
@@ -418,7 +417,7 @@ function love.run()
|
||||
local SCN=SCN
|
||||
local SETTING=SETTING
|
||||
|
||||
local Timer=love.timer.getTime
|
||||
local TIME=love.timer.getTime
|
||||
local STEP,WAIT=love.timer.step,love.timer.sleep
|
||||
local MINI=love.window.isMinimized
|
||||
local PUMP,POLL=love.event.pump,love.event.poll
|
||||
@@ -427,7 +426,7 @@ function love.run()
|
||||
|
||||
local frameTimeList={}
|
||||
|
||||
local lastFrame=Timer()
|
||||
local lastFrame=TIME()
|
||||
local lastFreshPow=lastFrame
|
||||
local FCT=0--Framedraw counter, from 0~99
|
||||
|
||||
@@ -443,9 +442,9 @@ function love.run()
|
||||
return function()
|
||||
local _
|
||||
|
||||
local T=Timer()
|
||||
local dt=T-lastFrame
|
||||
lastFrame=T
|
||||
local t=TIME()
|
||||
local dt=t-lastFrame
|
||||
lastFrame=t
|
||||
|
||||
--EVENT
|
||||
PUMP()
|
||||
@@ -490,11 +489,11 @@ function love.run()
|
||||
|
||||
--Draw cursor
|
||||
if mouseShow then
|
||||
local r=T*.5
|
||||
local r=t*.5
|
||||
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,T%3.1416*4,20,20,spinCenters[R][0][2]+.5,#BLOCKS[R][0]-spinCenters[R][0][1]-.5)
|
||||
gc.draw(TEXTURE.miniBlock[R],mx,my,t%3.1416*4,20,20,spinCenters[R][0][2]+.5,#BLOCKS[R][0]-spinCenters[R][0][1]-.5)
|
||||
gc.setColor(1,1,1,.5)gc.circle("fill",mx,my,5)
|
||||
gc.setColor(1,1,1)gc.circle("fill",mx,my,3)
|
||||
end
|
||||
@@ -517,8 +516,8 @@ function love.run()
|
||||
--Draw network working
|
||||
if TASK.netTaskCount>0 then
|
||||
setFont(30)
|
||||
gc.setColor(COLOR.rainbow(T*5))
|
||||
gc.print("E",1250,0,.26+.355*math.sin(T*6.26))
|
||||
gc.setColor(COLOR.rainbow(t*5))
|
||||
gc.print("E",SCR.safeW-18,17,.26+.355*math.sin(t*6.26),nil,nil,8,20)
|
||||
end
|
||||
|
||||
--Draw FPS
|
||||
@@ -552,10 +551,10 @@ function love.run()
|
||||
end
|
||||
|
||||
--Fresh power info.
|
||||
if Timer()-lastFreshPow>2.6 then
|
||||
if TIME()-lastFreshPow>2.6 then
|
||||
if SETTING.powerInfo and LOADED then
|
||||
updatePowerInfo()
|
||||
lastFreshPow=Timer()
|
||||
lastFreshPow=TIME()
|
||||
end
|
||||
if gc.getWidth()~=SCR.w then
|
||||
love.resize(gc.getWidth(),gc.getHeight())
|
||||
@@ -563,8 +562,8 @@ function love.run()
|
||||
end
|
||||
|
||||
--Keep 60fps
|
||||
_=Timer()-lastFrame
|
||||
_=TIME()-lastFrame
|
||||
if _<.016 then WAIT(.016-_)end
|
||||
while Timer()-lastFrame<1/60-5e-6 do WAIT(0)end
|
||||
while TIME()-lastFrame<1/60-5e-6 do WAIT(0)end
|
||||
end
|
||||
end
|
||||
@@ -1,25 +1,4 @@
|
||||
local function langFallback(T0,T)
|
||||
for k,v in next,T0 do
|
||||
if type(v)=="table"and not v.refuseCopy then--refuseCopy: just copy pointer, not contents
|
||||
if not T[k]then T[k]={}end
|
||||
if type(T[k])=="table"then langFallback(v,T[k])end
|
||||
elseif not T[k]then
|
||||
T[k]=v
|
||||
end
|
||||
end
|
||||
end
|
||||
local tipMeta={__call=function(L)return L[math.random(#L)]end}
|
||||
|
||||
local langList={}
|
||||
local publicText,publicWidgetText={},{}
|
||||
local function lang_set(l)
|
||||
text=langList[l]
|
||||
WIDGET.setLang(text.WidgetText)
|
||||
for _,s in next,drawableTextLoad do
|
||||
drawableText[s]:set(text[s])
|
||||
end
|
||||
end
|
||||
|
||||
local langList,publicText,publicWidgetText={},{},{}
|
||||
local LANG={}
|
||||
|
||||
--Call these before call LANG.init()
|
||||
@@ -27,7 +6,19 @@ function LANG.setLangList(list)langList=list end
|
||||
function LANG.setPublicText(L)publicText=L end
|
||||
function LANG.setPublicWidgetText(L)publicWidgetText=L end
|
||||
|
||||
function LANG.init()--Attention, calling this will DESTORY ALL METHODS, only left LANG.set()!
|
||||
function LANG.init()--Attention, calling this will destory all initializing methods, create a LANG.set()!
|
||||
local function langFallback(T0,T)
|
||||
for k,v in next,T0 do
|
||||
if type(v)=="table"and not v.refuseCopy then--refuseCopy: just copy pointer, not contents
|
||||
if not T[k]then T[k]={}end
|
||||
if type(T[k])=="table"then langFallback(v,T[k])end
|
||||
elseif not T[k]then
|
||||
T[k]=v
|
||||
end
|
||||
end
|
||||
end
|
||||
local tipMeta={__call=function(L)return L[math.random(#L)]end}
|
||||
|
||||
for i=1,#langList do
|
||||
local L=langList[i]
|
||||
|
||||
@@ -60,8 +51,16 @@ function LANG.init()--Attention, calling this will DESTORY ALL METHODS, only lef
|
||||
v.back=L.back
|
||||
end
|
||||
end
|
||||
|
||||
LANG.init,LANG.setLangList,LANG.setPublicText,LANG.setPublicWidgetText=nil
|
||||
LANG.set=lang_set
|
||||
|
||||
function LANG.set(l)
|
||||
text=langList[l]
|
||||
WIDGET.setLang(text.WidgetText)
|
||||
for _,s in next,drawableTextLoad do
|
||||
drawableText[s]:set(text[s])
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
return LANG
|
||||
@@ -21,11 +21,11 @@ do--LOADLIB
|
||||
function LOADLIB(name)
|
||||
local libName=libs[name]
|
||||
if SYSTEM=="Windows"or SYSTEM=="Linux"then
|
||||
local success,message=require(libName[SYSTEM])
|
||||
if success then
|
||||
return success
|
||||
local r1,r2,r3=pcall(require,libName[SYSTEM])
|
||||
if r1 and r2 then
|
||||
return r2
|
||||
else
|
||||
LOG.print("Cannot load "..name..": "..message,"warn",COLOR.red)
|
||||
LOG.print("Cannot load "..name..": "..(r2 or r3),"warn",COLOR.red)
|
||||
end
|
||||
elseif SYSTEM=="Android"then
|
||||
local fs=love.filesystem
|
||||
@@ -36,7 +36,7 @@ do--LOADLIB
|
||||
if soFile then
|
||||
local success,message=fs.write(libName.Android,soFile,size)
|
||||
if success then
|
||||
libFunc,message=package.loadlib(table.concat({fs.getSaveDirectory(),libName.Android},"/"),libName.libFunc)
|
||||
libFunc,message=package.loadlib(table.concat({SAVEDIR,libName.Android},"/"),libName.libFunc)
|
||||
if libFunc then
|
||||
LOG.print(name.." lib loaded","warn",COLOR.green)
|
||||
break
|
||||
@@ -51,7 +51,7 @@ do--LOADLIB
|
||||
end
|
||||
end
|
||||
if not libFunc then
|
||||
LOG.print("failed to load "..name,"warn",COLOR.red)
|
||||
LOG.print("Cannot load "..name,"warn",COLOR.red)
|
||||
return
|
||||
end
|
||||
return libFunc()
|
||||
|
||||
@@ -1,10 +1,9 @@
|
||||
local gc=love.graphics
|
||||
local kb=love.keyboard
|
||||
|
||||
local int,abs=math.floor,math.abs
|
||||
local max,min=math.max,math.min
|
||||
local sub,format=string.sub,string.format
|
||||
|
||||
local Timer=love.timer.getTime
|
||||
local setFont,mStr=setFont,mStr
|
||||
|
||||
local WIDGET={}
|
||||
@@ -463,8 +462,8 @@ function slider:drag(x)
|
||||
if p~=P then
|
||||
self.code(P)
|
||||
end
|
||||
if self.change and Timer()-self.lastTime>.18 then
|
||||
self.lastTime=Timer()
|
||||
if self.change and TIME()-self.lastTime>.18 then
|
||||
self.lastTime=TIME()
|
||||
self.change()
|
||||
end
|
||||
end
|
||||
@@ -478,8 +477,8 @@ function slider:arrowKey(isLeft)
|
||||
local P=isLeft and max(p-u,0)or min(p+u,self.unit)
|
||||
if p==P or not P then return end
|
||||
self.code(P)
|
||||
if self.change and Timer()-self.lastTime>.18 then
|
||||
self.lastTime=Timer()
|
||||
if self.change and TIME()-self.lastTime>.18 then
|
||||
self.lastTime=TIME()
|
||||
self.change()
|
||||
end
|
||||
end
|
||||
@@ -584,7 +583,7 @@ function selector:draw()
|
||||
gc.rectangle("line",x,y,w,60)
|
||||
|
||||
gc.setColor(1,1,1,.2+ATV*.1)
|
||||
local t=(Timer()%.5)^.5
|
||||
local t=(TIME()%.5)^.5
|
||||
if self.select>1 then
|
||||
gc.draw(drawableText.small,x+6,y+20)
|
||||
if ATV>0 then
|
||||
@@ -946,8 +945,8 @@ function WIDGET.gamepadPressed(i)
|
||||
local P=i=="left"and(p>0 and p-1)or p<W.unit and p+1
|
||||
if p==P or not P then return end
|
||||
W.code(P)
|
||||
if W.change and Timer()-W.lastTime>.18 then
|
||||
W.lastTime=Timer()
|
||||
if W.change and TIME()-W.lastTime>.18 then
|
||||
W.lastTime=TIME()
|
||||
W.change()
|
||||
end
|
||||
end
|
||||
|
||||
4
conf.lua
@@ -1,5 +1,5 @@
|
||||
VERSION_CODE=1206
|
||||
VERSION_NAME="Alpha V0.12.6"
|
||||
VERSION_CODE=1208
|
||||
VERSION_NAME="Alpha V0.12.8"
|
||||
love.setDeprecationOutput(false)
|
||||
function love.conf(t)
|
||||
t.identity="Techmino"--Saving folder
|
||||
|
||||
@@ -41,12 +41,12 @@ spin判定:
|
||||
没有用上的额外抵挡会被丢弃,最后剩下的攻击力会发送给对手
|
||||
|
||||
back to back(B2B)点数说明:
|
||||
B2B点数的范围在0~1200,在点数>=40时进行特殊消除为B2B,>1000时特殊消除为B3B
|
||||
B2B点数的范围在0~1000,在点数>=50时进行特殊消除为B2B,>800时特殊消除为B3B
|
||||
普通消除:-250
|
||||
spin1~5:+[50/100/180/1000/1200](mini变为原来25%)
|
||||
spin1~5:+[50/100/180/800/1000](mini变为原来50%)
|
||||
消四/五:+[100/200]
|
||||
空spin:+20,此法得到的点数不能超过1000
|
||||
当点数在1000以上时空放一块-40(不低于1000)
|
||||
空spin:+20,此法得到的点数不能超过800
|
||||
当点数在800以上时空放一块-40(不低于800)
|
||||
|
||||
混战模式说明:
|
||||
许多玩家同时进行一局游戏(对手都是AI,不是真人).随着玩家数量的减少,方块下落/垃圾生效速度/垃圾升起速度都会增加.淘汰其它玩家后可以获得一个徽章和该玩家持有的徽章,增强自己的攻击力.
|
||||
|
||||
@@ -43,12 +43,12 @@ Countering:
|
||||
Any extra blocking you didn't use will be discarded, and finally the remaining attack power will be sent to your opponent.
|
||||
|
||||
Back to Back (B2B) gauge:
|
||||
The B2B gauge ranges from 0 to 1,200. Special line clears are B2B if the gauge is >=40, B2B2B if >1,000.
|
||||
The B2B gauge ranges from 0 to 1,000. Special line clears are B2B if the gauge is >=50, B2B2B if >800.
|
||||
A regular line clear -250
|
||||
Spin Single/Double/Triple/Techrash/Techrash+ +50/100/180/1000/1200 (x25% if Mini)
|
||||
Spin Single/Double/Triple/Techrash/Techrash+ +50/100/180/800/1000 (x50% if Mini)
|
||||
Techrash/Techrash+ +100/200
|
||||
Spin (0 lines) +20. Do note that the B2B gauge cannot exceed 1000 using this method.
|
||||
When gauge is above 1,000, a drop without clearing lines decreases it by 40, but cannot drop below 1,000
|
||||
Spin (0 lines) +20. Do note that the B2B gauge cannot exceed 800 using this method.
|
||||
When gauge is above 800, a drop without clearing lines decreases it by 40, but cannot drop below 800
|
||||
|
||||
Battle Royale modes:
|
||||
Many players play a game at the same time (against AI bots, not real players). As players get eliminated, blocks fall faster, and garbage take effect faster, as well as rise faster. Eliminate other players to gain a badge and the player's badge to increase your attack power.
|
||||
|
||||
201
main.lua
@@ -13,6 +13,7 @@ local fs=love.filesystem
|
||||
--?
|
||||
NONE={}function NULL()end
|
||||
DBP=print--Use this in permanent code
|
||||
TIME=love.timer.getTime
|
||||
SYSTEM=love.system.getOS()
|
||||
MOBILE=SYSTEM=="Android"or SYSTEM=="iOS"
|
||||
SAVEDIR=fs.getSaveDirectory()
|
||||
@@ -30,13 +31,62 @@ love.keyboard.setKeyRepeat(true)
|
||||
love.keyboard.setTextInput(false)
|
||||
love.mouse.setVisible(false)
|
||||
|
||||
--Create directories
|
||||
for _,v in next,{"conf","record","replay"}do
|
||||
local info=fs.getInfo(v)
|
||||
if info then
|
||||
if info.type=="directory"then goto NEXT end
|
||||
fs.remove(v)
|
||||
end
|
||||
fs.createDirectory(v)
|
||||
::NEXT::
|
||||
end
|
||||
|
||||
--Delete useless files
|
||||
for _,v in next,{
|
||||
"cold_clear.dll",
|
||||
"CCloader.dll",
|
||||
"tech_ultimate.dat",
|
||||
"tech_ultimate+.dat",
|
||||
"sprintFix.dat",
|
||||
"sprintLock.dat",
|
||||
"marathon_ultimate.dat",
|
||||
"infinite.dat",
|
||||
"infinite_dig.dat",
|
||||
"conf/account",
|
||||
}do
|
||||
if fs.getInfo(v)then fs.remove(v)end
|
||||
end
|
||||
|
||||
--Collect files of old version
|
||||
if fs.getInfo("data.dat")or fs.getInfo("key.dat")or fs.getInfo("settings.dat")then
|
||||
for k,v in next,{
|
||||
["settings.dat"]="conf/settings",
|
||||
["unlock.dat"]="conf/unlock",
|
||||
["data.dat"]="conf/data",
|
||||
["key.dat"]="conf/key",
|
||||
["virtualkey.dat"]="conf/virtualkey",
|
||||
["account.dat"]="conf/user",
|
||||
}do
|
||||
if fs.getInfo(k)then
|
||||
fs.write(v,fs.read(k))
|
||||
fs.remove(k)
|
||||
end
|
||||
end
|
||||
for _,name in next,fs.getDirectoryItems("")do
|
||||
if name:sub(-4)==".dat"then
|
||||
fs.write("record/"..name:sub(1,-4).."rec",fs.read(name))
|
||||
fs.remove(name)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
--Load modules
|
||||
require"Zframework"
|
||||
|
||||
require"parts/list"
|
||||
require"parts/globalTables"
|
||||
require"parts/gametoolfunc"
|
||||
|
||||
SCR.setSize(1280,720)--Initialize Screen size
|
||||
FIELD[1]=newBoard()--Initialize field[1]
|
||||
|
||||
@@ -51,6 +101,16 @@ AIFUNC= require"parts/ai"
|
||||
MODES= require"parts/modes"
|
||||
TICK= require"parts/tick"
|
||||
|
||||
--First start for phones
|
||||
if not fs.getInfo("conf/settings")and MOBILE then
|
||||
SETTING.VKSwitch=true
|
||||
SETTING.swap=false
|
||||
SETTING.vib=2
|
||||
SETTING.powerInfo=true
|
||||
SETTING.fullscreen=true
|
||||
end
|
||||
if SETTING.fullscreen then love.window.setFullscreen(true)end
|
||||
|
||||
--Initialize image libs
|
||||
IMG.init{
|
||||
batteryImage="/mess/power.png",
|
||||
@@ -76,27 +136,25 @@ IMG.init{
|
||||
hbm="mess/hbm.png",
|
||||
}
|
||||
SKIN.init{
|
||||
"normal(mrz)",
|
||||
"smooth(mrz)",
|
||||
"contrast(mrz)",
|
||||
"glow(mrz)",
|
||||
"plastic(mrz)",
|
||||
"jelly(miya)",
|
||||
"steel(kulumi)",
|
||||
"pure(mrz)",
|
||||
"ball(shaw)",
|
||||
"paper(mrz)",
|
||||
"gem(notypey)",
|
||||
"classic(_)",
|
||||
"brick(notypey)",
|
||||
"brick_light(notypey)",
|
||||
"cartoon_cup(earety)",
|
||||
"crack(earety)",
|
||||
"retro(notypey)",
|
||||
"retro_grey(notypey)",
|
||||
"text_bone(mrz)",
|
||||
"colored_bone(mrz)",
|
||||
"white_bone(mrz)",
|
||||
"Normal(MrZ)",
|
||||
"Contrast(MrZ)",
|
||||
"PolkaDots(ScF)",
|
||||
"Smooth(MrZ)",
|
||||
"Glass(ScF)",
|
||||
"Pentagon(ScF)",
|
||||
"Pure(MrZ)",
|
||||
"Glow(MrZ)",
|
||||
"Plastic(MrZ)",
|
||||
"Paper(MrZ)",
|
||||
"CartoonCup(Earety)",
|
||||
"Jelly(Miya)",
|
||||
"Brick(Notypey)",
|
||||
"Gem(Notypey)",
|
||||
"Classic",
|
||||
"Ball(Shaw)",
|
||||
"Retro(Notypey)",
|
||||
"TextBone(MrZ)",
|
||||
"ColoredBone(MrZ)",
|
||||
"WTF",
|
||||
}
|
||||
--Initialize sound libs
|
||||
@@ -166,7 +224,10 @@ LANG.setLangList{
|
||||
require"parts/language/lang_sp",
|
||||
require"parts/language/lang_symbol",
|
||||
require"parts/language/lang_yygq",
|
||||
--Add new language file to LANG folder. Attention, new language won't show in-game when you add language
|
||||
--1. Add language file to LANG folder;
|
||||
--2. Require it;
|
||||
--3. Add a button in parts/scenes/setting_lang.lua;
|
||||
--4. Set button name at LANG.setPublicWidgetText.lang beneath.
|
||||
}
|
||||
LANG.setPublicText{
|
||||
block={
|
||||
@@ -250,76 +311,8 @@ for _,v in next,fs.getDirectoryItems("parts/scenes")do
|
||||
end
|
||||
end
|
||||
|
||||
--Create directories
|
||||
for _,v in next,{"conf","record","replay"}do
|
||||
local info=fs.getInfo(v)
|
||||
if info then
|
||||
if info.type=="directory"then goto NEXT end
|
||||
fs.remove(v)
|
||||
end
|
||||
fs.createDirectory(v)
|
||||
::NEXT::
|
||||
end
|
||||
|
||||
--Collect files
|
||||
if fs.getInfo("data.dat")or fs.getInfo("key.dat")or fs.getInfo("settings.dat")then
|
||||
for k,v in next,{
|
||||
["settings.dat"]="conf/settings",
|
||||
["unlock.dat"]="conf/unlock",
|
||||
["data.dat"]="conf/data",
|
||||
["key.dat"]="conf/key",
|
||||
["virtualkey.dat"]="conf/virtualkey",
|
||||
["account.dat"]="conf/user",
|
||||
}do
|
||||
if fs.getInfo(k)then
|
||||
fs.write(v,fs.read(k))
|
||||
fs.remove(k)
|
||||
end
|
||||
end
|
||||
for _,name in next,fs.getDirectoryItems("")do
|
||||
if name:sub(-4)==".dat"then
|
||||
fs.write("record/"..name:sub(1,-4).."rec",fs.read(name))
|
||||
fs.remove(name)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
--Load files
|
||||
if fs.getInfo("conf/settings")then
|
||||
addToTable(FILE.load("conf/settings"),SETTING)
|
||||
else
|
||||
if MOBILE then
|
||||
SETTING.VKSwitch=true
|
||||
SETTING.swap=false
|
||||
SETTING.vib=2
|
||||
SETTING.powerInfo=true
|
||||
SETTING.fullscreen=true
|
||||
love.window.setFullscreen(true)
|
||||
love.resize(love.graphics.getWidth(),love.graphics.getHeight())
|
||||
end
|
||||
end
|
||||
if SETTING.fullscreen then love.window.setFullscreen(true)end
|
||||
LANG.set(SETTING.lang)
|
||||
|
||||
if fs.getInfo("conf/unlock")then RANKS=FILE.load("conf/unlock")end
|
||||
if fs.getInfo("conf/data")then STAT=FILE.load("conf/data")end
|
||||
if fs.getInfo("conf/key")then keyMap=FILE.load("conf/key")end
|
||||
if fs.getInfo("conf/virtualkey")then VK_org=FILE.load("conf/virtualkey")end
|
||||
if fs.getInfo("conf/user")then USER=FILE.load("conf/user")end
|
||||
if fs.getInfo("conf/replay")then REPLAY=FILE.load("conf/replay")end
|
||||
|
||||
for _,v in next,{
|
||||
"tech_ultimate.dat",
|
||||
"tech_ultimate+.dat",
|
||||
"sprintFix.dat",
|
||||
"sprintLock.dat",
|
||||
"marathon_ultimate.dat",
|
||||
"infinite.dat",
|
||||
"infinite_dig.dat",
|
||||
}do
|
||||
if fs.getInfo(v)then fs.remove(v)end
|
||||
end
|
||||
|
||||
--Update data
|
||||
do
|
||||
--Check Ranks
|
||||
@@ -345,13 +338,7 @@ do
|
||||
S.stereo>1 or S.VKSFX>1 or S.VKAlpha>1
|
||||
then
|
||||
NOGAME=true
|
||||
fs.remove("settings.dat")
|
||||
end
|
||||
|
||||
if fs.getInfo("cold_clear.dll")then
|
||||
NOGAME=true
|
||||
fs.remove("cold_clear.dll")
|
||||
fs.remove("CCloader.dll")
|
||||
fs.remove("conf/settings")
|
||||
end
|
||||
|
||||
--Update data file
|
||||
@@ -374,22 +361,10 @@ do
|
||||
SETTING.VKCurW=SETTING.VKCurW*.1
|
||||
SETTING.VKTchW=SETTING.VKTchW*.1
|
||||
end
|
||||
newVersionLaunch=true
|
||||
|
||||
--Try unlock modes which should be unlocked
|
||||
for name,rank in next,RANKS do
|
||||
if rank and rank>0 then
|
||||
for _,mode in next,MODES do
|
||||
if mode.name==name and mode.unlock then
|
||||
for _,unlockName in next,mode.unlock do
|
||||
if not RANKS[unlockName]then
|
||||
RANKS[unlockName]=0
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
if S.version<1208 then
|
||||
SETTING.skinSet=1
|
||||
end
|
||||
newVersionLaunch=true
|
||||
|
||||
S.version=VERSION_CODE
|
||||
FILE.save(RANKS,"conf/unlock","q")
|
||||
|
||||
BIN
media/image/skin/Ball(Shaw).png
Normal file
|
After Width: | Height: | Size: 4.3 KiB |
BIN
media/image/skin/Brick(Notypey).png
Normal file
|
After Width: | Height: | Size: 17 KiB |
|
Before Width: | Height: | Size: 8.0 KiB After Width: | Height: | Size: 8.0 KiB |
BIN
media/image/skin/Classic.png
Normal file
|
After Width: | Height: | Size: 8.8 KiB |
BIN
media/image/skin/ColoredBone(MrZ).png
Normal file
|
After Width: | Height: | Size: 5.0 KiB |
BIN
media/image/skin/Contrast(MrZ).png
Normal file
|
After Width: | Height: | Size: 2.6 KiB |
BIN
media/image/skin/Gem(Notypey).png
Normal file
|
After Width: | Height: | Size: 18 KiB |
BIN
media/image/skin/Glass(ScF).png
Normal file
|
After Width: | Height: | Size: 4.3 KiB |
BIN
media/image/skin/Glow(MrZ).png
Normal file
|
After Width: | Height: | Size: 13 KiB |
BIN
media/image/skin/Jelly(Miya).png
Normal file
|
After Width: | Height: | Size: 12 KiB |
BIN
media/image/skin/Normal(MrZ).png
Normal file
|
After Width: | Height: | Size: 9.4 KiB |
BIN
media/image/skin/Paper(MrZ).png
Normal file
|
After Width: | Height: | Size: 3.4 KiB |
BIN
media/image/skin/Pentagon(ScF).png
Normal file
|
After Width: | Height: | Size: 5.2 KiB |
BIN
media/image/skin/Plastic(MrZ).png
Normal file
|
After Width: | Height: | Size: 2.3 KiB |
BIN
media/image/skin/PolkaDots(ScF).png
Normal file
|
After Width: | Height: | Size: 1.0 KiB |
BIN
media/image/skin/Pure(MrZ).png
Normal file
|
After Width: | Height: | Size: 613 B |
BIN
media/image/skin/Retro(Notypey).png
Normal file
|
After Width: | Height: | Size: 2.9 KiB |
BIN
media/image/skin/Smooth(MrZ).png
Normal file
|
After Width: | Height: | Size: 2.5 KiB |
BIN
media/image/skin/TextBone(MrZ).png
Normal file
|
After Width: | Height: | Size: 8.5 KiB |
|
Before Width: | Height: | Size: 4.3 KiB After Width: | Height: | Size: 4.3 KiB |
|
Before Width: | Height: | Size: 16 KiB After Width: | Height: | Size: 17 KiB |
|
Before Width: | Height: | Size: 3.4 KiB |
|
Before Width: | Height: | Size: 8.7 KiB |
|
Before Width: | Height: | Size: 5.0 KiB |
|
Before Width: | Height: | Size: 25 KiB |
|
Before Width: | Height: | Size: 17 KiB After Width: | Height: | Size: 18 KiB |
BIN
media/image/skin/glass(ScF).png
Normal file
|
After Width: | Height: | Size: 4.3 KiB |
|
Before Width: | Height: | Size: 11 KiB After Width: | Height: | Size: 12 KiB |
|
Before Width: | Height: | Size: 3.4 KiB After Width: | Height: | Size: 3.4 KiB |
|
Before Width: | Height: | Size: 612 B After Width: | Height: | Size: 613 B |
|
Before Width: | Height: | Size: 1.8 KiB |
|
Before Width: | Height: | Size: 2.2 KiB After Width: | Height: | Size: 2.5 KiB |
|
Before Width: | Height: | Size: 10 KiB |
|
Before Width: | Height: | Size: 8.2 KiB |
|
Before Width: | Height: | Size: 1.4 KiB |
@@ -699,7 +699,7 @@ end
|
||||
local noRecList={"custom","solo","round","techmino"}
|
||||
local function getModList()
|
||||
local res={}
|
||||
for k,v in next,GAME.mod do
|
||||
for _,v in next,GAME.mod do
|
||||
if v.sel>0 then
|
||||
ins(res,{v.no,v.sel})
|
||||
end
|
||||
|
||||
@@ -6,18 +6,18 @@ MODOPT={--Mod options
|
||||
{no=0,id="NX",name="next",
|
||||
key="q",x=80,y=230,color="orange",
|
||||
list={0,1,2,3,4,5,6},
|
||||
func=function(P,M)P.gameEnv.nextCount=M.list[M.sel]end,
|
||||
func=function(P,O)P.gameEnv.nextCount=O end,
|
||||
},
|
||||
{no=1,id="HL",name="hold",
|
||||
key="w",x=200,y=230,color="orange",
|
||||
list={0,1,2,3,4,5,6},
|
||||
func=function(P,M)P.gameEnv.holdCount=M.list[M.sel]end,
|
||||
func=function(P,O)P.gameEnv.holdCount=O end,
|
||||
unranked=true,
|
||||
},
|
||||
{no=2,id="FL",name="hideNext",
|
||||
key="e",x=320,y=230,color="water",
|
||||
list={1,2,3,4,5},
|
||||
func=function(P,M)P.gameEnv.nextStartPos=M.list[M.sel]+1 end,
|
||||
func=function(P,O)P.gameEnv.nextStartPos=O +1 end,
|
||||
},
|
||||
{no=3,id="IH",name="infHold",
|
||||
key="r",x=440,y=230,color="water",
|
||||
@@ -35,48 +35,48 @@ MODOPT={--Mod options
|
||||
{no=6,id="HD",name="hidden",
|
||||
key="i",x=920,y=230,color="grape",
|
||||
list={"time","fast","none"},
|
||||
func=function(P,M)P.gameEnv.visible=M.list[M.sel]end,
|
||||
func=function(P,O)P.gameEnv.visible=O end,
|
||||
unranked=true,
|
||||
},
|
||||
{no=7,id="HB",name="hideBoard",
|
||||
key="o",x=1040,y=230,color="grape",
|
||||
list={"down","up","all"},
|
||||
func=function(P)LOG.print("该mod还没有做好!")end,
|
||||
func=function(P,O)P.gameEnv.hideBoard=O end,
|
||||
},
|
||||
{no=8,id="FB",name="flipBoard",
|
||||
key="p",x=1160,y=230,color="grass",
|
||||
list={"UD","LR","180"},
|
||||
func=function(P)LOG.print("该mod还没有做好!")end,
|
||||
list={"U-D","L-R","180"},
|
||||
func=function(P,O)P.gameEnv.flipBoard=O end,
|
||||
},
|
||||
|
||||
{no=9,id="DT",name="dropDelay",
|
||||
key="a",x=140,y=350,color="red",
|
||||
list={0,.125,.25,.5,1,2,3,4,5,6,7,8,9,10,12,14,16,18,20,25,30,40,60,180,1e99},
|
||||
func=function(P,M)P.gameEnv.drop=M.list[M.sel]end,
|
||||
func=function(P,O)P.gameEnv.drop=O end,
|
||||
unranked=true,
|
||||
},
|
||||
{no=10,id="LT",name="lockDelay",
|
||||
key="s",x=260,y=350,color="red",
|
||||
list={0,1,2,3,4,5,6,7,8,9,10,12,14,16,18,20,25,30,40,60,180,1e99},
|
||||
func=function(P,M)P.gameEnv.lock=M.list[M.sel]end,
|
||||
func=function(P,O)P.gameEnv.lock=O end,
|
||||
unranked=true,
|
||||
},
|
||||
{no=11,id="ST",name="waitDelay",
|
||||
key="d",x=380,y=350,color="red",
|
||||
list={0,1,2,3,4,5,6,7,8,10,15,20,30,60},
|
||||
func=function(P,M)P.gameEnv.wait=M.list[M.sel]end,
|
||||
func=function(P,O)P.gameEnv.wait=O end,
|
||||
unranked=true,
|
||||
},
|
||||
{no=12,id="CT",name="fallDelay",
|
||||
key="f",x=500,y=350,color="red",
|
||||
list={0,1,2,3,4,5,6,7,8,10,15,20,30,60},
|
||||
func=function(P,M)P.gameEnv.fall=M.list[M.sel]end,
|
||||
func=function(P,O)P.gameEnv.fall=O end,
|
||||
unranked=true,
|
||||
},
|
||||
{no=13,id="LF",name="life",
|
||||
key="j",x=860,y=350,color="yellow",
|
||||
list={0,1,2,3,5,10,15,26,42,87,500},
|
||||
func=function(P,M)P.gameEnv.life=M.list[M.sel]end,
|
||||
func=function(P,O)P.gameEnv.life=O end,
|
||||
unranked=true,
|
||||
},
|
||||
{no=14,id="FB",name="forceB2B",
|
||||
@@ -116,19 +116,19 @@ MODOPT={--Mod options
|
||||
{no=19,id="CS",name="customSeq",
|
||||
key="b",x=680,y=470,color="blue",
|
||||
list={"bag","his4","rnd","reverb"},
|
||||
func=function(P,M)P.gameEnv.sequence=M.list[M.sel]end,
|
||||
func=function(P,O)P.gameEnv.sequence=O end,
|
||||
unranked=true,
|
||||
},
|
||||
{no=20,id="PS",name="pushSpeed",
|
||||
key="n",x=800,y=470,color="blue",
|
||||
list={.5,1,2,3,5,15,1e99},
|
||||
func=function(P,M)P.gameEnv.pushSpeed=M.list[M.sel]end,
|
||||
func=function(P,O)P.gameEnv.pushSpeed=O end,
|
||||
unranked=true,
|
||||
},
|
||||
{no=21,id="BN",name="boneBlock",
|
||||
key="m",x=920,y=470,color="blue",
|
||||
list={"on","off"},
|
||||
func=function(P,M)P.gameEnv.bone=M.sel==1 end,
|
||||
func=function(P,O)P.gameEnv.bone=O=="on"end,
|
||||
},
|
||||
}
|
||||
for i=1,#MODOPT do
|
||||
@@ -172,6 +172,8 @@ CUSTOMENV={--gameEnv for cutsom game
|
||||
highCam=false,
|
||||
nextPos=false,
|
||||
bone=false,
|
||||
hideBoard=false,
|
||||
flipBoard=false,
|
||||
|
||||
--Rule
|
||||
mindas=0,
|
||||
@@ -231,8 +233,8 @@ GAME={--Global game data
|
||||
}
|
||||
|
||||
--Userdata tables
|
||||
RANKS={sprint_10=0}--Ranks of modes
|
||||
USER={--User infomation
|
||||
RANKS=FILE.load("conf/unlock")or{sprint_10=0}--Ranks of modes
|
||||
USER=FILE.load("conf/user")or{--User infomation
|
||||
email=nil,
|
||||
auth_token=nil,
|
||||
access_token=nil,
|
||||
@@ -240,6 +242,7 @@ USER={--User infomation
|
||||
username=nil,
|
||||
motto=nil,
|
||||
avatar=nil,
|
||||
xp=0,lv=1,
|
||||
}
|
||||
SETTING={--Settings
|
||||
--Tuning
|
||||
@@ -300,28 +303,33 @@ SETTING={--Settings
|
||||
VKCurW=.4,--Cur-Pos Weight
|
||||
VKIcon=true,--If disp icon
|
||||
VKAlpha=.3,
|
||||
}
|
||||
STAT={--Statistics
|
||||
version=VERSION_CODE,
|
||||
run=0,game=0,time=0,frame=0,
|
||||
key=0,rotate=0,hold=0,
|
||||
extraPiece=0,finesseRate=0,
|
||||
piece=0,row=0,dig=0,
|
||||
atk=0,digatk=0,
|
||||
send=0,recv=0,pend=0,off=0,
|
||||
clear={},spin={},
|
||||
pc=0,hpc=0,b2b=0,b3b=0,score=0,
|
||||
lastPlay="sprint_10",--Last played mode ID
|
||||
date=nil,
|
||||
todayTime=0,
|
||||
}for i=1,25 do STAT.clear[i]={0,0,0,0,0,0}STAT.spin[i]={0,0,0,0,0,0,0}end
|
||||
keyMap={--Key setting
|
||||
}local S=FILE.load("conf/settings")if S then addToTable(S,SETTING)end
|
||||
S=FILE.load("conf/data")
|
||||
if S then--Statistics
|
||||
STAT=S
|
||||
else
|
||||
STAT={
|
||||
version=VERSION_CODE,
|
||||
run=0,game=0,time=0,frame=0,
|
||||
key=0,rotate=0,hold=0,
|
||||
extraPiece=0,finesseRate=0,
|
||||
piece=0,row=0,dig=0,
|
||||
atk=0,digatk=0,
|
||||
send=0,recv=0,pend=0,off=0,
|
||||
clear={},spin={},
|
||||
pc=0,hpc=0,b2b=0,b3b=0,score=0,
|
||||
lastPlay="sprint_10",--Last played mode ID
|
||||
date=nil,
|
||||
todayTime=0,
|
||||
}for i=1,25 do STAT.clear[i]={0,0,0,0,0,0}STAT.spin[i]={0,0,0,0,0,0,0}end
|
||||
end
|
||||
keyMap=FILE.load("conf/key")or{--Key setting
|
||||
{"left","right","x","z","c","up","down","space","tab","r"},{},
|
||||
--Keyboard
|
||||
{"dpleft","dpright","a","b","y","dpup","dpdown","rightshoulder","x","leftshoulder"},{},
|
||||
--Joystick
|
||||
}for i=1,#keyMap do for j=1,20 do if not keyMap[i][j]then keyMap[i][j]=""end end end
|
||||
VK_org={--Virtualkey layout, refresh all VKs' position with this before each game
|
||||
VK_org=FILE.load("conf/virtualkey")or{--Virtualkey layout, refresh all VKs' position with this before each game
|
||||
{ava=true, x=80, y=720-200, r=80},--moveLeft
|
||||
{ava=true, x=320, y=720-200, r=80},--moveRight
|
||||
{ava=true, x=1280-80, y=720-200, r=80},--rotRight
|
||||
@@ -344,4 +352,4 @@ VK_org={--Virtualkey layout, refresh all VKs' position with this before each gam
|
||||
{ava=false, x=1000, y=50, r=80},--addToRight
|
||||
}
|
||||
virtualkey={}for i=1,#VK_org do virtualkey[i]={}end--In-game virtualkey layout
|
||||
REPLAY={}
|
||||
REPLAY=FILE.load("conf/replay")or{}
|
||||
@@ -730,11 +730,17 @@ return{
|
||||
"http://139.199.75.237/tos",
|
||||
},
|
||||
{"Github Repository",
|
||||
"githubrepository",
|
||||
"githubrepository sourcecode",
|
||||
"other",
|
||||
"Techmino's Github repository. Stars are appreciated",
|
||||
"http://github.com/26F-Studio/Techmino",
|
||||
},
|
||||
{"Minigame",
|
||||
"minigame",
|
||||
"other",
|
||||
"Input these to play free minigames!\n\n15-Puzzle: 15p\nSchulte Grid: sltg\nPong: pong\nAtoZ: atoz\nUltimate Tic-tac-toe: uttt\ncubefield: cbf",
|
||||
},
|
||||
|
||||
|
||||
{"SFX",
|
||||
"sfx soundeffects",
|
||||
|
||||
@@ -732,11 +732,16 @@ return{
|
||||
"http://139.199.75.237/tos",
|
||||
},
|
||||
{"Github仓库",
|
||||
"github",
|
||||
"github sourcecode yuandaima",
|
||||
"other",
|
||||
"Techmino的github仓库地址,欢迎star",
|
||||
"http://github.com/26F-Studio/Techmino",
|
||||
},
|
||||
{"小游戏",
|
||||
"minigame xiaoyouxi",
|
||||
"other",
|
||||
"输入以下词语,小游戏免费玩!\n\n15-Puzzle: 15p\nSchulte Grid: sltg\nPong: pong\nAtoZ: atoz\nUltimate Tic-tac-toe: uttt\ncubefield: cbf",
|
||||
},
|
||||
|
||||
{"SFX",
|
||||
"sfx",
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
local gc=love.graphics
|
||||
local sin,min=math.sin,math.min
|
||||
local Timer=love.timer.getTime
|
||||
return{
|
||||
color=COLOR.red,
|
||||
env={
|
||||
@@ -43,7 +42,7 @@ return{
|
||||
end
|
||||
|
||||
--Figures
|
||||
local t=Timer()
|
||||
local t=TIME()
|
||||
gc.setColor(1,1,1,.5+.2*sin(t))
|
||||
gc.draw(IMG.hbm,-276,-86,0,1.5)
|
||||
gc.draw(IMG.electric,476,142,0,2.6)
|
||||
|
||||
@@ -16,6 +16,7 @@ return{
|
||||
drop=300,lock=300,
|
||||
infHold=true,
|
||||
dropPiece=update_round,
|
||||
pushSpeed=15,
|
||||
garbageSpeed=1e99,
|
||||
bg="rainbow",bgm="push",
|
||||
},
|
||||
|
||||
@@ -16,6 +16,7 @@ return{
|
||||
drop=300,lock=300,
|
||||
infHold=true,
|
||||
dropPiece=update_round,
|
||||
pushSpeed=15,
|
||||
garbageSpeed=1e99,
|
||||
bg="rainbow",bgm="push",
|
||||
},
|
||||
|
||||
@@ -16,6 +16,7 @@ return{
|
||||
drop=300,lock=300,
|
||||
infHold=true,
|
||||
dropPiece=update_round,
|
||||
pushSpeed=15,
|
||||
garbageSpeed=1e99,
|
||||
bg="rainbow",bgm="push",
|
||||
},
|
||||
|
||||
@@ -16,6 +16,7 @@ return{
|
||||
drop=300,lock=300,
|
||||
infHold=true,
|
||||
dropPiece=update_round,
|
||||
pushSpeed=15,
|
||||
garbageSpeed=1e99,
|
||||
bg="rainbow",bgm="push",
|
||||
},
|
||||
|
||||
@@ -16,6 +16,7 @@ return{
|
||||
drop=300,lock=300,
|
||||
infHold=true,
|
||||
dropPiece=update_round,
|
||||
pushSpeed=15,
|
||||
garbageSpeed=1e99,
|
||||
bg="rainbow",bgm="push",
|
||||
},
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
local gc=love.graphics
|
||||
local Timer=love.timer.getTime
|
||||
local gc_rectangle,gc_setColor=gc.rectangle,gc.setColor
|
||||
local TIME=love.timer.getTime
|
||||
local int,ceil,rnd=math.floor,math.ceil,math.random
|
||||
local max,min,sin=math.max,math.min,math.sin
|
||||
local format=string.format
|
||||
@@ -18,7 +19,7 @@ local frameColorList={
|
||||
local function drawGrid(P,alpha)
|
||||
local FBN,FUP=P.fieldBeneath,P.fieldUp
|
||||
gc.setLineWidth(1)
|
||||
gc.setColor(1,1,1,alpha)
|
||||
gc_setColor(1,1,1,alpha)
|
||||
for x=1,9 do
|
||||
gc.line(30*x,-10,30*x,600)
|
||||
end
|
||||
@@ -37,11 +38,11 @@ local function drawField(P)
|
||||
for i=1,10 do
|
||||
if F[j][i]>0 then
|
||||
if V[j][i]>0 then
|
||||
gc.setColor(1,1,1,min(V[j][i]*.05,1))
|
||||
gc_setColor(1,1,1,min(V[j][i]*.05,1))
|
||||
Draw(texture[F[j][i]],30*i-30,-30*j)-- drawCell(j,i,F[j][i])
|
||||
elseif rep then
|
||||
gc.setColor(1,1,1,.3+.08*sin(.5*(j-i)+Timer()*4))
|
||||
gc.rectangle("fill",30*i-30,-30*j,30,30)
|
||||
gc_setColor(1,1,1,.3+.08*sin(.5*(j-i)+TIME()*4))
|
||||
gc_rectangle("fill",30*i-30,-30*j,30,30)
|
||||
end
|
||||
end
|
||||
end
|
||||
@@ -56,17 +57,17 @@ local function drawField(P)
|
||||
while j==P.clearingRow[h]do
|
||||
h=h+1
|
||||
gc.translate(0,-stepY)
|
||||
gc.setColor(1,1,1,A)
|
||||
gc.rectangle("fill",0,30-30*j,300,stepY)
|
||||
gc_setColor(1,1,1,A)
|
||||
gc_rectangle("fill",0,30-30*j,300,stepY)
|
||||
end
|
||||
for i=1,10 do
|
||||
if F[j][i]>0 then
|
||||
if V[j][i]>0 then
|
||||
gc.setColor(1,1,1,min(V[j][i]*.05,1))
|
||||
gc_setColor(1,1,1,min(V[j][i]*.05,1))
|
||||
Draw(texture[F[j][i]],30*i-30,-30*j)-- drawCell(j,i,F[j][i])
|
||||
elseif rep then
|
||||
gc.setColor(1,1,1,.2)
|
||||
gc.rectangle("fill",30*i-30,-30*j,30,30)
|
||||
gc_setColor(1,1,1,.2)
|
||||
gc_rectangle("fill",30*i-30,-30*j,30,30)
|
||||
end
|
||||
end
|
||||
end
|
||||
@@ -79,27 +80,27 @@ local function drawFXs(P)
|
||||
for i=1,#P.lockFX do
|
||||
local S=P.lockFX[i]
|
||||
if S[3]<.5 then
|
||||
gc.setColor(1,1,1,2*S[3])
|
||||
gc.rectangle("fill",S[1],S[2],60*S[3],30)
|
||||
gc_setColor(1,1,1,2*S[3])
|
||||
gc_rectangle("fill",S[1],S[2],60*S[3],30)
|
||||
else
|
||||
gc.setColor(1,1,1,2-2*S[3])
|
||||
gc.rectangle("fill",S[1]+30,S[2],60*S[3]-60,30)
|
||||
gc_setColor(1,1,1,2-2*S[3])
|
||||
gc_rectangle("fill",S[1]+30,S[2],60*S[3]-60,30)
|
||||
end
|
||||
end
|
||||
|
||||
--DropFX
|
||||
for i=1,#P.dropFX do
|
||||
local S=P.dropFX[i]
|
||||
gc.setColor(1,1,1,.6-S[5]*.6)
|
||||
gc_setColor(1,1,1,.6-S[5]*.6)
|
||||
local w=30*S[3]*(1-S[5]*.5)
|
||||
gc.rectangle("fill",30*S[1]-30+15*S[3]-w*.5,-30*S[2],w,30*S[4])
|
||||
gc_rectangle("fill",30*S[1]-30+15*S[3]-w*.5,-30*S[2],w,30*S[4])
|
||||
end
|
||||
|
||||
--MoveFX
|
||||
local texture=SKIN.curText
|
||||
for i=1,#P.moveFX do
|
||||
local S=P.moveFX[i]
|
||||
gc.setColor(1,1,1,.6-S[4]*.6)
|
||||
gc_setColor(1,1,1,.6-S[4]*.6)
|
||||
Draw(texture[S[1]],30*S[2]-30,-30*S[3])-- drawCell(S[3],S[2],S[1])
|
||||
end
|
||||
|
||||
@@ -109,12 +110,12 @@ local function drawFXs(P)
|
||||
local t=S[2]
|
||||
local x=t<.3 and 1-(3.3333*t-1)^2 or 1
|
||||
local y=t<.2 and 5*t or 1-1.25*(t-.2)
|
||||
gc.setColor(1,1,1,y)
|
||||
gc.rectangle("fill",150-x*150,15-S[1]*30-y*15,300*x,y*30)
|
||||
gc_setColor(1,1,1,y)
|
||||
gc_rectangle("fill",150-x*150,15-S[1]*30-y*15,300*x,y*30)
|
||||
end
|
||||
end
|
||||
local function drawGhost(P,clr)
|
||||
gc.setColor(1,1,1,P.gameEnv.ghost)
|
||||
gc_setColor(1,1,1,P.gameEnv.ghost)
|
||||
local texture=SKIN.curText
|
||||
for i=1,P.r do for j=1,P.c do
|
||||
if P.cur.bk[i][j]then
|
||||
@@ -138,7 +139,7 @@ local function drawBlockOutline(P,texture,trans)
|
||||
gc.setShader()
|
||||
end
|
||||
local function drawBlock(P,clr)
|
||||
gc.setColor(1,1,1)
|
||||
gc_setColor(1,1,1)
|
||||
local texture=SKIN.curText
|
||||
for i=1,P.r do for j=1,P.c do
|
||||
if P.cur.bk[i][j]then
|
||||
@@ -147,7 +148,7 @@ local function drawBlock(P,clr)
|
||||
end end
|
||||
end
|
||||
local function drawNextPreview(P,B)
|
||||
gc.setColor(1,1,1,.8)
|
||||
gc_setColor(1,1,1,.8)
|
||||
local x=int(6-#B[1]*.5)
|
||||
local y=21+ceil(P.fieldBeneath/30)
|
||||
for i=1,#B do for j=1,#B[1]do
|
||||
@@ -165,8 +166,8 @@ function draw.drawNext_norm(P)
|
||||
local texture=SKIN.curText
|
||||
gc.push("transform")
|
||||
gc.translate(316,116)
|
||||
gc.setColor(0,0,0,.4)gc.rectangle("fill",0,-80,124,N+8)
|
||||
gc.setColor(1,1,1)gc.rectangle("line",0,-80,124,N+8)
|
||||
gc_setColor(0,0,0,.4)gc_rectangle("fill",0,-80,124,N+8)
|
||||
gc_setColor(1,1,1)gc_rectangle("line",0,-80,124,N+8)
|
||||
mText(drawableText.next,62,-131)
|
||||
N=1
|
||||
while N<=ENV.nextCount and P.nextQueue[N]do
|
||||
@@ -182,7 +183,7 @@ function draw.drawNext_norm(P)
|
||||
if ENV.bagLine then
|
||||
local L=ENV.bagLen
|
||||
local C=-P.pieceCount%L--Phase
|
||||
gc.setColor(.8,.5,.5)
|
||||
gc_setColor(.8,.5,.5)
|
||||
for i=C,N-1,L do
|
||||
local y=72*i-77
|
||||
gc.line(2+P.fieldOff.x,y,120,y)
|
||||
@@ -196,8 +197,8 @@ function draw.drawNext_hidden(P)
|
||||
local texture=SKIN.curText
|
||||
gc.push("transform")
|
||||
gc.translate(316,116)
|
||||
gc.setColor(.5,0,0,.4)gc.rectangle("fill",0,-80,124,N+8)
|
||||
gc.setColor(1,1,1)gc.rectangle("line",0,-80,124,N+8)
|
||||
gc_setColor(.5,0,0,.4)gc_rectangle("fill",0,-80,124,N+8)
|
||||
gc_setColor(1,1,1)gc_rectangle("line",0,-80,124,N+8)
|
||||
mText(drawableText.next,62,-131)
|
||||
N=min(ENV.nextStartPos,P.pieceCount+1)
|
||||
while N<=ENV.nextCount and P.nextQueue[N]do
|
||||
@@ -213,7 +214,7 @@ function draw.drawNext_hidden(P)
|
||||
if ENV.bagLine then
|
||||
local L=ENV.bagLen
|
||||
local C=-P.pieceCount%L--Phase
|
||||
gc.setColor(.8,.5,.5)
|
||||
gc_setColor(.8,.5,.5)
|
||||
for i=C,N-1,L do
|
||||
local y=72*i-77
|
||||
gc.line(2+P.fieldOff.x,y,120,y)
|
||||
@@ -226,9 +227,9 @@ function draw.drawHold_norm(P)
|
||||
local texture=SKIN.curText
|
||||
gc.push("transform")
|
||||
gc.translate(-140,116)
|
||||
gc.setColor(0,0,0,.4)gc.rectangle("fill",0,-80,124,80)
|
||||
gc.setColor(1,1,1)gc.rectangle("line",0,-80,124,80)
|
||||
if P.holdTime==0 then gc.setColor(.6,.4,.4)end
|
||||
gc_setColor(0,0,0,.4)gc_rectangle("fill",0,-80,124,80)
|
||||
gc_setColor(1,1,1)gc_rectangle("line",0,-80,124,80)
|
||||
if P.holdTime==0 then gc_setColor(.6,.4,.4)end
|
||||
mText(drawableText.hold,62,-131)
|
||||
|
||||
local B=P.holdQueue[1]
|
||||
@@ -248,19 +249,19 @@ function draw.drawHold_multi(P)
|
||||
local texture=SKIN.curText
|
||||
gc.push("transform")
|
||||
gc.translate(-140,116)
|
||||
gc.setColor(0,0,0,.4)gc.rectangle("fill",0,-80,124,N+8)
|
||||
gc.setColor(1,1,1)gc.rectangle("line",0,-80,124,N+8)
|
||||
if P.holdTime==0 then gc.setColor(.6,.4,.4)end
|
||||
gc_setColor(0,0,0,.4)gc_rectangle("fill",0,-80,124,N+8)
|
||||
gc_setColor(1,1,1)gc_rectangle("line",0,-80,124,N+8)
|
||||
if P.holdTime==0 then gc_setColor(.6,.4,.4)end
|
||||
mText(drawableText.hold,62,-131)
|
||||
|
||||
gc.setColor(1,1,1)
|
||||
gc_setColor(1,1,1)
|
||||
if #P.holdQueue<P.gameEnv.holdCount and P.nextQueue[1]then
|
||||
N=1
|
||||
else
|
||||
N=P.holdTime+1
|
||||
end
|
||||
for n=1,#P.holdQueue do
|
||||
if n==N then gc.setColor(.6,.4,.4)end
|
||||
if n==N then gc_setColor(.6,.4,.4)end
|
||||
local bk,clr=P.holdQueue[n].bk,P.holdQueue[n].color
|
||||
for i=1,#bk do for j=1,#bk[1]do
|
||||
if bk[i][j]then
|
||||
@@ -274,7 +275,7 @@ end
|
||||
function draw.drawTargetLine(P,r)
|
||||
if r<21+(P.fieldBeneath+P.fieldUp)/30 and r>0 then
|
||||
gc.setLineWidth(4)
|
||||
gc.setColor(1,r>10 and 0 or rnd(),.5)
|
||||
gc_setColor(1,r>10 and 0 or rnd(),.5)
|
||||
local dx,dy=150+P.fieldOff.x,P.fieldOff.y+P.fieldBeneath+P.fieldUp
|
||||
gc.line(dx,600-30*r+dy,300+dx,600-30*r+dy)
|
||||
end
|
||||
@@ -289,24 +290,30 @@ local attackColor={
|
||||
}
|
||||
local RCPB={5,33,195,33,100,5,100,60}
|
||||
local function drawDial(x,y,speed)
|
||||
gc.setColor(1,1,1)
|
||||
gc_setColor(1,1,1)
|
||||
mStr(int(speed),x,y-18)
|
||||
|
||||
gc.setLineWidth(4)
|
||||
gc.setColor(1,1,1,.4)
|
||||
gc_setColor(1,1,1,.4)
|
||||
gc.circle("line",x,y,30,10)
|
||||
|
||||
gc.setLineWidth(2)
|
||||
gc.setColor(1,1,1,.6)
|
||||
gc_setColor(1,1,1,.6)
|
||||
gc.circle("line",x,y,30,10)
|
||||
|
||||
gc.setColor(1,1,1,.8)
|
||||
gc_setColor(1,1,1,.8)
|
||||
gc.draw(IMG.dialNeedle,x,y,2.094+(speed<=175 and .02094*speed or 4.712-52.36/(speed-125)),nil,nil,5,4)
|
||||
end
|
||||
local hideBoardStencil={
|
||||
up=function()gc_rectangle("fill",0,0,300,300)end,
|
||||
down=function()gc_rectangle("fill",0,300,300,300)end,
|
||||
all=function()gc_rectangle("fill",0,0,300,600)end,
|
||||
}
|
||||
function draw.norm(P)
|
||||
local _
|
||||
local ENV=P.gameEnv
|
||||
local FBN,FUP=P.fieldBeneath,P.fieldUp
|
||||
local t=TIME()
|
||||
gc.push("transform")
|
||||
gc.translate(P.x,P.y)gc.scale(P.size)
|
||||
|
||||
@@ -319,26 +326,38 @@ function draw.norm(P)
|
||||
gc.translate(P.fieldOff.x,P.fieldOff.y)
|
||||
|
||||
--Fill field
|
||||
gc.setColor(0,0,0,.6)
|
||||
gc.rectangle("fill",0,-10,300,610)
|
||||
gc_setColor(0,0,0,.6)
|
||||
gc_rectangle("fill",0,-10,300,610)
|
||||
|
||||
--Draw grid
|
||||
if ENV.grid then drawGrid(P,ENV.grid)end
|
||||
|
||||
--In-field things
|
||||
gc.push("transform")
|
||||
if ENV.flipBoard then
|
||||
if ENV.flipBoard=="U-D"then
|
||||
gc.translate(0,590)
|
||||
gc.scale(1,-1)
|
||||
elseif ENV.flipBoard=="L-R"then
|
||||
gc.translate(300,0)
|
||||
gc.scale(-1,1)
|
||||
elseif ENV.flipBoard=="180"then
|
||||
gc.translate(300,590)
|
||||
gc.scale(-1,-1)
|
||||
end
|
||||
end
|
||||
gc.translate(0,600+FBN+FUP)
|
||||
gc.setScissor(SCR.x+(P.absFieldX+P.fieldOff.x)*SCR.k,SCR.y+(P.absFieldY+P.fieldOff.y)*SCR.k,300*P.size*SCR.k,610*P.size*SCR.k)
|
||||
|
||||
--Draw dangerous area
|
||||
gc.setColor(1,0,0,.3)
|
||||
gc.rectangle("fill",0,-600,300,-610-FUP-FBN)
|
||||
gc_setColor(1,0,0,.3)
|
||||
gc_rectangle("fill",0,-600,300,-610-FUP-FBN)
|
||||
|
||||
--Draw field
|
||||
drawField(P)
|
||||
|
||||
--Draw spawn line
|
||||
gc.setColor(1,sin(Timer())*.4+.5,0,.5)
|
||||
gc_setColor(1,sin(t)*.4+.5,0,.5)
|
||||
gc.setLineWidth(4)
|
||||
gc.line(0,-600-FBN,300,-600-FBN)
|
||||
|
||||
@@ -365,12 +384,12 @@ function draw.norm(P)
|
||||
--Draw rotate center
|
||||
local x=30*(P.curX+P.sc[2])-15
|
||||
if ENV.center and ENV.block then
|
||||
gc.setColor(1,1,1,ENV.center)
|
||||
gc_setColor(1,1,1,ENV.center)
|
||||
gc.draw(IMG.spinCenter,x,-30*(P.curY+P.sc[1])+15,nil,nil,nil,4,4)
|
||||
end
|
||||
gc.translate(0,dy)
|
||||
if ENV.center and ENV.ghost then
|
||||
gc.setColor(1,1,1,trans*ENV.center)
|
||||
gc_setColor(1,1,1,trans*ENV.center)
|
||||
gc.draw(IMG.spinCenter,x,-30*(P.imgY+P.sc[1])+15,nil,nil,nil,4,4)
|
||||
end
|
||||
end
|
||||
@@ -384,10 +403,10 @@ function draw.norm(P)
|
||||
gc.pop()
|
||||
|
||||
gc.setLineWidth(2)
|
||||
gc.setColor(frameColorList[P.frameColor])
|
||||
gc.rectangle("line",-1,-11,302,612)--Boarder
|
||||
gc.rectangle("line",301,-3,15,604)--AtkBuffer boarder
|
||||
gc.rectangle("line",-16,-3,15,604)--B2b bar boarder
|
||||
gc_setColor(frameColorList[P.frameColor])
|
||||
gc_rectangle("line",-1,-11,302,612)--Boarder
|
||||
gc_rectangle("line",301,-3,15,604)--AtkBuffer boarder
|
||||
gc_rectangle("line",-16,-3,15,604)--B2b bar boarder
|
||||
|
||||
--Buffer line
|
||||
local h=0
|
||||
@@ -402,21 +421,21 @@ function draw.norm(P)
|
||||
end
|
||||
if A.countdown>0 then
|
||||
--Timing
|
||||
gc.setColor(attackColor[A.lv][1])
|
||||
gc.rectangle("fill",303,599-h,11,-bar)
|
||||
gc.setColor(attackColor[A.lv][2])
|
||||
gc.rectangle("fill",303,599-h-bar,11,bar*(1-A.countdown/A.cd0))
|
||||
gc_setColor(attackColor[A.lv][1])
|
||||
gc_rectangle("fill",303,599-h,11,-bar)
|
||||
gc_setColor(attackColor[A.lv][2])
|
||||
gc_rectangle("fill",303,599-h-bar,11,bar*(1-A.countdown/A.cd0))
|
||||
else
|
||||
--Warning
|
||||
local t=math.sin((Timer()-i)*30)*.5+.5
|
||||
local a=math.sin((t-i)*30)*.5+.5
|
||||
local c1,c2=attackColor[A.lv][1],attackColor[A.lv][2]
|
||||
gc.setColor(c1[1]*t+c2[1]*(1-t),c1[2]*t+c2[2]*(1-t),c1[3]*t+c2[3]*(1-t))
|
||||
gc.rectangle("fill",303,599-h,11,-bar)
|
||||
gc_setColor(c1[1]*a+c2[1]*(1-a),c1[2]*a+c2[2]*(1-a),c1[3]*a+c2[3]*(1-a))
|
||||
gc_rectangle("fill",303,599-h,11,-bar)
|
||||
end
|
||||
else
|
||||
gc.setColor(attackColor[A.lv][1])
|
||||
gc_setColor(attackColor[A.lv][1])
|
||||
bar=bar*(20-A.time)*.05
|
||||
gc.rectangle("fill",303,599-h,11,-bar)
|
||||
gc_rectangle("fill",303,599-h,11,-bar)
|
||||
--Disappear
|
||||
end
|
||||
h=h+bar
|
||||
@@ -424,27 +443,27 @@ function draw.norm(P)
|
||||
|
||||
--B2B indictator
|
||||
local a,b=P.b2b,P.b2b1 if a>b then a,b=b,a end
|
||||
gc.setColor(.8,1,.2)
|
||||
gc.rectangle("fill",-14,599,11,-b*.5)
|
||||
gc.setColor(P.b2b<40 and COLOR.white or P.b2b<=1e3 and COLOR.lRed or COLOR.lBlue)
|
||||
gc.rectangle("fill",-14,599,11,-a*.5)
|
||||
gc.setColor(1,1,1)
|
||||
if Timer()%.5<.3 then
|
||||
gc.rectangle("fill",-15,b<40 and 578.5 or 98.5,13,3)
|
||||
gc_setColor(.8,1,.2)
|
||||
gc_rectangle("fill",-14,599,11,-b*.6)
|
||||
gc_setColor(P.b2b<40 and COLOR.white or P.b2b<=800 and COLOR.lRed or COLOR.lBlue)
|
||||
gc_rectangle("fill",-14,599,11,-a*.6)
|
||||
gc_setColor(1,1,1)
|
||||
if t%.5<.3 then
|
||||
gc_rectangle("fill",-15,b<40 and 568.5 or 118.5,13,3)
|
||||
end
|
||||
|
||||
--LockDelay indicator
|
||||
if ENV.easyFresh then
|
||||
gc.setColor(1,1,1)
|
||||
gc_setColor(1,1,1)
|
||||
else
|
||||
gc.setColor(1,.26,.26)
|
||||
gc_setColor(1,.26,.26)
|
||||
end
|
||||
if P.lockDelay>=0 then
|
||||
gc.rectangle("fill",0,602,300*P.lockDelay/ENV.lock,6)--Lock delay indicator
|
||||
gc_rectangle("fill",0,602,300*P.lockDelay/ENV.lock,6)--Lock delay indicator
|
||||
end
|
||||
local x=3
|
||||
for _=1,min(P.freshTime,15)do
|
||||
gc.rectangle("fill",x,615,14,5)
|
||||
gc_rectangle("fill",x,615,14,5)
|
||||
x=x+20
|
||||
end
|
||||
|
||||
@@ -457,16 +476,26 @@ function draw.norm(P)
|
||||
--Draw target selecting pad
|
||||
if GAME.modeEnv.royaleMode then
|
||||
if P.atkMode then
|
||||
gc.setColor(1,.8,0,P.swappingAtkMode*.02)
|
||||
gc.rectangle("fill",RCPB[2*P.atkMode-1],RCPB[2*P.atkMode],90,35,8,4)
|
||||
gc_setColor(1,.8,0,P.swappingAtkMode*.02)
|
||||
gc_rectangle("fill",RCPB[2*P.atkMode-1],RCPB[2*P.atkMode],90,35,8,4)
|
||||
end
|
||||
gc.setColor(1,1,1,P.swappingAtkMode*.025)
|
||||
gc_setColor(1,1,1,P.swappingAtkMode*.025)
|
||||
setFont(35)
|
||||
for i=1,4 do
|
||||
gc.rectangle("line",RCPB[2*i-1],RCPB[2*i],90,35,8,4)
|
||||
gc_rectangle("line",RCPB[2*i-1],RCPB[2*i],90,35,8,4)
|
||||
gc.printf(text.atkModeName[i],RCPB[2*i-1]-4,RCPB[2*i]+4,200,"center",nil,.5)
|
||||
end
|
||||
end
|
||||
if ENV.hideBoard then
|
||||
gc.stencil(hideBoardStencil[ENV.hideBoard],"replace",1)
|
||||
gc.setStencilTest("equal",1)
|
||||
gc.setLineWidth(20)
|
||||
for i=0,24 do
|
||||
gc_setColor(COLOR.rainbow_grey(t*.626+i*.1))
|
||||
gc.line(20*i-190,-2,20*i+10,602)
|
||||
end
|
||||
gc.setStencilTest()
|
||||
end
|
||||
gc.pop()
|
||||
|
||||
--Bonus texts
|
||||
@@ -474,50 +503,50 @@ function draw.norm(P)
|
||||
|
||||
--Display Ys
|
||||
-- gc.setLineWidth(6)
|
||||
-- if P.curY then gc.setColor(1,.4,0,.42)gc.line(0,611-P.curY*30,300,611-P.curY*30)end
|
||||
-- if P.imgY then gc.setColor(0,1,.4,.42)gc.line(0,615-P.imgY*30,300,615-P.imgY*30)end
|
||||
-- if P.minY then gc.setColor(0,.4,1,.42)gc.line(0,619-P.minY*30,300,619-P.minY*30)end
|
||||
-- gc.setColor(0,.4,1,.42)gc.line(0,600-P.garbageBeneath*30,300,600-P.garbageBeneath*30)
|
||||
-- if P.curY then gc_setColor(1,.4,0,.42)gc.line(0,611-P.curY*30,300,611-P.curY*30)end
|
||||
-- if P.imgY then gc_setColor(0,1,.4,.42)gc.line(0,615-P.imgY*30,300,615-P.imgY*30)end
|
||||
-- if P.minY then gc_setColor(0,.4,1,.42)gc.line(0,619-P.minY*30,300,619-P.minY*30)end
|
||||
-- gc_setColor(0,.4,1,.42)gc.line(0,600-P.garbageBeneath*30,300,600-P.garbageBeneath*30)
|
||||
gc.pop()
|
||||
|
||||
--Speed dials
|
||||
setFont(25)
|
||||
drawDial(510,510,P.dropSpeed)
|
||||
drawDial(555,565,P.keySpeed)
|
||||
gc.setColor(1,1,1)
|
||||
gc_setColor(1,1,1)
|
||||
gc.draw(drawableText.bpm,540,480)
|
||||
gc.draw(drawableText.kpm,494,573)
|
||||
|
||||
--Score & Time
|
||||
setFont(25)
|
||||
gc.setColor(0,0,0,.3)
|
||||
gc_setColor(0,0,0,.3)
|
||||
gc.print(P.score1,18,509)
|
||||
gc.print(format("%.2f",P.stat.time),18,539)
|
||||
gc.setColor(COLOR.lYellow)gc.print(P.score1,20,510)
|
||||
gc.setColor(COLOR.sky)gc.print(format("%.2f",P.stat.time),20,540)
|
||||
gc_setColor(COLOR.lYellow)gc.print(P.score1,20,510)
|
||||
gc_setColor(COLOR.sky)gc.print(format("%.2f",P.stat.time),20,540)
|
||||
|
||||
--FinesseCombo
|
||||
if P.finesseCombo>2 then
|
||||
_=P.finesseComboTime
|
||||
local T=P.finesseCombo.."x"
|
||||
local str=P.finesseCombo.."x"
|
||||
if _>0 then
|
||||
gc.setColor(1,1,1,_*.2)
|
||||
gc.print(T,20,570)
|
||||
gc.setColor(1,1,1,1.2-_*.1)
|
||||
gc_setColor(1,1,1,_*.2)
|
||||
gc.print(str,20,570)
|
||||
gc_setColor(1,1,1,1.2-_*.1)
|
||||
gc.push("transform")
|
||||
gc.translate(20,600)
|
||||
gc.scale(1+_*.08)
|
||||
gc.print(T,0,-30)
|
||||
gc.print(str,0,-30)
|
||||
gc.pop()
|
||||
else
|
||||
gc.setColor(1,1,1)
|
||||
gc.print(T,20,570)
|
||||
gc_setColor(1,1,1)
|
||||
gc.print(str,20,570)
|
||||
end
|
||||
end
|
||||
|
||||
--Lives
|
||||
if P.life>0 then
|
||||
gc.setColor(1,1,1)
|
||||
gc_setColor(1,1,1)
|
||||
if P.life<=3 then
|
||||
for i=1,P.life do
|
||||
gc.draw(IMG.lifeIcon,450+25*i,595,nil,.8)
|
||||
@@ -531,7 +560,7 @@ function draw.norm(P)
|
||||
end
|
||||
|
||||
--Other messages
|
||||
gc.setColor(1,1,1)
|
||||
gc_setColor(1,1,1)
|
||||
if GAME.curMode.mesDisp then
|
||||
GAME.curMode.mesDisp(P)
|
||||
end
|
||||
@@ -544,19 +573,19 @@ function draw.norm(P)
|
||||
--Draw current mission
|
||||
setFont(35)
|
||||
if ENV.missionKill then
|
||||
gc.setColor(1,.7+.2*sin(Timer()*6.26),.4)
|
||||
gc_setColor(1,.7+.2*sin(t*6.26),.4)
|
||||
else
|
||||
gc.setColor(1,1,1)
|
||||
gc_setColor(1,1,1)
|
||||
end
|
||||
gc.print(missionEnum[L[P.curMission]],85,110)
|
||||
|
||||
--Draw next mission
|
||||
setFont(20)
|
||||
for i=1,3 do
|
||||
local t=L[P.curMission+i]
|
||||
if t then
|
||||
t=missionEnum[t]
|
||||
gc.print(t,87-28*i,117)
|
||||
local m=L[P.curMission+i]
|
||||
if m then
|
||||
m=missionEnum[m]
|
||||
gc.print(m,87-28*i,117)
|
||||
else
|
||||
break
|
||||
end
|
||||
@@ -564,7 +593,7 @@ function draw.norm(P)
|
||||
end
|
||||
|
||||
--Draw starting counter
|
||||
gc.setColor(1,1,1)
|
||||
gc_setColor(1,1,1)
|
||||
if GAME.frame<180 then
|
||||
local count=179-GAME.frame
|
||||
gc.push("transform")
|
||||
@@ -586,7 +615,7 @@ function draw.small(P)
|
||||
gc.clear(0,0,0,.4)
|
||||
gc.push("transform")
|
||||
gc.origin()
|
||||
gc.setColor(1,1,1,P.result and max(20-P.endCounter,0)*.05 or 1)
|
||||
gc_setColor(1,1,1,P.result and max(20-P.endCounter,0)*.05 or 1)
|
||||
|
||||
--Field
|
||||
local F=P.field
|
||||
@@ -600,13 +629,13 @@ function draw.small(P)
|
||||
--Draw boarder
|
||||
if P.alive then
|
||||
gc.setLineWidth(2)
|
||||
gc.setColor(frameColorList[P.frameColor])
|
||||
gc.rectangle("line",0,0,60,120)
|
||||
gc_setColor(frameColorList[P.frameColor])
|
||||
gc_rectangle("line",0,0,60,120)
|
||||
end
|
||||
|
||||
--Draw badge
|
||||
if GAME.modeEnv.royaleMode then
|
||||
gc.setColor(1,1,1)
|
||||
gc_setColor(1,1,1)
|
||||
for i=1,P.strength do
|
||||
gc.draw(IMG.badgeIcon,12*i-7,4,nil,.5)
|
||||
end
|
||||
@@ -614,7 +643,7 @@ function draw.small(P)
|
||||
|
||||
--Draw result
|
||||
if P.result then
|
||||
gc.setColor(1,1,1,min(P.endCounter,60)*.01)
|
||||
gc_setColor(1,1,1,min(P.endCounter,60)*.01)
|
||||
setFont(20)mStr(P.result,32,47)
|
||||
setFont(15)mStr(P.modeData.event,30,82)
|
||||
end
|
||||
@@ -623,11 +652,11 @@ function draw.small(P)
|
||||
end
|
||||
|
||||
--Draw Canvas
|
||||
gc.setColor(1,1,1)
|
||||
gc_setColor(1,1,1)
|
||||
gc.draw(P.canvas,P.x,P.y,nil,P.size*10)
|
||||
if P.killMark then
|
||||
gc.setLineWidth(3)
|
||||
gc.setColor(1,0,0,min(P.endCounter,25)*.04)
|
||||
gc_setColor(1,0,0,min(P.endCounter,25)*.04)
|
||||
gc.circle("line",P.centerX,P.centerY,(840-20*min(P.endCounter,30))*P.size)
|
||||
end
|
||||
setFont(30)
|
||||
@@ -646,11 +675,11 @@ function draw.demo(P)
|
||||
gc.translate(P.fieldOff.x,P.fieldOff.y)
|
||||
|
||||
--Frame
|
||||
gc.setColor(0,0,0,.6)
|
||||
gc.rectangle("fill",0,0,300,600)
|
||||
gc_setColor(0,0,0,.6)
|
||||
gc_rectangle("fill",0,0,300,600)
|
||||
gc.setLineWidth(2)
|
||||
gc.setColor(1,1,1)
|
||||
gc.rectangle("line",-1,-1,302,602)
|
||||
gc_setColor(1,1,1)
|
||||
gc_rectangle("line",-1,-1,302,602)
|
||||
|
||||
gc.push("transform")
|
||||
gc.translate(0,600)
|
||||
@@ -674,7 +703,7 @@ function draw.demo(P)
|
||||
while P.holdQueue[N]do
|
||||
local id=P.holdQueue[N].id
|
||||
_=P.color[id]
|
||||
gc.setColor(_[1],_[2],_[3],.3)
|
||||
gc_setColor(_[1],_[2],_[3],.3)
|
||||
_=blockImg[id]
|
||||
gc.draw(_,15,40*N-10,nil,16,nil,0,_:getHeight()*.5)
|
||||
N=N+1
|
||||
@@ -685,7 +714,7 @@ function draw.demo(P)
|
||||
while N<=ENV.nextCount and P.nextQueue[N]do
|
||||
local id=P.nextQueue[N].id
|
||||
_=P.color[id]
|
||||
gc.setColor(_[1],_[2],_[3],.3)
|
||||
gc_setColor(_[1],_[2],_[3],.3)
|
||||
_=blockImg[id]
|
||||
gc.draw(_,285,40*N-10,nil,16,nil,_:getWidth(),_:getHeight()*.5)
|
||||
N=N+1
|
||||
|
||||
@@ -24,6 +24,8 @@ return{
|
||||
|
||||
highCam=false,
|
||||
nextPos=false,
|
||||
hideBoard=false,
|
||||
flipBoard=false,
|
||||
|
||||
drop=60,lock=60,
|
||||
wait=0,fall=0,
|
||||
|
||||
@@ -3,7 +3,7 @@ local prepareSequence=require"parts/player/prepareSequence"
|
||||
local gameEnv0=require"parts/player/gameEnv0"
|
||||
|
||||
local mt=love.math
|
||||
local rnd,max,min=math.random,math.max,math.min
|
||||
local rnd,max=math.random,math.max
|
||||
local ins=table.insert
|
||||
|
||||
local PLY={
|
||||
@@ -216,7 +216,7 @@ local function loadGameEnv(P)--Load gameEnv
|
||||
end
|
||||
if not ENV.noMod then
|
||||
for _,M in next,GAME.mod do
|
||||
M.func(P,M)
|
||||
M.func(P,M.list and M.list[M.sel])
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
@@ -747,7 +747,7 @@ do--Player.drop(P)--Place piece
|
||||
{300,1200,1700,4000,6000},--I
|
||||
{220,800,2000,3000,8000,26000},--Else
|
||||
}--B2Bmul:1.2/2.0; Mini*=.6
|
||||
local b2bPoint={50,100,180,1000,1200,9999}
|
||||
local b2bPoint={50,100,180,800,1000,9999}
|
||||
|
||||
local b2bATK={3,5,8,12,18}
|
||||
local reAtk={0,0,1,1,1,2,2,3,3}
|
||||
@@ -1052,7 +1052,7 @@ do--Player.drop(P)--Place piece
|
||||
cmb=cmb+1
|
||||
if dospin then
|
||||
cscore=(spinSCR[CB.name]or spinSCR[8])[cc]
|
||||
if P.b2b>1000 then
|
||||
if P.b2b>800 then
|
||||
P:showText(text.b3b..text.block[CB.name]..text.spin.." "..text.clear[cc],0,-30,35,"stretch")
|
||||
atk=b2bATK[cc]+cc*.5
|
||||
exblock=exblock+1
|
||||
@@ -1094,7 +1094,7 @@ do--Player.drop(P)--Place piece
|
||||
end
|
||||
elseif cc>=4 then
|
||||
cscore=cc==4 and 1000 or cc==5 and 1500 or 2000
|
||||
if P.b2b>1000 then
|
||||
if P.b2b>800 then
|
||||
P:showText(text.b3b..text.clear[cc],0,-30,50,"fly")
|
||||
atk=4*cc-10
|
||||
sendTime=100
|
||||
@@ -1134,7 +1134,7 @@ do--Player.drop(P)--Place piece
|
||||
exblock=exblock+2
|
||||
sendTime=sendTime+120
|
||||
if STAT.row+cc>4 then
|
||||
P.b2b=1200
|
||||
P.b2b=1000
|
||||
cscore=cscore+300*min(6+STAT.pc,10)
|
||||
else
|
||||
cscore=cscore+626
|
||||
@@ -1184,7 +1184,7 @@ do--Player.drop(P)--Place piece
|
||||
cscore=cscore+min(50*cmb,500)*(2*cc-1)
|
||||
end
|
||||
|
||||
if P.b2b>1200 then P.b2b=1200 end
|
||||
if P.b2b>1000 then P.b2b=1000 end
|
||||
|
||||
--Bonus atk/def when focused
|
||||
if GAME.modeEnv.royaleMode then
|
||||
@@ -1258,8 +1258,8 @@ do--Player.drop(P)--Place piece
|
||||
cscore=30
|
||||
end
|
||||
|
||||
if P.b2b>1000 then
|
||||
P.b2b=max(P.b2b-40,1000)
|
||||
if P.b2b>800 then
|
||||
P.b2b=max(P.b2b-40,800)
|
||||
end
|
||||
P:garbageRelease()
|
||||
end
|
||||
|
||||
@@ -333,8 +333,8 @@ local update={
|
||||
function update.dead(P,dt)
|
||||
if P.keyRec then
|
||||
local S=P.stat
|
||||
P.keySpeed=P.keySpeed*.96+S.key/S.frame*.04
|
||||
P.dropSpeed=P.dropSpeed*.96+S.piece/S.frame*.04
|
||||
P.keySpeed=P.keySpeed*.96+S.key/S.frame*144
|
||||
P.dropSpeed=P.dropSpeed*.96+S.piece/S.frame*144
|
||||
--Final average speeds
|
||||
if GAME.modeEnv.royaleMode then
|
||||
P.swappingAtkMode=min(P.swappingAtkMode+2,30)
|
||||
|
||||
@@ -1,12 +1,11 @@
|
||||
local gc=love.graphics
|
||||
local Timer=love.timer.getTime
|
||||
|
||||
local ins,rem=table.insert,table.remove
|
||||
local max,min=math.max,math.min
|
||||
|
||||
local texts={}
|
||||
local remain--People in chat room
|
||||
local scroll--Bottom message no.
|
||||
local scrollPos--Scroll up length
|
||||
local newMessage=false--If there is a new message
|
||||
local heartBeatTimer
|
||||
local escapeTimer=0
|
||||
@@ -23,7 +22,7 @@ local function sendMessage()
|
||||
end
|
||||
local function clearHistory()
|
||||
while #texts>1 do rem(texts)end
|
||||
scroll=1
|
||||
scrollPos=1
|
||||
SFX.play("fall")
|
||||
collectgarbage()
|
||||
end
|
||||
@@ -39,7 +38,7 @@ function scene.sceneInit()
|
||||
elseif #texts>1 and texts[#texts][1]~=COLOR.dG then
|
||||
ins(texts,{COLOR.dG,text.chatHistory})
|
||||
end
|
||||
scroll=#texts
|
||||
scrollPos=#texts
|
||||
TASK.new(focusAtTextbox)--Widgets are not initialized, so active after 1 frame
|
||||
BG.set("none")
|
||||
wsConnect(
|
||||
@@ -58,19 +57,19 @@ function scene.wheelMoved(_,y)
|
||||
end
|
||||
function scene.keyDown(k)
|
||||
if k=="up"then
|
||||
scroll=max(scroll-1,min(#texts,12))
|
||||
scrollPos=max(scrollPos-1,min(#texts,12))
|
||||
elseif k=="down"then
|
||||
scroll=min(scroll+1,#texts)
|
||||
if scroll==#texts then
|
||||
scrollPos=min(scrollPos+1,#texts)
|
||||
if scrollPos==#texts then
|
||||
newMessage=false
|
||||
end
|
||||
elseif k=="return"then
|
||||
sendMessage()
|
||||
elseif k=="escape"then
|
||||
if Timer()-escapeTimer<.6 then
|
||||
if TIME()-escapeTimer<.6 then
|
||||
SCN.back()
|
||||
else
|
||||
escapeTimer=Timer()
|
||||
escapeTimer=TIME()
|
||||
LOG.print(text.chatQuit,COLOR.orange)
|
||||
end
|
||||
else
|
||||
@@ -102,8 +101,8 @@ function scene.socketRead(mes)
|
||||
COLOR.sky,mes:sub(sep+1),
|
||||
})
|
||||
end
|
||||
if scroll==#texts-1 then
|
||||
scroll=scroll+1
|
||||
if scrollPos==#texts-1 then
|
||||
scrollPos=scrollPos+1
|
||||
else
|
||||
SFX.play("spin_0",.8)
|
||||
newMessage=true
|
||||
@@ -124,8 +123,8 @@ function scene.draw()
|
||||
gc.print(remain or"?",1205,10)
|
||||
|
||||
setFont(30)
|
||||
for i=max(scroll-11,1),scroll do
|
||||
gc.printf(texts[i],40,416-36*(scroll-i),1240)
|
||||
for i=max(scrollPos-11,1),scrollPos do
|
||||
gc.printf(texts[i],40,416-36*(scrollPos-i),1240)
|
||||
end
|
||||
|
||||
--Slider
|
||||
@@ -133,13 +132,13 @@ function scene.draw()
|
||||
gc.setLineWidth(2)
|
||||
gc.rectangle("line",10,30,20,420)
|
||||
local len=420*12/#texts
|
||||
gc.rectangle("fill",13,33+(414-len)*(scroll-12)/(#texts-12),14,len)
|
||||
gc.rectangle("fill",13,33+(414-len)*(scrollPos-12)/(#texts-12),14,len)
|
||||
end
|
||||
|
||||
--Draw
|
||||
if newMessage and scroll~=#texts then
|
||||
if newMessage and scrollPos~=#texts then
|
||||
setFont(40)
|
||||
gc.setColor(1,Timer()%.4<.2 and 1 or 0,0)
|
||||
gc.setColor(1,TIME()%.4<.2 and 1 or 0,0)
|
||||
gc.print("v",8,480)
|
||||
end
|
||||
end
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
local gc,sys=love.graphics,love.system
|
||||
local kb=love.keyboard
|
||||
local Timer=love.timer.getTime
|
||||
|
||||
local int=math.floor
|
||||
local find,sub=string.find,string.sub
|
||||
@@ -132,14 +131,14 @@ function scene.draw()
|
||||
--Field
|
||||
setFont(40)
|
||||
if initField and #FIELD>1 then
|
||||
gc.setColor(1,1,int(Timer()*6.26)%2)
|
||||
gc.setColor(1,1,int(TIME()*6.26)%2)
|
||||
gc.print("+",275,300)
|
||||
gc.print(#FIELD-1,300,300)
|
||||
end
|
||||
|
||||
--Sequence
|
||||
if #BAG>0 then
|
||||
gc.setColor(1,1,int(Timer()*6.26)%2)
|
||||
gc.setColor(1,1,int(TIME()*6.26)%2)
|
||||
gc.print("#",330,545)
|
||||
gc.print(#BAG,360,545)
|
||||
end
|
||||
@@ -149,7 +148,7 @@ function scene.draw()
|
||||
|
||||
--Sequence
|
||||
if #MISSION>0 then
|
||||
gc.setColor(1,CUSTOMENV.missionKill and 0 or 1,int(Timer()*6.26)%2)
|
||||
gc.setColor(1,CUSTOMENV.missionKill and 0 or 1,int(TIME()*6.26)%2)
|
||||
gc.print("#",610,545)
|
||||
gc.print(#MISSION,640,545)
|
||||
end
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
local gc,sys=love.graphics,love.system
|
||||
local kb=love.keyboard
|
||||
local Timer=love.timer.getTime
|
||||
|
||||
local int,sin=math.floor,math.sin
|
||||
local ins,rem=table.insert,table.remove
|
||||
@@ -160,7 +159,7 @@ function scene.draw()
|
||||
if N>0 then
|
||||
gc.setColor(libColor[set[N]])
|
||||
elseif L[i]>4 then
|
||||
gc.setColor(COLOR.rainbow(i+Timer()*6.26))
|
||||
gc.setColor(COLOR.rainbow(i+TIME()*6.26))
|
||||
else
|
||||
gc.setColor(COLOR.grey)
|
||||
end
|
||||
@@ -175,7 +174,7 @@ function scene.draw()
|
||||
until i>j+1
|
||||
|
||||
--Draw cursor
|
||||
gc.setColor(1,1,.4,.6+.4*sin(Timer()*6.26))
|
||||
gc.setColor(1,1,.4,.6+.4*sin(TIME()*6.26))
|
||||
gc.line(cx-5,cy-20,cx-5,cy+20)
|
||||
|
||||
--Confirm reset
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
local gc,sys=love.graphics,love.system
|
||||
local kb=love.keyboard
|
||||
local Timer=love.timer.getTime
|
||||
|
||||
local sin=math.sin
|
||||
local ins,rem=table.insert,table.remove
|
||||
@@ -171,7 +170,7 @@ function scene.draw()
|
||||
gc.print(#L,120,310)
|
||||
|
||||
--Draw cursor
|
||||
gc.setColor(.5,1,.5,.6+.4*sin(Timer()*6.26))
|
||||
gc.setColor(.5,1,.5,.6+.4*sin(TIME()*6.26))
|
||||
gc.line(cx-5,cy-20,cx-5,cy+20)
|
||||
|
||||
--Confirm reset
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
local gc=love.graphics
|
||||
local Timer=love.timer.getTime
|
||||
|
||||
local int,abs=math.floor,math.abs
|
||||
local min,sin=math.min,math.sin
|
||||
@@ -39,44 +38,21 @@ local function clearResult()
|
||||
for _=1,#result do rem(result)end
|
||||
selected,scrollPos,waiting,lastSearch=1,0,0,false
|
||||
end
|
||||
local miniGame={
|
||||
["15"]="15p",
|
||||
["15p"]="15p",
|
||||
hrd="15p",
|
||||
huarongdao="15p",
|
||||
shuzihuarongdao="15p",
|
||||
|
||||
schulte="schulteG",
|
||||
schulteg="schulteG",
|
||||
schultegrid="schulteG",
|
||||
shuerte="schulteG",
|
||||
shuertefangge="schulteG",
|
||||
|
||||
ping="pong",
|
||||
pong="pong",
|
||||
tanqiu="pong",
|
||||
|
||||
abc="AtoZ",
|
||||
abcde="AtoZ",
|
||||
abcdefg="AtoZ",
|
||||
atoz="AtoZ",
|
||||
AtoZ="AtoZ",
|
||||
dazi="AtoZ",
|
||||
|
||||
uttt="UTTT",
|
||||
tictactoe="UTTT",
|
||||
ultimatetictactoe="UTTT",
|
||||
ultimateTicTacToe="UTTT",
|
||||
jingziqi="UTTT",
|
||||
zhanluejingziqi="UTTT",
|
||||
|
||||
cf="cubefield",
|
||||
cbfd="cubefield",
|
||||
cubefield="cubefield",
|
||||
local eggInput={
|
||||
["15p"]="mg_15p",
|
||||
sltg="mg_schulteG",
|
||||
pong="mg_pong",
|
||||
atoz="mg_AtoZ",
|
||||
uttt="mg_UTTT",
|
||||
cbf="mg_cubefield",
|
||||
}
|
||||
local function search()
|
||||
if miniGame[input]then
|
||||
SCN.go("mg_"..miniGame[input])
|
||||
if eggInput[input]then
|
||||
if type(eggInput[input])=="string"then
|
||||
SCN.go(eggInput[input])
|
||||
elseif type(eggInput[input])=="function"then
|
||||
eggInput[input]()
|
||||
end
|
||||
else
|
||||
clearResult()
|
||||
local first
|
||||
@@ -172,20 +148,20 @@ function scene.draw()
|
||||
|
||||
local list=result[1]and result or dict
|
||||
gc.setColor(1,1,1)
|
||||
local text=list[selected][4]
|
||||
if #text>900 then
|
||||
local t=list[selected][4]
|
||||
if #t>900 then
|
||||
setFont(15)
|
||||
elseif #text>600 then
|
||||
elseif #t>600 then
|
||||
setFont(20)
|
||||
elseif #text>400 then
|
||||
elseif #t>400 then
|
||||
setFont(25)
|
||||
else
|
||||
setFont(30)
|
||||
end
|
||||
gc.printf(text,306,180,950)
|
||||
gc.printf(t,306,180,950)
|
||||
|
||||
setFont(30)
|
||||
gc.setColor(1,1,1,.4+.2*sin(Timer()*4))
|
||||
gc.setColor(1,1,1,.4+.2*sin(TIME()*4))
|
||||
gc.rectangle("fill",20,143+35*(selected-scrollPos),280,35)
|
||||
|
||||
setFont(30)
|
||||
@@ -207,10 +183,10 @@ function scene.draw()
|
||||
gc.rectangle("line",20,180,280,526)
|
||||
|
||||
if waiting>0 then
|
||||
local r=Timer()*2
|
||||
local r=TIME()*2
|
||||
local R=int(r)%7+1
|
||||
gc.setColor(1,1,1,1-abs(r%1*2-1))
|
||||
gc.draw(TEXTURE.miniBlock[R],785,140,Timer()*10%6.2832,15,15,spinCenters[R][0][2]+.5,#BLOCKS[R][0]-spinCenters[R][0][1]-.5)
|
||||
gc.draw(TEXTURE.miniBlock[R],785,140,TIME()*10%6.2832,15,15,spinCenters[R][0][2]+.5,#BLOCKS[R][0]-spinCenters[R][0][1]-.5)
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
local gc=love.graphics
|
||||
local Timer=love.timer.getTime
|
||||
|
||||
local sin=math.sin
|
||||
|
||||
@@ -10,23 +9,33 @@ function scene.sceneInit()
|
||||
end
|
||||
|
||||
function scene.draw()
|
||||
--Draw all texts
|
||||
setFont(20)
|
||||
gc.setColor(1,1,1)
|
||||
for i=1,#text.help do
|
||||
gc.printf(text.help[i],150,35*i+40,1000,"center")
|
||||
end
|
||||
|
||||
--Lib used
|
||||
setFont(15)
|
||||
gc.print(text.used,30,330)
|
||||
gc.draw(IMG.title,280,610,.1,1+.05*sin(Timer()*2.6),nil,206,35)
|
||||
|
||||
local t=TIME()
|
||||
--Sponsor code
|
||||
gc.draw(IMG.title,280,610,.1,1+.05*sin(t*2.6),nil,206,35)
|
||||
gc.setLineWidth(3)
|
||||
gc.rectangle("line",18,18,263,263)
|
||||
gc.rectangle("line",1012,18,250,250)
|
||||
|
||||
--Group code
|
||||
setFont(20)
|
||||
mStr(text.group,640,490)
|
||||
gc.setColor(1,1,1,sin(Timer()*20)*.3+.6)
|
||||
|
||||
--Support text
|
||||
gc.setColor(1,1,1,sin(t*20)*.3+.6)
|
||||
setFont(30)
|
||||
mStr(text.support,150+sin(Timer()*4)*20,283)
|
||||
mStr(text.support,1138-sin(Timer()*4)*20,270)
|
||||
mStr(text.support,150+sin(t*4)*20,283)
|
||||
mStr(text.support,1138-sin(t*4)*20,270)
|
||||
end
|
||||
|
||||
scene.widgetList={
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
local gc=love.graphics
|
||||
local Timer=love.timer.getTime
|
||||
|
||||
local abs=math.abs
|
||||
local max,min,sin,cos=math.max,math.min,math.sin,math.cos
|
||||
@@ -59,11 +58,11 @@ local titleTransform={
|
||||
end,
|
||||
function(t,i)
|
||||
local d=max(50-t,0)
|
||||
gc.translate(sin(Timer()*3+626*i)*d,cos(Timer()*3+626*i)*d)
|
||||
gc.translate(sin(TIME()*3+626*i)*d,cos(TIME()*3+626*i)*d)
|
||||
end,
|
||||
function(t,i)
|
||||
local d=max(50-t,0)
|
||||
gc.translate(sin(Timer()*3+626*i)*d,-cos(Timer()*3+626*i)*d)
|
||||
gc.translate(sin(TIME()*3+626*i)*d,-cos(TIME()*3+626*i)*d)
|
||||
end,
|
||||
function(t)
|
||||
gc.setColor(1,1,1,min(t*.02,1)+rnd()*.2)
|
||||
@@ -96,7 +95,7 @@ function scene.draw()
|
||||
gc.pop()
|
||||
if t2>=80 then
|
||||
gc.setColor(1,1,1,.6+sin((t2-80)*.0626)*.3)
|
||||
mText(drawableText.anykey,640,615+sin(Timer()*3)*5)
|
||||
mText(drawableText.anykey,640,615+sin(TIME()*3)*5)
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
local gc=love.graphics
|
||||
local tc=love.touch
|
||||
local Timer=love.timer.getTime
|
||||
|
||||
local max,min,sin=math.max,math.min,math.sin
|
||||
|
||||
@@ -175,6 +174,21 @@ function scene.update()
|
||||
gc.setCanvas()
|
||||
elseif phase==9 then
|
||||
SKIN.change(SETTING.skinSet)
|
||||
if newVersionLaunch then--Delete old ranks & Unlock modes which should be unlocked
|
||||
for name,rank in next,RANKS do
|
||||
local M=MODES[name]
|
||||
if M and M.unlock and rank>0 then
|
||||
for _,unlockName in next,M.unlock do
|
||||
if not RANKS[unlockName]then
|
||||
RANKS[unlockName]=0
|
||||
end
|
||||
end
|
||||
end
|
||||
if not(M and M.score)then
|
||||
RANKS[name]=nil
|
||||
end
|
||||
end
|
||||
end
|
||||
STAT.run=STAT.run+1
|
||||
LOADED=true
|
||||
SFX.play("welcome_sfx")
|
||||
@@ -224,14 +238,14 @@ function scene.draw()
|
||||
gc.setColor(.4,.4,.4)
|
||||
gc.rectangle("fill",0,0,440,260)
|
||||
|
||||
local T=Timer()
|
||||
local t=TIME()
|
||||
gc.setColor(COLOR.dCyan)
|
||||
mDraw(studioLogo,220,Y*.2-1204)
|
||||
mDraw(studioLogo,220,-Y*.2+1476)
|
||||
|
||||
gc.setColor(COLOR.cyan)
|
||||
mDraw(studioLogo,220+4*sin(T*10),136+4*sin(T*6))
|
||||
mDraw(studioLogo,220+4*sin(T*12),136+4*sin(T*8))
|
||||
mDraw(studioLogo,220+4*sin(t*10),136+4*sin(t*6))
|
||||
mDraw(studioLogo,220+4*sin(t*12),136+4*sin(t*8))
|
||||
|
||||
gc.setColor(COLOR.dCyan)
|
||||
mDraw(studioLogo,219,137)
|
||||
|
||||
@@ -11,7 +11,7 @@ local function tick_httpREQ_newLogin(task)
|
||||
LOG.print(text.loginSuccessed)
|
||||
USER.email=res.email
|
||||
USER.auth_token=res.auth_token
|
||||
FILE.save(USER,"conf/account","q")
|
||||
FILE.save(USER,"conf/user","q")
|
||||
|
||||
httpRequest(
|
||||
TICK.httpREQ_getAccessToken,
|
||||
|
||||
@@ -73,8 +73,8 @@ function scene.draw()
|
||||
gc.print(tip,50,660)
|
||||
local L=text.modes[STAT.lastPlay]
|
||||
setFont(25)
|
||||
gc.print(L[1],700,390)
|
||||
gc.print(L[2],700,420)
|
||||
gc.print(L[1],700,230)
|
||||
gc.print(L[2],700,260)
|
||||
PLAYERS[1]:draw()
|
||||
end
|
||||
|
||||
@@ -109,10 +109,10 @@ scene.widgetList={
|
||||
SCN.go("login")
|
||||
end
|
||||
end},
|
||||
WIDGET.newButton{name="custom", x=590,y=220,w=200,h=140,color="lBlue", font=40,code=WIDGET.lnk_goScene("customGame")},
|
||||
WIDGET.newButton{name="qplay", x=590,y=220,w=200,h=140,color="lBlue", font=40,code=function()loadGame(STAT.lastPlay,true)end},
|
||||
WIDGET.newButton{name="setting",x=150,y=380,w=200,h=140,color="lOrange",font=40,code=WIDGET.lnk_goScene("setting_game")},
|
||||
WIDGET.newButton{name="stat", x=370,y=380,w=200,h=140,color="lGreen", font=40,code=WIDGET.lnk_goScene("stat")},
|
||||
WIDGET.newButton{name="qplay", x=590,y=380,w=200,h=140,color="white", font=40,code=function()loadGame(STAT.lastPlay,true)end},
|
||||
WIDGET.newButton{name="custom", x=590,y=380,w=200,h=140,color="white", font=40,code=WIDGET.lnk_goScene("customGame")},
|
||||
WIDGET.newButton{name="lang", x=150,y=515,w=200,h=90,color="lYellow", font=40,code=WIDGET.lnk_goScene("lang")},
|
||||
WIDGET.newButton{name="help", x=370,y=515,w=200,h=90,color="dGreen", font=40,code=WIDGET.lnk_goScene("help")},
|
||||
WIDGET.newButton{name="quit", x=590,y=515,w=200,h=90,color="grey", font=40,code=function()VOC.play("bye")SCN.swapTo("quit","slowFade")end},
|
||||
|
||||
@@ -1,11 +1,8 @@
|
||||
local gc=love.graphics
|
||||
local Timer=love.timer.getTime
|
||||
|
||||
local mStr=mStr
|
||||
|
||||
local int=math.floor
|
||||
local rnd=math.random
|
||||
local int,rnd=math.floor,math.random
|
||||
local format=string.format
|
||||
local mStr=mStr
|
||||
|
||||
local scene={}
|
||||
|
||||
@@ -23,7 +20,7 @@ local pathVis
|
||||
local revKB
|
||||
|
||||
function scene.sceneInit()
|
||||
BG.set("rainbow")
|
||||
BG.set("rainbow2")
|
||||
BGM.play("push")
|
||||
board={{1,2,3,4},{5,6,7,8},{9,10,11,12},{13,14,15,16}}
|
||||
cx,cy=4,4
|
||||
@@ -120,11 +117,11 @@ local function tapBoard(x,y,key)
|
||||
move=move+moves
|
||||
if state==0 then
|
||||
state=1
|
||||
startTime=Timer()
|
||||
startTime=TIME()
|
||||
end
|
||||
if checkBoard(b)then
|
||||
state=2
|
||||
time=Timer()-startTime
|
||||
time=TIME()-startTime
|
||||
if time<1 then LOG.print("不是人",COLOR.lBlue)
|
||||
elseif time<2 then LOG.print("还是人",COLOR.lBlue)
|
||||
elseif time<3 then LOG.print("神仙",COLOR.lBlue)
|
||||
@@ -203,7 +200,7 @@ end
|
||||
|
||||
function scene.update()
|
||||
if state==1 then
|
||||
time=Timer()-startTime
|
||||
time=TIME()-startTime
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
@@ -1,8 +1,6 @@
|
||||
local gc=love.graphics
|
||||
local Timer=love.timer.getTime
|
||||
local rnd=math.random
|
||||
local format=string.format
|
||||
|
||||
local mStr=mStr
|
||||
|
||||
local levels={
|
||||
@@ -63,9 +61,9 @@ function scene.keyDown(key)
|
||||
SFX.play("move")
|
||||
if progress==2 then
|
||||
state=1
|
||||
startTime=Timer()
|
||||
startTime=TIME()
|
||||
elseif progress>#targetString then
|
||||
time=Timer()-startTime
|
||||
time=TIME()-startTime
|
||||
state=2
|
||||
SFX.play("reach")
|
||||
end
|
||||
@@ -87,7 +85,7 @@ end
|
||||
function scene.update()
|
||||
if state==1 then
|
||||
frameKeyCount=0
|
||||
time=Timer()-startTime
|
||||
time=TIME()-startTime
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
local gc=love.graphics
|
||||
local int=math.floor
|
||||
local Timer=love.timer.getTime
|
||||
|
||||
local lines={
|
||||
{1,2,3},
|
||||
@@ -28,7 +27,7 @@ local function restart()
|
||||
curX,curx=nil
|
||||
round=0
|
||||
target=false
|
||||
placeTime=Timer()
|
||||
placeTime=TIME()
|
||||
gameover=false
|
||||
for X=1,9 do
|
||||
score[X]=false
|
||||
@@ -61,7 +60,7 @@ local function place(X,x)
|
||||
SFX.play("move")
|
||||
lastX,lastx=X,x
|
||||
curX,curx=nil
|
||||
placeTime=Timer()
|
||||
placeTime=TIME()
|
||||
if checkBoard(board[X],round)then
|
||||
score[X]=round
|
||||
if checkBoard(score,round)then
|
||||
@@ -98,7 +97,7 @@ local scene={}
|
||||
function scene.sceneInit()
|
||||
restart()
|
||||
BGM.play("truth")
|
||||
BG.set("bg2")
|
||||
BG.set("rainbow")
|
||||
end
|
||||
|
||||
function scene.draw()
|
||||
@@ -112,7 +111,7 @@ function scene.draw()
|
||||
gc.rectangle("fill",0,0,90,90)
|
||||
|
||||
--Draw target area
|
||||
gc.setColor(1,1,1,math.sin((Timer()-placeTime)*5)/5+.2)
|
||||
gc.setColor(1,1,1,math.sin((TIME()-placeTime)*5)/5+.2)
|
||||
if target then
|
||||
gc.rectangle("fill",(target-1)%3*30,int((target-1)/3)*30,30,30)
|
||||
elseif not gameover then
|
||||
@@ -165,7 +164,7 @@ function scene.draw()
|
||||
--Draw last pos
|
||||
if lastX then
|
||||
gc.setColor(.5,1,.4,.8)
|
||||
local r=.5+.5*math.sin(Timer()*6.26)
|
||||
local r=.5+.5*math.sin(TIME()*6.26)
|
||||
gc.rectangle("line",(lastX-1)%3*30+(lastx-1)%3*10-r,int((lastX-1)/3)*30+int((lastx-1)/3)*10-r,10+2*r,10+2*r)
|
||||
end
|
||||
gc.pop()
|
||||
|
||||
@@ -1,14 +1,11 @@
|
||||
local gc=love.graphics
|
||||
local ms=love.mouse
|
||||
local Timer=love.timer.getTime
|
||||
|
||||
local setFont=setFont
|
||||
local mStr=mStr
|
||||
|
||||
local int=math.floor
|
||||
local rnd=math.random
|
||||
local int,rnd=math.floor,math.random
|
||||
local format=string.format
|
||||
local rem=table.remove
|
||||
local setFont=setFont
|
||||
local mStr=mStr
|
||||
|
||||
local scene={}
|
||||
|
||||
@@ -23,6 +20,7 @@ local mistake
|
||||
local state
|
||||
local progress
|
||||
function scene.sceneInit()
|
||||
BG.set("space")
|
||||
BGM.play("way")
|
||||
board={}
|
||||
rank=3
|
||||
@@ -52,7 +50,7 @@ local function tapBoard(x,y)
|
||||
if state==0 then
|
||||
newBoard()
|
||||
state=1
|
||||
startTime=Timer()
|
||||
startTime=TIME()
|
||||
progress=0
|
||||
elseif state==1 then
|
||||
local X=int((x-320)/640*R)
|
||||
@@ -63,7 +61,7 @@ local function tapBoard(x,y)
|
||||
if progress<R^2 then
|
||||
SFX.play("lock")
|
||||
else
|
||||
time=Timer()-startTime+mistake
|
||||
time=TIME()-startTime+mistake
|
||||
state=2
|
||||
SFX.play("reach")
|
||||
end
|
||||
@@ -121,7 +119,7 @@ end
|
||||
|
||||
function scene.update()
|
||||
if state==1 then
|
||||
time=Timer()-startTime+mistake
|
||||
time=TIME()-startTime+mistake
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
local mt=love.math
|
||||
local gc=love.graphics
|
||||
local ms,kb,tc=love.mouse,love.keyboard,love.touch
|
||||
local Timer=love.timer.getTime
|
||||
|
||||
local max,min=math.max,math.min
|
||||
local int,abs=math.floor,math.abs
|
||||
@@ -217,7 +216,7 @@ function scene.draw()
|
||||
if c then
|
||||
gc.setColor(c)
|
||||
else
|
||||
c=.5+sin(Timer()*6.26)*.2
|
||||
c=.5+sin(TIME()*6.26)*.2
|
||||
gc.setColor(c,c,c)
|
||||
end
|
||||
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
local gc=love.graphics
|
||||
local Timer=love.timer.getTime
|
||||
|
||||
local sin=math.sin
|
||||
|
||||
@@ -63,13 +62,14 @@ function scene.draw()
|
||||
gc.draw(IMG.title,840,220,nil,1.5,nil,206,35)
|
||||
if BGM.nowPlay then
|
||||
setFont(50)
|
||||
gc.setColor(sin(Timer()*.5)*.2+.8,sin(Timer()*.7)*.2+.8,sin(Timer())*.2+.8)
|
||||
local t=TIME()
|
||||
gc.setColor(sin(t*.5)*.2+.8,sin(t*.7)*.2+.8,sin(t)*.2+.8)
|
||||
gc.print(BGM.nowPlay,710,500)
|
||||
|
||||
local t=-Timer()%2.3/2
|
||||
if t<1 then
|
||||
gc.setColor(1,1,1,t)
|
||||
gc.draw(IMG.title_color,840,220,nil,1.5+.1-.1*t,1.5+.3-.3*t,206,35)
|
||||
local a=-t%2.3/2
|
||||
if a<1 then
|
||||
gc.setColor(1,1,1,a)
|
||||
gc.draw(IMG.title_color,840,220,nil,1.5+.1-.1*a,1.5+.3-.3*a,206,35)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
local gc=love.graphics
|
||||
local Timer=love.timer.getTime
|
||||
|
||||
local int=math.floor
|
||||
local sin,log=math.sin,math.log10
|
||||
@@ -269,7 +268,7 @@ function scene.draw()
|
||||
--Polygon
|
||||
gc.push("transform")
|
||||
gc.scale((3-2*T)*T)
|
||||
gc.setColor(1,1,1,T*(.5+.3*sin(Timer()*6.26)))gc.polygon("line",standard)
|
||||
gc.setColor(1,1,1,T*(.5+.3*sin(TIME()*6.26)))gc.polygon("line",standard)
|
||||
gc.setColor(chartColor[1],chartColor[2],chartColor[3],T*.626)
|
||||
for i=1,9,2 do
|
||||
gc.polygon("fill",0,0,val[i],val[i+1],val[i+2],val[i+3])
|
||||
@@ -287,7 +286,7 @@ function scene.draw()
|
||||
|
||||
--Texts
|
||||
local C
|
||||
_=Timer()%6.2832
|
||||
_=TIME()%6.2832
|
||||
if _>3.1416 then
|
||||
gc.setColor(1,1,1,-T*sin(_))
|
||||
setFont(35)
|
||||
|
||||
@@ -1,12 +1,10 @@
|
||||
local gc=love.graphics
|
||||
local tc=love.touch
|
||||
local Timer=love.timer.getTime
|
||||
local TIME=TIME
|
||||
|
||||
local max,sin=math.max,math.sin
|
||||
local log=math.log
|
||||
|
||||
local SCR=SCR--play/pause
|
||||
|
||||
local SCR=SCR
|
||||
local VK=virtualkey
|
||||
local function onVirtualkey(x,y)
|
||||
local dist,nearest=1e10
|
||||
@@ -24,8 +22,7 @@ local function onVirtualkey(x,y)
|
||||
return nearest
|
||||
end
|
||||
|
||||
local noTouch
|
||||
local noKey
|
||||
local noTouch,noKey
|
||||
|
||||
local scene={}
|
||||
|
||||
@@ -239,7 +236,7 @@ function scene.update(dt)
|
||||
end
|
||||
end
|
||||
end
|
||||
GAME.warnLVL0=log(height-15+P1.atkBuffer.sum*.8)
|
||||
GAME.warnLVL0=math.log(height-15+P1.atkBuffer.sum*.8)
|
||||
end
|
||||
_=GAME.warnLVL
|
||||
if _<GAME.warnLVL0 then
|
||||
@@ -254,10 +251,10 @@ function scene.update(dt)
|
||||
end
|
||||
|
||||
local function drawAtkPointer(x,y)
|
||||
local t=sin(Timer()*20)
|
||||
local t=sin(TIME()*20)
|
||||
gc.setColor(.2,.7+t*.2,1,.6+t*.4)
|
||||
gc.circle("fill",x,y,25,6)
|
||||
local a=Timer()*3%1*.8
|
||||
local a=TIME()*3%1*.8
|
||||
gc.setColor(0,.6,1,.8-a)
|
||||
gc.circle("line",x,y,30*(1+a),6)
|
||||
end
|
||||
@@ -299,9 +296,9 @@ local function drawVirtualkey()
|
||||
end
|
||||
end
|
||||
function scene.draw()
|
||||
local t=TIME()
|
||||
if MARKING then
|
||||
setFont(25)
|
||||
local t=Timer()
|
||||
gc.setColor(1,1,1,.2+.1*(sin(3*t)+sin(2.6*t)))
|
||||
mStr(text.marking,190,60+26*sin(t))
|
||||
end
|
||||
@@ -337,7 +334,7 @@ function scene.draw()
|
||||
|
||||
--Replaying
|
||||
if GAME.replaying then
|
||||
gc.setColor(1,1,Timer()%1>.5 and 1 or 0)
|
||||
gc.setColor(1,1,t%1>.5 and 1 or 0)
|
||||
mText(drawableText.replaying,410,17)
|
||||
end
|
||||
|
||||
@@ -345,7 +342,6 @@ function scene.draw()
|
||||
gc.push("transform")
|
||||
gc.origin()
|
||||
if GAME.warnLVL>0 then
|
||||
gc.setColor(0,0,0,0)
|
||||
SHADER.warning:send("level",GAME.warnLVL)
|
||||
gc.setShader(SHADER.warning)
|
||||
gc.rectangle("fill",0,0,SCR.w,SCR.h)
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
local gc=love.graphics
|
||||
local Timer=love.timer.getTime
|
||||
|
||||
local int=math.floor
|
||||
|
||||
local scene={}
|
||||
@@ -14,7 +12,7 @@ end
|
||||
|
||||
function scene.draw()
|
||||
gc.setColor(1,1,1)
|
||||
gc.draw(SKIN.curText[int(Timer()*2)%16+1],740,540,Timer()%6.28319,2,nil,15,15)
|
||||
gc.draw(SKIN.curText[int(TIME()*2)%16+1],740,540,TIME()%6.28319,2,nil,15,15)
|
||||
end
|
||||
|
||||
scene.widgetList={
|
||||
|
||||
@@ -1,9 +1,6 @@
|
||||
local gc=love.graphics
|
||||
local Timer=love.timer.getTime
|
||||
|
||||
local mStr=mStr
|
||||
|
||||
local int,sin=math.floor,math.sin
|
||||
local mStr=mStr
|
||||
|
||||
local scene={}
|
||||
|
||||
@@ -92,7 +89,7 @@ function scene.gamepadDown(key)
|
||||
end
|
||||
|
||||
function scene.draw()
|
||||
local a=.3+sin(Timer()*15)*.1
|
||||
local a=.3+sin(TIME()*15)*.1
|
||||
if kS then gc.setColor(1,.3,.3,a)else gc.setColor(1,.7,.7,a)end
|
||||
gc.rectangle("fill",
|
||||
kb<11 and 240 or 840,
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
local gc=love.graphics
|
||||
local Timer=love.timer.getTime
|
||||
local sin=math.sin
|
||||
|
||||
local scene={}
|
||||
@@ -18,7 +17,7 @@ function scene.draw()
|
||||
gc.draw(texture[color],x+30*j,y-30*i)
|
||||
end
|
||||
end end
|
||||
gc.circle("fill",-10+140*N,340,sin(Timer()*10)+5)
|
||||
gc.circle("fill",-10+140*N,340,sin(TIME()*10)+5)
|
||||
end
|
||||
gc.draw(texture[17],930,610,nil,2)
|
||||
for i=1,5 do
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
local gc=love.graphics
|
||||
local Timer=love.timer.getTime
|
||||
|
||||
local sin=math.sin
|
||||
local rnd=math.random
|
||||
@@ -23,10 +22,10 @@ end
|
||||
function scene.mouseDown(x,y)
|
||||
if x>780 and x<980 and y>470 and jump==0 then
|
||||
jump=10
|
||||
local t=Timer()-last
|
||||
local t=TIME()-last
|
||||
if t>1 then
|
||||
VOC.play((t<1.5 or t>15)and"doubt"or rnd()<.8 and"happy"or"egg")
|
||||
last=Timer()
|
||||
last=TIME()
|
||||
end
|
||||
end
|
||||
end
|
||||
@@ -43,7 +42,7 @@ end
|
||||
|
||||
function scene.draw()
|
||||
gc.setColor(1,1,1)
|
||||
local t=Timer()
|
||||
local t=TIME()
|
||||
local _=jump
|
||||
local x,y=800,340+10*sin(t*.5)+(_-10)*_*.3
|
||||
gc.translate(x,y)
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
local gc=love.graphics
|
||||
local ms=love.mouse
|
||||
local Timer=love.timer.getTime
|
||||
|
||||
local int,sin=math.floor,math.sin
|
||||
|
||||
@@ -91,7 +90,7 @@ function scene.draw()
|
||||
local d=snapUnit
|
||||
if d>=10 then
|
||||
gc.setLineWidth(3)
|
||||
gc.setColor(1,1,1,sin(Timer()*4)*.1+.1)
|
||||
gc.setColor(1,1,1,sin(TIME()*4)*.1+.1)
|
||||
for i=1,1280/d-1 do
|
||||
gc.line(d*i,0,d*i,720)
|
||||
end
|
||||
|
||||
@@ -1,9 +1,7 @@
|
||||
local gc=love.graphics
|
||||
local Timer=love.timer.getTime
|
||||
|
||||
local abs,int,sin=math.abs,math.floor,math.sin
|
||||
local format=string.format
|
||||
|
||||
local mStr=mStr
|
||||
|
||||
local scene={}
|
||||
@@ -88,17 +86,18 @@ function scene.draw()
|
||||
gc.line(40,240+40*y,600,240+40*y)
|
||||
end
|
||||
|
||||
gc.draw(IMG.title,260,615,.2+.04*sin(Timer()*3),nil,nil,206,35)
|
||||
local t=TIME()
|
||||
gc.draw(IMG.title,260,615,.2+.04*sin(t*3),nil,nil,206,35)
|
||||
|
||||
local r=Timer()*2
|
||||
local r=t*2
|
||||
local R=int(r)%7+1
|
||||
gc.setColor(1,1,1,1-abs(r%1*2-1))
|
||||
gc.draw(TEXTURE.miniBlock[R],680,50,Timer()*10%6.2832,15,15,spinCenters[R][0][2]+.5,#BLOCKS[R][0]-spinCenters[R][0][1]-.5)
|
||||
gc.draw(TEXTURE.miniBlock[R],680,50,t*10%6.2832,15,15,spinCenters[R][0][2]+.5,#BLOCKS[R][0]-spinCenters[R][0][1]-.5)
|
||||
gc.draw(TEXTURE.miniBlock[R],680,300,0,15,15,spinCenters[R][0][2]+.5,#BLOCKS[R][0]-spinCenters[R][0][1]-.5)
|
||||
end
|
||||
|
||||
scene.widgetList={
|
||||
WIDGET.newButton{name="path",x=1000,y=540,w=250,h=80,font=25,code=function()love.system.openURL(love.filesystem.getSaveDirectory())end,hide=MOBILE},
|
||||
WIDGET.newButton{name="path",x=1000,y=540,w=250,h=80,font=25,code=function()love.system.openURL(SAVEDIR)end,hide=MOBILE},
|
||||
WIDGET.newButton{name="save",x=1000,y=640,w=250,h=80,font=25,code=WIDGET.lnk_goScene("savedata")},
|
||||
WIDGET.newButton{name="back",x=640,y=620,w=200,h=80,font=35,code=WIDGET.lnk_BACK},
|
||||
}
|
||||
|
||||
@@ -10,7 +10,7 @@ function Tick.httpREQ_getAccessToken(task)
|
||||
if res then
|
||||
LOG.print(text.accessSuccessed)
|
||||
USER.access_token=res.access_token
|
||||
FILE.save(USER,"conf/account")
|
||||
FILE.save(USER,"conf/user")
|
||||
SCN.swapTo("netgame")
|
||||
else
|
||||
LOG.print(text.netErrorCode..response.code..": "..res.message,"warn")
|
||||
|
||||
@@ -3,12 +3,12 @@ local S=[=[
|
||||
<<<<<<<<<<rmb1000+>>>>>>>>>>
|
||||
★☆白羽☆★
|
||||
<<<rmb100+>>>
|
||||
\那没事了(T6300)/ \加油啊,钉钉动了的大哥哥(T3228)/
|
||||
\那没事了(T6300)/ \加油啊,钉钉动了的大哥哥(T3228)/
|
||||
\弥佑瑶/ \Alan/ \幽灵3383/
|
||||
\靏鸖龘龘/ \込余/ \saki/
|
||||
\模电/ \吃水榴莲/ \世界沃德/
|
||||
\Petris/ \Zakeru/ \镝/
|
||||
\HitachiMako/ \我慌死了/ \JogsIntang/
|
||||
\HitachiMako/ \我慌死了/ \PESWGGL/
|
||||
<rmb10+>
|
||||
八零哥 蕴空之灵 gggf127 dtg ThTsOd Fireboos 金巧 10元
|
||||
立斐 Deep_Sea 时雪 yyangdid sfqr 心痕 Sasoric 夏小亚
|
||||
@@ -31,17 +31,44 @@ local S=[=[
|
||||
OSD
|
||||
其他:
|
||||
小游戏:
|
||||
Tetro-1010(四连块,next,hold,20G)
|
||||
2048 (带预览; 后妈发牌)
|
||||
Tetro-1010(四/五连块, 2cur, 2next, 随机重力)
|
||||
2048 (1next, 固定规则发牌(轮格,移动顺/反方向...))
|
||||
扫雷; 坦克大战
|
||||
打砖块; 速算; 各种计算器小游戏移植
|
||||
录像保存/导出; 联网游戏; 全新模式选择; 游戏内文档
|
||||
机器人调试模式; 按块回放录像; 跳帧开关
|
||||
隔断消除; 混合消除; 彩色消除; 物理hold; 多方块; 自由场地尺寸
|
||||
自定义游戏按各种目标复制数据; 画图智能画笔
|
||||
按块回放录像; 联网对战
|
||||
UI重做; 游戏内文档
|
||||
隔断消除; 架空消除; 混合消除; 彩色消除
|
||||
物理hold; 多方块; 自由场地尺寸
|
||||
画图智能画笔; 自定义游戏按各种目标复制数据
|
||||
任意尺寸屏幕的UI; 3D背景; 1/2/3连块
|
||||
移动n格+硬降复合操作键; 手柄操作; 手势操作; 特殊控件(虚拟摇杆等)
|
||||
task-Z(新AI); 热更新; 工程编译到字节码; 超60帧
|
||||
移动n格+硬降复合操作键; 手柄操作; 手势操作
|
||||
特殊控件(虚拟摇杆等); task-Z(新AI); 机器人调试模式
|
||||
热更新; 工程编译到字节码; 超60帧; 跳帧开关
|
||||
|
||||
0.12.8: 皮肤调整 Better Skins
|
||||
改动:
|
||||
b3b触发点和上限都减小200,变为800和1000
|
||||
新增/删除几个方块皮肤
|
||||
调整部分皮肤亮度
|
||||
代码:
|
||||
尝试让文件读取更安全
|
||||
尝试修正读取老版本存档的错误
|
||||
修复:
|
||||
手机第一次安装永远进不去
|
||||
每次启动游戏统计信息的消除信息必定丢失
|
||||
游戏结束后两个码表显示不正确
|
||||
|
||||
0.12.7: 视野 Sight
|
||||
新增:
|
||||
场地遮挡和场地反转的mod完成
|
||||
改动:
|
||||
回合制模式垃圾上涨速度调快
|
||||
代码:
|
||||
调整转换存档/加载文件的逻辑
|
||||
COLOR模块小升级
|
||||
修复:
|
||||
win和linux缺库不会再闪退了
|
||||
许多神秘小错误
|
||||
|
||||
0.12.6: 系统升级 System Update
|
||||
新增:
|
||||
@@ -52,6 +79,7 @@ local S=[=[
|
||||
游戏开始开始两秒后或者确实结束后才计入统计数据
|
||||
所有小游戏入口移至词典
|
||||
极限马拉松入口隐藏
|
||||
移除maxNext设置项
|
||||
代码:
|
||||
FILE模块修改,将所有文件换后缀放文件夹分类整理方便管理
|
||||
"远程玩家"进入可用测试阶段
|
||||
|
||||