背景系统增加“默认背景”功能,新增节日飘雪背景

This commit is contained in:
MrZ626
2020-12-25 20:23:16 +08:00
parent 4850cdb292
commit 1729e1f36d
12 changed files with 77 additions and 11 deletions

View File

@@ -7,6 +7,7 @@ local BGlist={
}
local BG={
cur="none",
defaultBG="none",
init=false,
resize=false,
update=NULL,
@@ -23,7 +24,13 @@ function BG.send(...)
BG.event(...)
end
end
function BG.setDefaultBG(bg)
defaultBG=bg
end
function BG.set(background)
if not background then
background=defaultBG
end
if background==BG.cur or not SETTING.bg then return end
BG.discard()
BG.cur=background