Zframework允许外部设置开关电量显示的条件函数

This commit is contained in:
MrZ626
2021-09-14 17:24:37 +08:00
parent 18471a201f
commit b48e65a9d8
2 changed files with 16 additions and 9 deletions

View File

@@ -60,16 +60,19 @@ do
local ms=love.mouse
Z.setCursor(function(time,x,y)
if not SETTING.sysCursor then
local R=int((time+1)/2)%7+1
_=minoColor[SETTING.skin[R]]
gc_setColor(_[1],_[2],_[3],min(abs(1-time%2),.3))
_=DSCP[R][0]
gc_draw(TEXTURE.miniBlock[R],x,y,time%3.14159265359*4,16,16,_[2]+.5,#BLOCKS[R][0]-_[1]-.5)
gc_setColor(1,1,1)
gc_draw(ms.isDown(1)and holdImg or normImg,x,y,nil,nil,nil,8,8)
local R=int((time+1)/2)%7+1
_=minoColor[SETTING.skin[R]]
gc_setColor(_[1],_[2],_[3],min(abs(1-time%2),.3))
_=DSCP[R][0]
gc_draw(TEXTURE.miniBlock[R],x,y,time%3.14159265359*4,16,16,_[2]+.5,#BLOCKS[R][0]-_[1]-.5)
gc_setColor(1,1,1)
gc_draw(ms.isDown(1)and holdImg or normImg,x,y,nil,nil,nil,8,8)
end
end)
end
Z.setIfPowerInfo(function()
return SETTING.powerInfo and LOADED
end)
FONT.init('parts/fonts/puhui.ttf')
setFont=FONT.set