几个音频模块和skin模块load附加必须先init的条件
This commit is contained in:
@@ -2,6 +2,8 @@ local BGM={
|
|||||||
default=false,
|
default=false,
|
||||||
getList=function()error("Can't getList before initialized!")end,
|
getList=function()error("Can't getList before initialized!")end,
|
||||||
getCount=function()return 0 end,
|
getCount=function()return 0 end,
|
||||||
|
loadOne=function()error("Cannot load before init!")end,
|
||||||
|
loadAll=function()error("Cannot load before init!")end,
|
||||||
play=NULL,
|
play=NULL,
|
||||||
freshVolume=NULL,
|
freshVolume=NULL,
|
||||||
stop=NULL,
|
stop=NULL,
|
||||||
|
|||||||
@@ -1,5 +1,7 @@
|
|||||||
local IMG={
|
local IMG={
|
||||||
getCount=function()return 0 end,
|
getCount=function()return 0 end,
|
||||||
|
loadOne=function()error("Cannot load before init!")end,
|
||||||
|
loadAll=function()error("Cannot load before init!")end,
|
||||||
}
|
}
|
||||||
function IMG.init(list)
|
function IMG.init(list)
|
||||||
IMG.init=nil
|
IMG.init=nil
|
||||||
|
|||||||
@@ -1,5 +1,7 @@
|
|||||||
local SFX={
|
local SFX={
|
||||||
getCount=function()return 0 end,
|
getCount=function()return 0 end,
|
||||||
|
loadOne=function()error("Cannot load before init!")end,
|
||||||
|
loadAll=function()error("Cannot load before init!")end,
|
||||||
fieldPlay=NULL,
|
fieldPlay=NULL,
|
||||||
play=NULL,
|
play=NULL,
|
||||||
fplay=NULL,
|
fplay=NULL,
|
||||||
|
|||||||
@@ -3,7 +3,6 @@ local gc_setColor,gc_setLineWidth=gc.setColor,gc.setLineWidth
|
|||||||
local gc_draw,gc_line=gc.draw,gc.line
|
local gc_draw,gc_line=gc.draw,gc.line
|
||||||
local gc_rectangle,gc_circle=gc.rectangle,gc.circle
|
local gc_rectangle,gc_circle=gc.rectangle,gc.circle
|
||||||
|
|
||||||
local sin,cos=math.sin,math.cos
|
|
||||||
local max,min=math.max,math.min
|
local max,min=math.max,math.min
|
||||||
local rnd=math.random
|
local rnd=math.random
|
||||||
local ins,rem=table.insert,table.remove
|
local ins,rem=table.insert,table.remove
|
||||||
|
|||||||
@@ -1,6 +1,8 @@
|
|||||||
local VOC={
|
local VOC={
|
||||||
getCount=function()return 0 end,
|
getCount=function()return 0 end,
|
||||||
getQueueCount=function()return 0 end,
|
getQueueCount=function()return 0 end,
|
||||||
|
loadOne=function()error("Cannot load before init!")end,
|
||||||
|
loadAll=function()error("Cannot load before init!")end,
|
||||||
getFreeChannel=NULL,
|
getFreeChannel=NULL,
|
||||||
play=NULL,
|
play=NULL,
|
||||||
update=NULL,
|
update=NULL,
|
||||||
|
|||||||
@@ -1,5 +1,7 @@
|
|||||||
local SKIN={
|
local SKIN={
|
||||||
getCount=function()return 0 end,
|
getCount=function()return 0 end,
|
||||||
|
loadOne=function()error("Cannot load before init!")end,
|
||||||
|
loadAll=function()error("Cannot load before init!")end,
|
||||||
prevSet=NULL,
|
prevSet=NULL,
|
||||||
nextSet=NULL,
|
nextSet=NULL,
|
||||||
prev=NULL,
|
prev=NULL,
|
||||||
|
|||||||
Reference in New Issue
Block a user