--舞蹈信息配置
local dance = {
	["Count"] = 17,		--配置当前舞蹈总数
	--下面配置舞蹈信息，从0开始递增
	[0] = {
		["DanceID"]=1380,
		["DanceImg"]="Action_Dance2Btn",
		["DanceAct"]=2,
	},
	[1] = {
		["DanceID"]=1385,
		["DanceImg"]="Action_Dance3Btn",
		["DanceAct"]=3,
	},
	[2] = {
		["DanceID"]=1390,
		["DanceImg"]="Action_Dance4Btn",
		["DanceAct"]=4,
	},
	[3] = {
		["DanceID"]=1395,
		["DanceImg"]="Action_Dance5Btn",
		["DanceAct"]=5,
	},
	[4] = {
		["DanceID"]=1400,
		["DanceImg"]="Action_Dance6Btn",
		["DanceAct"]=6,
	},
	[5] = {
		["DanceID"]=1405,
		["DanceImg"]="Action_Dance7Btn",
		["DanceAct"]=7,
	},
	[6] = {
		["DanceID"]=1410,
		["DanceImg"]="Action_Dance8Btn",
		["DanceAct"]=8,
	},
	[7] = {
		["DanceID"]=1415,
		["DanceImg"]="Action_Dance13Btn",
		["DanceAct"]=13,
	},
	[8] = {
		["DanceID"]=1416,
		["DanceImg"]="Action_Dance14Btn",
		["DanceAct"]=14,
	},
	[9] = {
		["DanceID"]=1417,
		["DanceImg"]="Action_Dance15Btn",	
		["DanceAct"]=15,
	},
	[10] = {
		["DanceID"]=1418,
		["DanceImg"]="Action_Dance16Btn",
		["DanceAct"]=16,
	},
	[11] = {
		["DanceID"]=1419,
		["DanceImg"]="Action_Dance17Btn",
		["DanceAct"]=17,
	},
	[12] = {
		["DanceID"]=1420,
		["DanceImg"]="Action_Dance18Btn",
		["DanceAct"]=18,
	},
	[13] = {
		["DanceID"]=1421,
		["DanceImg"]="Action_Dance19Btn",
		["DanceAct"]=19,
	},
	[14] = {
		["DanceID"]=1422,
		["DanceImg"]="Action_Dance20Btn",
		["DanceAct"]=20,
	},
	[15] = {
		["DanceID"]=1423,
		["DanceImg"]="Action_Dance21Btn",
		["DanceAct"]=21,
	},
	[16] = {
		["DanceID"]=25050,
		["DanceImg"]="Action_Dance22Btn",
		["DanceAct"]=25,
	},
}

local function GetDanceCount()
	local keyValue = dance["Count"]

	if (keyValue) then
		return keyValue
	end
	
	return 0
end

local function GetDanceInfo(id, key)
	local keyValue = dance[id][key]

	if (keyValue) then
		return keyValue
	end
	
	return 0
end

local function GetDanceAct(id)
	local count = dance["Count"]
	if count == nil or count <= 0 then
		return 0
	end
	
	for i = 1, count do
		if dance[i] ~= nil and dance[i]["DanceID"] == id then
			return dance[i]["DanceAct"]
		end
	end
	
	return 0
end

local function IsDanceSkill(id)
	local count = dance["Count"]
	if count == nil or count <= 0 then
		return false
	end
	
	for i = 1, count do
		if dance[i] ~= nil and dance[i]["DanceID"] == id then
			return true
		end
	end
	
	return false
end


local DanceInfo = {
    GetDanceCount = GetDanceCount,
	GetDanceInfo = GetDanceInfo,
	GetDanceAct = GetDanceAct,
	IsDanceSkill = IsDanceSkill,
    Unload = Unload,
}

-- global
DanceInfo_GetDanceCount = DanceInfo.GetDanceCount
DanceInfo_GetDanceInfo = DanceInfo.GetDanceInfo
DanceInfo_GetDanceAct = DanceInfo.GetDanceAct
DanceInfo_IsDanceSkill = DanceInfo.IsDanceSkill
DanceInfo_Unload = DanceInfo.Unload

return DanceInfo
