圆月活动
This commit is contained in:
parent
37f93d1cd1
commit
8c1082793e
@ -150,12 +150,18 @@ BIReport.ITEM_GET_TYPE = {
|
||||
ACT_FOURTEEN_DAY_TASK = "ActFourteenDayTask",
|
||||
ACT_FOURTEEN_DAY_EXCHANGE = "ActFourteenDayExchange",
|
||||
FOURTEEN_DAY_GIFT = "FourteenDayGift",
|
||||
FULL_MOON_HERO_GIFT = "FullMoonHeroGift",
|
||||
FULL_MOON_NEW_HERO_GIFT = "FullMoonNewHeroGift",
|
||||
FULL_MOON_SKIN_GIFT = "FullMoonSkinGift",
|
||||
DUNGEON_RUNE_START = "DungeonRuneStart",
|
||||
DUNGEON_RUNE_SETTLEMENT = "DungeonRuneSettlement",
|
||||
DUNGEON_RUNE_SWEEP = "DungeonRuneSweep",
|
||||
DUNGEON_RUNE_BUY_WING = "DungeonRunebuyWing",
|
||||
RUNES_QUENCHING = "RuneQuenching",
|
||||
RUNES_GIFT = "RuneGift",
|
||||
FULL_MOON_TASK = "FullMoonTask",
|
||||
FULL_MOON_TASK_PROG_REWARD = "FullMoonTaskProgReward",
|
||||
FULL_MOON_SKIN_CHALLENGE_REWARD = "FullMoonSkinChallengeReward",
|
||||
}
|
||||
|
||||
BIReport.ADS_CLICK_TYPE = {
|
||||
@ -207,6 +213,7 @@ BIReport.BATTLE_TYPE = {
|
||||
["7"] = "DungeonArmor",
|
||||
["8"] = "ActBossRush",
|
||||
["9"] = "DungeonRune",
|
||||
["10"] = "FullMoonSkin",
|
||||
}
|
||||
|
||||
BIReport.GIFT_TYPE = {
|
||||
@ -229,6 +236,9 @@ BIReport.GIFT_TYPE = {
|
||||
ACT_SUMMER = "ActSummer",
|
||||
ACT_HERO_FUND = "ActHeroFund",
|
||||
FOURTEEN_DAY_GIFT = "FourteenDayGift",
|
||||
FULL_MOON_HERO_GIFT = "FullMoonHeroGift",
|
||||
FULL_MOON_NEW_HERO_GIFT = "FullMoonNewHeroGift",
|
||||
FULL_MOON_SKIN_GIFT = "FullMoonSkinGift",
|
||||
RUNES_GIFT = "RunesGift",
|
||||
}
|
||||
|
||||
|
||||
@ -33,6 +33,7 @@ function DataManager:init()
|
||||
self:initManager("SevenDayData", "app/userdata/activity/seven_day/seven_day_data")
|
||||
self:initManager("ShopData", "app/userdata/shop/shop_data")
|
||||
self:initManager("SummonData", "app/userdata/summon/summon_data")
|
||||
self:initManager("FullMoonData", "app/userdata/activity/full_moon/full_moon_data")
|
||||
self:initManager("AIHelperData", "app/userdata/game_setting/ai_helper_data")
|
||||
self:initManager("HeroFundData", "app/userdata/activity/hero_fund/hero_fund_data")
|
||||
self:initManager("ActBossRushData", "app/userdata/activity/act_boss_rush/act_boss_rush_data")
|
||||
@ -120,6 +121,7 @@ function DataManager:clear()
|
||||
self.SevenDayData:clear()
|
||||
self.ShopData:clear()
|
||||
self.SummonData:clear()
|
||||
self.FullMoonData:clear()
|
||||
-- 任务数据最后清理
|
||||
self.TaskData:clear()
|
||||
self.AIHelperData:clear()
|
||||
@ -485,14 +487,22 @@ DataManager.activityOpenFunc = {
|
||||
[2] = function(params)
|
||||
ModuleManager.ActBossRushManager:reqActData()
|
||||
DataManager.ActBossRushData:setActivityInfo(params)
|
||||
end
|
||||
end,
|
||||
[4] = function(params)
|
||||
DataManager.FullMoonData:setActStatus(params)
|
||||
ModuleManager.FullMoonManager:reqActData()
|
||||
end,
|
||||
}
|
||||
|
||||
DataManager.waitOpenActivity = {
|
||||
[2] = function(params)
|
||||
DataManager.ActBossRushData:init({activity_id = params.id}) -- 默认初始化
|
||||
DataManager.ActBossRushData:setActivityInfo(params)
|
||||
end
|
||||
end,
|
||||
[4] = function(params)
|
||||
DataManager.FullMoonData:setActStatus(params)
|
||||
ModuleManager.FullMoonManager:initTimer()
|
||||
end,
|
||||
}
|
||||
|
||||
return DataManager
|
||||
@ -60,6 +60,7 @@ EventManager.CUSTOM_EVENT = {
|
||||
-- BORAD_TOUCH_OVER = "BORAD_TOUCH_OVER"
|
||||
DUNGEON_ARMOR_TO_TARGET_ID = "DUNGEON_ARMOR_TO_TARGET_ID",
|
||||
ACTIVITY_SUMMER_END = "ACTIVITY_SUMMER_END",
|
||||
ACTIVITY_FULL_MOON_END = "ACTIVITY_FULL_MOON_END",
|
||||
MAIN_UI_CHECK_SIDE_BAR = "MAIN_UI_CHECK_SIDE_BAR",
|
||||
FORMATION_CHANGE = "FORMATION_CHANGE",
|
||||
BATTLE_REBIRTH = "BATTLE_REBIRTH",
|
||||
|
||||
@ -77,6 +77,8 @@ local MODULE_PATHS = {
|
||||
ActBossRushManager = "app/module/activity/act_boss_rush/act_boss_rush_manager",
|
||||
-- 新手14天乐
|
||||
FourteenDayManager = "app/module/activity/fourteen_day/fourteen_day_manager",
|
||||
-- 圆月活动
|
||||
FullMoonManager = "app/module/activity/full_moon/full_moon_manager",
|
||||
-- 符文副本
|
||||
DungeonRuneManager = "app/module/dungeon_rune/dungeon_rune_manager",
|
||||
}
|
||||
|
||||
@ -27,6 +27,9 @@ PayManager.PURCHARSE_ACT_TYPE = {
|
||||
WEAPON_UPGRADE_GIFT = 15,
|
||||
ARMOR_UPGRADE_GIFT = 16,
|
||||
FOURTEEN_DAY_GIFT = 17,
|
||||
FULL_MOON_HERO_GIFT = 18,
|
||||
FULL_MOON_NEW_HERO_GIFT = 19,
|
||||
FULL_MOON_SKIN_GIFT = 20,
|
||||
RUNES_GIFT = 21,
|
||||
}
|
||||
|
||||
@ -57,6 +60,9 @@ PayManager.BI_ITEM_GET_TYPE = {
|
||||
[PayManager.PURCHARSE_ACT_TYPE.WEAPON_UPGRADE_GIFT] = BIReport.ITEM_GET_TYPE.WEAPON_GIFT,
|
||||
[PayManager.PURCHARSE_ACT_TYPE.ARMOR_UPGRADE_GIFT] = BIReport.ITEM_GET_TYPE.ARMOR_GIFT,
|
||||
[PayManager.PURCHARSE_ACT_TYPE.FOURTEEN_DAY_GIFT] = BIReport.ITEM_GET_TYPE.FOURTEEN_DAY_GIFT,
|
||||
[PayManager.PURCHARSE_ACT_TYPE.FULL_MOON_HERO_GIFT] = BIReport.ITEM_GET_TYPE.FULL_MOON_HERO_GIFT,
|
||||
[PayManager.PURCHARSE_ACT_TYPE.FULL_MOON_NEW_HERO_GIFT] = BIReport.ITEM_GET_TYPE.FULL_MOON_NEW_HERO_GIFT,
|
||||
[PayManager.PURCHARSE_ACT_TYPE.FULL_MOON_SKIN_GIFT] = BIReport.ITEM_GET_TYPE.FULL_MOON_SKIN_GIFT,
|
||||
[PayManager.PURCHARSE_ACT_TYPE.RUNES_GIFT] = BIReport.ITEM_GET_TYPE.RUNES_GIFT,
|
||||
},
|
||||
[PayManager.PURCHARSE_TYPE.ACT_GOLD_PIG] = BIReport.ITEM_GET_TYPE.GOLD_PIG,
|
||||
@ -80,10 +86,13 @@ PayManager.BI_GIFT_TYPE = {
|
||||
[PayManager.PURCHARSE_ACT_TYPE.WEAPON_GIFT] = BIReport.GIFT_TYPE.WEAPON_GIFT,
|
||||
[PayManager.PURCHARSE_ACT_TYPE.ARMOR_GIFT] = BIReport.GIFT_TYPE.ARMOR_GIFT,
|
||||
[PayManager.PURCHARSE_ACT_TYPE.ACT_SUMMER] = BIReport.GIFT_TYPE.ACT_SUMMER,
|
||||
[PayManager.PURCHARSE_ACT_TYPE.ACT_HERO_FUND] = BIReport.ITEM_GET_TYPE.ACT_HERO_FUND,
|
||||
[PayManager.PURCHARSE_ACT_TYPE.ACT_HERO_FUND] = BIReport.GIFT_TYPE.ACT_HERO_FUND,
|
||||
[PayManager.PURCHARSE_ACT_TYPE.WEAPON_UPGRADE_GIFT] = BIReport.GIFT_TYPE.WEAPON_GIFT,
|
||||
[PayManager.PURCHARSE_ACT_TYPE.ARMOR_UPGRADE_GIFT] = BIReport.GIFT_TYPE.ARMOR_GIFT,
|
||||
[PayManager.PURCHARSE_ACT_TYPE.FOURTEEN_DAY_GIFT] = BIReport.GIFT_TYPE.FOURTEEN_DAY_GIFT,
|
||||
[PayManager.PURCHARSE_ACT_TYPE.FULL_MOON_HERO_GIFT] = BIReport.GIFT_TYPE.FULL_MOON_HERO_GIFT,
|
||||
[PayManager.PURCHARSE_ACT_TYPE.FULL_MOON_NEW_HERO_GIFT] = BIReport.GIFT_TYPE.FULL_MOON_NEW_HERO_GIFT,
|
||||
[PayManager.PURCHARSE_ACT_TYPE.FULL_MOON_SKIN_GIFT] = BIReport.GIFT_TYPE.FULL_MOON_SKIN_GIFT,
|
||||
[PayManager.PURCHARSE_ACT_TYPE.RUNES_GIFT] = BIReport.GIFT_TYPE.RUNES_GIFT,
|
||||
},
|
||||
[PayManager.PURCHARSE_TYPE.ACT_GOLD_PIG] = BIReport.GIFT_TYPE.GOLD_PIG,
|
||||
|
||||
@ -5059,8 +5059,8 @@ local act_gift = {
|
||||
{
|
||||
["type"]=1,
|
||||
["type_for_nothing"]="Vw==",
|
||||
["id"]=3400101,
|
||||
["id_for_nothing"]="VQxcA2RRfg==",
|
||||
["id"]=5400401,
|
||||
["id_for_nothing"]="UwxcA2FRfg==",
|
||||
["num"]=1,
|
||||
["num_for_nothing"]="Vw=="
|
||||
}
|
||||
@ -5091,8 +5091,8 @@ local act_gift = {
|
||||
{
|
||||
["type"]=1,
|
||||
["type_for_nothing"]="Vw==",
|
||||
["id"]=5400101,
|
||||
["id_for_nothing"]="UwxcA2RRfg==",
|
||||
["id"]=4400201,
|
||||
["id_for_nothing"]="UgxcA2dRfg==",
|
||||
["num"]=1,
|
||||
["num_for_nothing"]="Vw=="
|
||||
}
|
||||
|
||||
@ -171,9 +171,21 @@ local avatar = {
|
||||
[1400101]={
|
||||
["iconId"]="16_1",
|
||||
["item"]=1400101
|
||||
},
|
||||
[2300201]={
|
||||
["iconId"]="10_1",
|
||||
["item"]=2300201
|
||||
},
|
||||
[4400201]={
|
||||
["iconId"]="20_1",
|
||||
["item"]=4400201
|
||||
},
|
||||
[5400401]={
|
||||
["iconId"]="16_1",
|
||||
["item"]=5400401
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=avatar,count=42
|
||||
data=avatar,count=45
|
||||
}
|
||||
return config
|
||||
File diff suppressed because it is too large
Load Diff
@ -1620,7 +1620,8 @@ local hero = {
|
||||
["is_show"]=1,
|
||||
["collection_point"]=5,
|
||||
["skin"]={
|
||||
44002
|
||||
44002,
|
||||
4400201
|
||||
}
|
||||
},
|
||||
[44003]={
|
||||
@ -2180,7 +2181,8 @@ local hero = {
|
||||
["item_id"]=54004,
|
||||
["collection_point"]=5,
|
||||
["skin"]={
|
||||
54004
|
||||
54004,
|
||||
5400401
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -2451,9 +2451,21 @@ local item = {
|
||||
["parameter"]=2300201,
|
||||
["qlt"]=2,
|
||||
["icon"]="2300201"
|
||||
},
|
||||
[4400201]={
|
||||
["type"]=12,
|
||||
["parameter"]=4400201,
|
||||
["qlt"]=4,
|
||||
["icon"]="4400201"
|
||||
},
|
||||
[5400401]={
|
||||
["type"]=12,
|
||||
["parameter"]=5400401,
|
||||
["qlt"]=4,
|
||||
["icon"]="5400401"
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=item,count=126
|
||||
data=item,count=128
|
||||
}
|
||||
return config
|
||||
@ -771,47 +771,39 @@ local monster_activity = {
|
||||
["monster_exp"]=15000
|
||||
},
|
||||
[10004]={
|
||||
["monster_base"]=20047,
|
||||
["monster_base"]=30043,
|
||||
["is_boss"]=1,
|
||||
["hp"]=107230000,
|
||||
["atk"]=930000,
|
||||
["hp"]=245450000,
|
||||
["atk"]=910000,
|
||||
["atk_times"]=4,
|
||||
["hurt_skill"]={
|
||||
30156,
|
||||
30157,
|
||||
30158
|
||||
50138,
|
||||
50139,
|
||||
50140,
|
||||
50141
|
||||
},
|
||||
["skill"]={
|
||||
10137,
|
||||
10138
|
||||
50142,
|
||||
50143
|
||||
},
|
||||
["passive_skill"]={
|
||||
10013,
|
||||
10010
|
||||
},
|
||||
["monster_exp"]=15000
|
||||
["monster_exp"]=350000
|
||||
},
|
||||
[10104]={
|
||||
["monster_base"]=20048,
|
||||
["monster_base"]=30044,
|
||||
["is_boss"]=1,
|
||||
["hp"]=107230000,
|
||||
["atk"]=930000,
|
||||
["hp"]=245450000,
|
||||
["atk"]=910000,
|
||||
["atk_times"]=4,
|
||||
["hurt_skill"]={
|
||||
30159,
|
||||
30160,
|
||||
30161
|
||||
50144,
|
||||
50145,
|
||||
50146,
|
||||
50147
|
||||
},
|
||||
["skill"]={
|
||||
10139,
|
||||
10140
|
||||
50148
|
||||
},
|
||||
["passive_skill"]={
|
||||
10141,
|
||||
10014,
|
||||
10009
|
||||
},
|
||||
["monster_exp"]=15000
|
||||
["monster_exp"]=350000
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
|
||||
@ -793,9 +793,19 @@ local monster_base = {
|
||||
["model_id"]="p0026",
|
||||
["body"]=2,
|
||||
["model_ui"]=1.0
|
||||
},
|
||||
[30043]={
|
||||
["model_id"]="p0043",
|
||||
["body"]=2,
|
||||
["model_ui"]=1.0
|
||||
},
|
||||
[30044]={
|
||||
["model_id"]="p0044",
|
||||
["body"]=2,
|
||||
["model_ui"]=1.0
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=monster_base,count=159
|
||||
data=monster_base,count=161
|
||||
}
|
||||
return config
|
||||
@ -30334,6 +30334,339 @@ local skill = {
|
||||
["cd"]=3,
|
||||
["cd_start"]=0
|
||||
},
|
||||
[50138]={
|
||||
["effect_type"]=1,
|
||||
["trigger"]=1,
|
||||
["effect"]={
|
||||
{
|
||||
["type"]="hurt_purple",
|
||||
["num"]=10000,
|
||||
["ratio"]=10000,
|
||||
["round"]=0
|
||||
}
|
||||
},
|
||||
["obj"]=2,
|
||||
["skill_position"]={
|
||||
1,
|
||||
25
|
||||
},
|
||||
["shake_time"]=100,
|
||||
["shake_type"]=2,
|
||||
["sound"]=5400410,
|
||||
["sound_delay"]=0.0,
|
||||
["name_act"]="attack01",
|
||||
["fx_self"]=400160
|
||||
},
|
||||
[50139]={
|
||||
["effect_type"]=1,
|
||||
["trigger"]=1,
|
||||
["effect"]={
|
||||
{
|
||||
["type"]="hurt_purple",
|
||||
["num"]=10000,
|
||||
["ratio"]=10000,
|
||||
["round"]=0
|
||||
}
|
||||
},
|
||||
["obj"]=2,
|
||||
["skill_position"]={
|
||||
1,
|
||||
25
|
||||
},
|
||||
["shake_time"]=100,
|
||||
["shake_type"]=2,
|
||||
["sound"]=5400411,
|
||||
["sound_delay"]=0.0,
|
||||
["name_act"]="attack02",
|
||||
["fx_self"]=400161
|
||||
},
|
||||
[50140]={
|
||||
["effect_type"]=1,
|
||||
["trigger"]=1,
|
||||
["effect"]={
|
||||
{
|
||||
["type"]="hurt_purple",
|
||||
["num"]=10000,
|
||||
["ratio"]=10000,
|
||||
["round"]=0
|
||||
}
|
||||
},
|
||||
["obj"]=2,
|
||||
["skill_position"]={
|
||||
1,
|
||||
25
|
||||
},
|
||||
["shake_time"]=100,
|
||||
["shake_type"]=1,
|
||||
["sound"]=5400412,
|
||||
["sound_delay"]=0.0,
|
||||
["name_act"]="attack03",
|
||||
["fx_self"]=400162
|
||||
},
|
||||
[50141]={
|
||||
["effect_type"]=1,
|
||||
["trigger"]=1,
|
||||
["effect"]={
|
||||
{
|
||||
["type"]="hurt_purple",
|
||||
["num"]=10000,
|
||||
["ratio"]=10000,
|
||||
["round"]=0
|
||||
}
|
||||
},
|
||||
["obj"]=2,
|
||||
["skill_position"]={
|
||||
1,
|
||||
25
|
||||
},
|
||||
["shake_time"]=100,
|
||||
["shake_type"]=2,
|
||||
["sound"]=5400413,
|
||||
["sound_delay"]=0.0,
|
||||
["name_act"]="attack04",
|
||||
["fx_self"]=400163
|
||||
},
|
||||
[50142]={
|
||||
["effect_type"]=1,
|
||||
["trigger"]=1,
|
||||
["effect"]={
|
||||
{
|
||||
["type"]="hurt_purple",
|
||||
["num"]=50000,
|
||||
["ratio"]=10000,
|
||||
["round"]=0
|
||||
}
|
||||
},
|
||||
["obj"]=2,
|
||||
["skill_position"]={
|
||||
1,
|
||||
25
|
||||
},
|
||||
["cd"]=3,
|
||||
["cd_start"]=0,
|
||||
["shake_time"]=200,
|
||||
["shake_type"]=6,
|
||||
["sound"]=5400420,
|
||||
["sound_delay"]=0.0,
|
||||
["name_act"]="skill01",
|
||||
["fx_self"]=400164,
|
||||
["bullet_time"]={
|
||||
1666,
|
||||
3000,
|
||||
400
|
||||
}
|
||||
},
|
||||
[50143]={
|
||||
["effect_type"]=1,
|
||||
["trigger"]=1,
|
||||
["effect"]={
|
||||
{
|
||||
["type"]="immune",
|
||||
["num"]=0,
|
||||
["ratio"]=10000,
|
||||
["round"]=2
|
||||
},
|
||||
{
|
||||
["type"]="counterattack",
|
||||
["num"]=2500,
|
||||
["ratio"]=10000,
|
||||
["round"]=2
|
||||
},
|
||||
{
|
||||
["type"]="undead",
|
||||
["num"]=0,
|
||||
["ratio"]=10000,
|
||||
["round"]=2
|
||||
}
|
||||
},
|
||||
["obj"]=1,
|
||||
["skill_position"]={
|
||||
1,
|
||||
25
|
||||
},
|
||||
["cd"]=3,
|
||||
["cd_start"]=0
|
||||
},
|
||||
[50144]={
|
||||
["effect_type"]=1,
|
||||
["trigger"]=1,
|
||||
["effect"]={
|
||||
{
|
||||
["type"]="hurt",
|
||||
["num"]=10000,
|
||||
["ratio"]=10000,
|
||||
["round"]=0
|
||||
},
|
||||
{
|
||||
["type"]="corrupt",
|
||||
["num"]=7500,
|
||||
["ratio"]=1000,
|
||||
["round"]=2
|
||||
}
|
||||
},
|
||||
["obj"]=2,
|
||||
["skill_position"]={
|
||||
2,
|
||||
0
|
||||
},
|
||||
["shake_time"]=100,
|
||||
["shake_type"]=1,
|
||||
["sound_hit"]={
|
||||
10005
|
||||
},
|
||||
["name_act"]="attack01",
|
||||
["fx_self"]=400110
|
||||
},
|
||||
[50145]={
|
||||
["effect_type"]=1,
|
||||
["trigger"]=1,
|
||||
["effect"]={
|
||||
{
|
||||
["type"]="hurt",
|
||||
["num"]=10000,
|
||||
["ratio"]=10000,
|
||||
["round"]=0
|
||||
},
|
||||
{
|
||||
["type"]="corrupt",
|
||||
["num"]=7500,
|
||||
["ratio"]=1000,
|
||||
["round"]=2
|
||||
}
|
||||
},
|
||||
["obj"]=2,
|
||||
["skill_position"]={
|
||||
2,
|
||||
0
|
||||
},
|
||||
["shake_time"]=100,
|
||||
["shake_type"]=1,
|
||||
["sound_hit"]={
|
||||
10006
|
||||
},
|
||||
["name_act"]="attack02",
|
||||
["fx_self"]=400110
|
||||
},
|
||||
[50146]={
|
||||
["effect_type"]=1,
|
||||
["trigger"]=1,
|
||||
["effect"]={
|
||||
{
|
||||
["type"]="hurt",
|
||||
["num"]=10000,
|
||||
["ratio"]=10000,
|
||||
["round"]=0
|
||||
},
|
||||
{
|
||||
["type"]="corrupt",
|
||||
["num"]=7500,
|
||||
["ratio"]=1000,
|
||||
["round"]=2
|
||||
}
|
||||
},
|
||||
["obj"]=2,
|
||||
["skill_position"]={
|
||||
2,
|
||||
0
|
||||
},
|
||||
["shake_time"]=100,
|
||||
["shake_type"]=1,
|
||||
["sound_hit"]={
|
||||
10023
|
||||
},
|
||||
["name_act"]="attack03",
|
||||
["fx_self"]=400110
|
||||
},
|
||||
[50147]={
|
||||
["effect_type"]=1,
|
||||
["trigger"]=1,
|
||||
["effect"]={
|
||||
{
|
||||
["type"]="hurt",
|
||||
["num"]=10000,
|
||||
["ratio"]=10000,
|
||||
["round"]=0
|
||||
},
|
||||
{
|
||||
["type"]="corrupt",
|
||||
["num"]=7500,
|
||||
["ratio"]=1000,
|
||||
["round"]=2
|
||||
}
|
||||
},
|
||||
["obj"]=2,
|
||||
["skill_position"]={
|
||||
2,
|
||||
0
|
||||
},
|
||||
["shake_time"]=100,
|
||||
["shake_type"]=1,
|
||||
["sound_hit"]={
|
||||
10048
|
||||
},
|
||||
["name_act"]="attack04",
|
||||
["fx_self"]=400110
|
||||
},
|
||||
[50148]={
|
||||
["effect_type"]=1,
|
||||
["trigger"]=1,
|
||||
["effect"]={
|
||||
{
|
||||
["type"]="hurt",
|
||||
["num"]=10000,
|
||||
["ratio"]=10000,
|
||||
["round"]=0
|
||||
},
|
||||
{
|
||||
["type"]="hurt",
|
||||
["num"]=10000,
|
||||
["ratio"]=10000,
|
||||
["round"]=0
|
||||
},
|
||||
{
|
||||
["type"]="hurt",
|
||||
["num"]=10000,
|
||||
["ratio"]=10000,
|
||||
["round"]=0
|
||||
},
|
||||
{
|
||||
["type"]="hurt",
|
||||
["num"]=10000,
|
||||
["ratio"]=10000,
|
||||
["round"]=0
|
||||
},
|
||||
{
|
||||
["type"]="curse",
|
||||
["num"]=10000,
|
||||
["ratio"]=10000,
|
||||
["round"]=2
|
||||
}
|
||||
},
|
||||
["obj"]=2,
|
||||
["effect_block"]={
|
||||
1,
|
||||
2,
|
||||
3,
|
||||
5
|
||||
},
|
||||
["skill_position"]={
|
||||
2,
|
||||
0
|
||||
},
|
||||
["cd"]=3,
|
||||
["cd_start"]=0,
|
||||
["shake_time"]=200,
|
||||
["shake_type"]=6,
|
||||
["sound"]=44002200,
|
||||
["sound_delay"]=0.0,
|
||||
["name_act"]="skill01",
|
||||
["fx_self"]=400111,
|
||||
["bullet_time"]={
|
||||
1600,
|
||||
3000,
|
||||
200
|
||||
}
|
||||
},
|
||||
[110001]={
|
||||
["skill_type"]=5,
|
||||
["skill_position"]={
|
||||
@ -30436,6 +30769,6 @@ local skill = {
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=skill,count=1104
|
||||
data=skill,count=1115
|
||||
}
|
||||
return config
|
||||
@ -259,6 +259,32 @@ local skin = {
|
||||
["skin_point"]=0,
|
||||
["hero_id"]=44002
|
||||
},
|
||||
[4400201]={
|
||||
["model_id"]="p0044",
|
||||
["qlt"]=4,
|
||||
["bonus"]={
|
||||
{
|
||||
["type"]="attr_crit_blue",
|
||||
["num"]=500
|
||||
},
|
||||
{
|
||||
["type"]="attr_crit_time_blue",
|
||||
["num"]=2000
|
||||
}
|
||||
},
|
||||
["icon"]="20_1",
|
||||
["got"]=1,
|
||||
["skin_point"]=15,
|
||||
["hero_id"]=44002,
|
||||
["item_id"]=4400201,
|
||||
["skill_show"]={
|
||||
44002011,
|
||||
44002012,
|
||||
44002013,
|
||||
44002014,
|
||||
44002015
|
||||
}
|
||||
},
|
||||
[44003]={
|
||||
["model_id"]="p0030",
|
||||
["qlt"]=1,
|
||||
@ -364,9 +390,35 @@ local skin = {
|
||||
["qlt"]=1,
|
||||
["skin_point"]=0,
|
||||
["hero_id"]=54004
|
||||
},
|
||||
[5400401]={
|
||||
["model_id"]="p0043",
|
||||
["qlt"]=4,
|
||||
["bonus"]={
|
||||
{
|
||||
["type"]="attr_crit_purple",
|
||||
["num"]=500
|
||||
},
|
||||
{
|
||||
["type"]="attr_crit_time_purple",
|
||||
["num"]=2000
|
||||
}
|
||||
},
|
||||
["icon"]="20_1",
|
||||
["got"]=1,
|
||||
["skin_point"]=15,
|
||||
["hero_id"]=54004,
|
||||
["item_id"]=5400401,
|
||||
["skill_show"]={
|
||||
54004011,
|
||||
54004012,
|
||||
54004013,
|
||||
54004014,
|
||||
54004015
|
||||
}
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=skin,count=41
|
||||
data=skin,count=43
|
||||
}
|
||||
return config
|
||||
@ -451,9 +451,153 @@ local skin_skill = {
|
||||
400
|
||||
},
|
||||
["fx_self_mirror"]=400004
|
||||
},
|
||||
[44002011]={
|
||||
["skill_position"]={
|
||||
2,
|
||||
0
|
||||
},
|
||||
["shake_time"]=100,
|
||||
["shake_type"]=1,
|
||||
["sound_hit"]={
|
||||
10005
|
||||
},
|
||||
["name_act"]="attack01",
|
||||
["fx_self"]=300110,
|
||||
["fx_self_mirror"]=400110
|
||||
},
|
||||
[44002012]={
|
||||
["skill_position"]={
|
||||
2,
|
||||
0
|
||||
},
|
||||
["shake_time"]=100,
|
||||
["shake_type"]=1,
|
||||
["sound_hit"]={
|
||||
10006
|
||||
},
|
||||
["name_act"]="attack02",
|
||||
["fx_self"]=300110,
|
||||
["fx_self_mirror"]=400110
|
||||
},
|
||||
[44002013]={
|
||||
["skill_position"]={
|
||||
2,
|
||||
0
|
||||
},
|
||||
["shake_time"]=100,
|
||||
["shake_type"]=1,
|
||||
["sound_hit"]={
|
||||
10023
|
||||
},
|
||||
["name_act"]="attack03",
|
||||
["fx_self"]=300110,
|
||||
["fx_self_mirror"]=400110
|
||||
},
|
||||
[44002014]={
|
||||
["skill_position"]={
|
||||
2,
|
||||
0
|
||||
},
|
||||
["shake_time"]=100,
|
||||
["shake_type"]=1,
|
||||
["sound_hit"]={
|
||||
10048
|
||||
},
|
||||
["name_act"]="attack04",
|
||||
["fx_self"]=300110,
|
||||
["fx_self_mirror"]=400110
|
||||
},
|
||||
[44002015]={
|
||||
["skill_position"]={
|
||||
2,
|
||||
0
|
||||
},
|
||||
["shake_time"]=200,
|
||||
["shake_type"]=6,
|
||||
["sound"]=44002200,
|
||||
["sound_delay"]=0.0,
|
||||
["name_act"]="skill01",
|
||||
["fx_self"]=300111,
|
||||
["bullet_time"]={
|
||||
1333,
|
||||
3000,
|
||||
400
|
||||
},
|
||||
["fx_self_mirror"]=400111
|
||||
},
|
||||
[54004011]={
|
||||
["skill_position"]={
|
||||
1,
|
||||
25
|
||||
},
|
||||
["shake_time"]=100,
|
||||
["shake_type"]=2,
|
||||
["sound"]=5400410,
|
||||
["sound_delay"]=0.0,
|
||||
["name_act"]="attack01",
|
||||
["fx_self"]=300160,
|
||||
["fx_self_mirror"]=400160
|
||||
},
|
||||
[54004012]={
|
||||
["skill_position"]={
|
||||
1,
|
||||
25
|
||||
},
|
||||
["shake_time"]=100,
|
||||
["shake_type"]=2,
|
||||
["sound"]=5400411,
|
||||
["sound_delay"]=0.0,
|
||||
["name_act"]="attack02",
|
||||
["fx_self"]=300161,
|
||||
["fx_self_mirror"]=400161
|
||||
},
|
||||
[54004013]={
|
||||
["skill_position"]={
|
||||
1,
|
||||
25
|
||||
},
|
||||
["shake_time"]=100,
|
||||
["shake_type"]=1,
|
||||
["sound"]=5400412,
|
||||
["sound_delay"]=0.0,
|
||||
["name_act"]="attack03",
|
||||
["fx_self"]=300162,
|
||||
["fx_self_mirror"]=400162
|
||||
},
|
||||
[54004014]={
|
||||
["skill_position"]={
|
||||
1,
|
||||
25
|
||||
},
|
||||
["shake_time"]=100,
|
||||
["shake_type"]=2,
|
||||
["sound"]=5400413,
|
||||
["sound_delay"]=0.0,
|
||||
["name_act"]="attack04",
|
||||
["fx_self"]=300163,
|
||||
["fx_self_mirror"]=400163
|
||||
},
|
||||
[54004015]={
|
||||
["skill_position"]={
|
||||
1,
|
||||
25
|
||||
},
|
||||
["shake_time"]=200,
|
||||
["shake_type"]=6,
|
||||
["sound"]=5400420,
|
||||
["sound_delay"]=0.0,
|
||||
["name_act"]="skill01",
|
||||
["fx_self"]=300164,
|
||||
["bullet_time"]={
|
||||
1666,
|
||||
3000,
|
||||
400
|
||||
},
|
||||
["fx_self_mirror"]=400164
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=skin_skill,count=30
|
||||
data=skin_skill,count=40
|
||||
}
|
||||
return config
|
||||
@ -124,9 +124,18 @@ local avatar = {
|
||||
},
|
||||
[1400101]={
|
||||
["desc"]="遗迹战甲"
|
||||
},
|
||||
[2300201]={
|
||||
["desc"]="黑剑士"
|
||||
},
|
||||
[4400201]={
|
||||
["desc"]="新月女王"
|
||||
},
|
||||
[5400401]={
|
||||
["desc"]="暗月武神"
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=avatar,count=42
|
||||
data=avatar,count=45
|
||||
}
|
||||
return config
|
||||
@ -474,9 +474,18 @@ local item = {
|
||||
[5400101]={
|
||||
["name"]="翩然起舞",
|
||||
["desc"]="蝴蝶的新衣装。"
|
||||
},
|
||||
[2300201]={
|
||||
["name"]="黑剑士"
|
||||
},
|
||||
[4400201]={
|
||||
["name"]="新月女王"
|
||||
},
|
||||
[5400401]={
|
||||
["name"]="暗月武神"
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=item,count=119
|
||||
data=item,count=122
|
||||
}
|
||||
return config
|
||||
@ -36,7 +36,7 @@ local skin = {
|
||||
["value"]="初始"
|
||||
},
|
||||
[2300201]={
|
||||
["value"]="Z丫"
|
||||
["value"]="黑剑士"
|
||||
},
|
||||
[24001]={
|
||||
["value"]="初始"
|
||||
@ -89,6 +89,9 @@ local skin = {
|
||||
[44002]={
|
||||
["value"]="初始"
|
||||
},
|
||||
[4400201]={
|
||||
["value"]="新月女王"
|
||||
},
|
||||
[44003]={
|
||||
["value"]="初始"
|
||||
},
|
||||
@ -121,9 +124,12 @@ local skin = {
|
||||
},
|
||||
[54004]={
|
||||
["value"]="初始"
|
||||
},
|
||||
[5400401]={
|
||||
["value"]="暗月武神"
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=skin,count=41
|
||||
data=skin,count=43
|
||||
}
|
||||
return config
|
||||
@ -124,9 +124,18 @@ local avatar = {
|
||||
},
|
||||
[1400101]={
|
||||
|
||||
},
|
||||
[2300201]={
|
||||
|
||||
},
|
||||
[4400201]={
|
||||
|
||||
},
|
||||
[5400401]={
|
||||
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=avatar,count=42
|
||||
data=avatar,count=45
|
||||
}
|
||||
return config
|
||||
@ -355,9 +355,18 @@ local item = {
|
||||
},
|
||||
[5400101]={
|
||||
|
||||
},
|
||||
[2300201]={
|
||||
|
||||
},
|
||||
[4400201]={
|
||||
|
||||
},
|
||||
[5400401]={
|
||||
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=item,count=119
|
||||
data=item,count=122
|
||||
}
|
||||
return config
|
||||
@ -88,6 +88,9 @@ local skin = {
|
||||
},
|
||||
[44002]={
|
||||
|
||||
},
|
||||
[4400201]={
|
||||
|
||||
},
|
||||
[44003]={
|
||||
|
||||
@ -121,9 +124,12 @@ local skin = {
|
||||
},
|
||||
[54004]={
|
||||
|
||||
},
|
||||
[5400401]={
|
||||
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=skin,count=41
|
||||
data=skin,count=43
|
||||
}
|
||||
return config
|
||||
@ -124,9 +124,18 @@ local avatar = {
|
||||
},
|
||||
[1400101]={
|
||||
["desc"]="Relic Armor"
|
||||
},
|
||||
[2300201]={
|
||||
|
||||
},
|
||||
[4400201]={
|
||||
|
||||
},
|
||||
[5400401]={
|
||||
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=avatar,count=42
|
||||
data=avatar,count=45
|
||||
}
|
||||
return config
|
||||
@ -470,9 +470,18 @@ local item = {
|
||||
[5400101]={
|
||||
["name"]="Graceful Dance",
|
||||
["desc"]="Butterfly's new outfit."
|
||||
},
|
||||
[2300201]={
|
||||
|
||||
},
|
||||
[4400201]={
|
||||
|
||||
},
|
||||
[5400401]={
|
||||
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=item,count=119
|
||||
data=item,count=122
|
||||
}
|
||||
return config
|
||||
@ -88,6 +88,9 @@ local skin = {
|
||||
},
|
||||
[44002]={
|
||||
["value"]="Initial"
|
||||
},
|
||||
[4400201]={
|
||||
|
||||
},
|
||||
[44003]={
|
||||
["value"]="Initial"
|
||||
@ -121,9 +124,12 @@ local skin = {
|
||||
},
|
||||
[54004]={
|
||||
["value"]="Initial"
|
||||
},
|
||||
[5400401]={
|
||||
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=skin,count=41
|
||||
data=skin,count=43
|
||||
}
|
||||
return config
|
||||
@ -124,9 +124,18 @@ local avatar = {
|
||||
},
|
||||
[1400101]={
|
||||
["desc"]="Armadura de Ruinas"
|
||||
},
|
||||
[2300201]={
|
||||
|
||||
},
|
||||
[4400201]={
|
||||
|
||||
},
|
||||
[5400401]={
|
||||
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=avatar,count=42
|
||||
data=avatar,count=45
|
||||
}
|
||||
return config
|
||||
@ -470,9 +470,18 @@ local item = {
|
||||
[5400101]={
|
||||
["name"]="Danza Elegante",
|
||||
["desc"]="Traje nuevo de Mariposa."
|
||||
},
|
||||
[2300201]={
|
||||
|
||||
},
|
||||
[4400201]={
|
||||
|
||||
},
|
||||
[5400401]={
|
||||
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=item,count=119
|
||||
data=item,count=122
|
||||
}
|
||||
return config
|
||||
@ -88,6 +88,9 @@ local skin = {
|
||||
},
|
||||
[44002]={
|
||||
["value"]="Inicial"
|
||||
},
|
||||
[4400201]={
|
||||
|
||||
},
|
||||
[44003]={
|
||||
["value"]="Inicial"
|
||||
@ -121,9 +124,12 @@ local skin = {
|
||||
},
|
||||
[54004]={
|
||||
["value"]="Inicial"
|
||||
},
|
||||
[5400401]={
|
||||
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=skin,count=41
|
||||
data=skin,count=43
|
||||
}
|
||||
return config
|
||||
@ -124,9 +124,18 @@ local avatar = {
|
||||
},
|
||||
[1400101]={
|
||||
|
||||
},
|
||||
[2300201]={
|
||||
|
||||
},
|
||||
[4400201]={
|
||||
|
||||
},
|
||||
[5400401]={
|
||||
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=avatar,count=42
|
||||
data=avatar,count=45
|
||||
}
|
||||
return config
|
||||
@ -355,9 +355,18 @@ local item = {
|
||||
},
|
||||
[5400101]={
|
||||
|
||||
},
|
||||
[2300201]={
|
||||
|
||||
},
|
||||
[4400201]={
|
||||
|
||||
},
|
||||
[5400401]={
|
||||
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=item,count=119
|
||||
data=item,count=122
|
||||
}
|
||||
return config
|
||||
@ -88,6 +88,9 @@ local skin = {
|
||||
},
|
||||
[44002]={
|
||||
|
||||
},
|
||||
[4400201]={
|
||||
|
||||
},
|
||||
[44003]={
|
||||
|
||||
@ -121,9 +124,12 @@ local skin = {
|
||||
},
|
||||
[54004]={
|
||||
|
||||
},
|
||||
[5400401]={
|
||||
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=skin,count=41
|
||||
data=skin,count=43
|
||||
}
|
||||
return config
|
||||
@ -124,9 +124,18 @@ local avatar = {
|
||||
},
|
||||
[1400101]={
|
||||
["desc"]="Armor Relik"
|
||||
},
|
||||
[2300201]={
|
||||
|
||||
},
|
||||
[4400201]={
|
||||
|
||||
},
|
||||
[5400401]={
|
||||
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=avatar,count=42
|
||||
data=avatar,count=45
|
||||
}
|
||||
return config
|
||||
@ -470,9 +470,18 @@ local item = {
|
||||
[5400101]={
|
||||
["name"]="Tarian Anggun",
|
||||
["desc"]="Outfit baru Kupu-kupu."
|
||||
},
|
||||
[2300201]={
|
||||
|
||||
},
|
||||
[4400201]={
|
||||
|
||||
},
|
||||
[5400401]={
|
||||
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=item,count=119
|
||||
data=item,count=122
|
||||
}
|
||||
return config
|
||||
@ -88,6 +88,9 @@ local skin = {
|
||||
},
|
||||
[44002]={
|
||||
["value"]="Awal"
|
||||
},
|
||||
[4400201]={
|
||||
|
||||
},
|
||||
[44003]={
|
||||
["value"]="Awal"
|
||||
@ -121,9 +124,12 @@ local skin = {
|
||||
},
|
||||
[54004]={
|
||||
["value"]="Awal"
|
||||
},
|
||||
[5400401]={
|
||||
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=skin,count=41
|
||||
data=skin,count=43
|
||||
}
|
||||
return config
|
||||
@ -124,9 +124,18 @@ local avatar = {
|
||||
},
|
||||
[1400101]={
|
||||
["desc"]="レリックアーマー"
|
||||
},
|
||||
[2300201]={
|
||||
|
||||
},
|
||||
[4400201]={
|
||||
|
||||
},
|
||||
[5400401]={
|
||||
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=avatar,count=42
|
||||
data=avatar,count=45
|
||||
}
|
||||
return config
|
||||
@ -470,9 +470,18 @@ local item = {
|
||||
[5400101]={
|
||||
["name"]="グレイスフルダンス",
|
||||
["desc"]="蝴蝶の新スキン。"
|
||||
},
|
||||
[2300201]={
|
||||
|
||||
},
|
||||
[4400201]={
|
||||
|
||||
},
|
||||
[5400401]={
|
||||
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=item,count=119
|
||||
data=item,count=122
|
||||
}
|
||||
return config
|
||||
@ -88,6 +88,9 @@ local skin = {
|
||||
},
|
||||
[44002]={
|
||||
["value"]="デフォルト"
|
||||
},
|
||||
[4400201]={
|
||||
|
||||
},
|
||||
[44003]={
|
||||
["value"]="デフォルト"
|
||||
@ -121,9 +124,12 @@ local skin = {
|
||||
},
|
||||
[54004]={
|
||||
["value"]="デフォルト"
|
||||
},
|
||||
[5400401]={
|
||||
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=skin,count=41
|
||||
data=skin,count=43
|
||||
}
|
||||
return config
|
||||
@ -124,9 +124,18 @@ local avatar = {
|
||||
},
|
||||
[1400101]={
|
||||
["desc"]="유적 갑옷"
|
||||
},
|
||||
[2300201]={
|
||||
|
||||
},
|
||||
[4400201]={
|
||||
|
||||
},
|
||||
[5400401]={
|
||||
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=avatar,count=42
|
||||
data=avatar,count=45
|
||||
}
|
||||
return config
|
||||
@ -470,9 +470,18 @@ local item = {
|
||||
[5400101]={
|
||||
["name"]="날아오르는 춤",
|
||||
["desc"]="나비의 새 옷"
|
||||
},
|
||||
[2300201]={
|
||||
|
||||
},
|
||||
[4400201]={
|
||||
|
||||
},
|
||||
[5400401]={
|
||||
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=item,count=119
|
||||
data=item,count=122
|
||||
}
|
||||
return config
|
||||
@ -88,6 +88,9 @@ local skin = {
|
||||
},
|
||||
[44002]={
|
||||
["value"]="초기"
|
||||
},
|
||||
[4400201]={
|
||||
|
||||
},
|
||||
[44003]={
|
||||
["value"]="초기"
|
||||
@ -121,9 +124,12 @@ local skin = {
|
||||
},
|
||||
[54004]={
|
||||
["value"]="초기"
|
||||
},
|
||||
[5400401]={
|
||||
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=skin,count=41
|
||||
data=skin,count=43
|
||||
}
|
||||
return config
|
||||
@ -124,9 +124,18 @@ local avatar = {
|
||||
},
|
||||
[1400101]={
|
||||
["desc"]="Armadura das Ruínas"
|
||||
},
|
||||
[2300201]={
|
||||
|
||||
},
|
||||
[4400201]={
|
||||
|
||||
},
|
||||
[5400401]={
|
||||
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=avatar,count=42
|
||||
data=avatar,count=45
|
||||
}
|
||||
return config
|
||||
@ -470,9 +470,18 @@ local item = {
|
||||
[5400101]={
|
||||
["name"]="Dança Fluida",
|
||||
["desc"]="A nova roupa da Borboleta."
|
||||
},
|
||||
[2300201]={
|
||||
|
||||
},
|
||||
[4400201]={
|
||||
|
||||
},
|
||||
[5400401]={
|
||||
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=item,count=119
|
||||
data=item,count=122
|
||||
}
|
||||
return config
|
||||
@ -88,6 +88,9 @@ local skin = {
|
||||
},
|
||||
[44002]={
|
||||
["value"]="Inicial"
|
||||
},
|
||||
[4400201]={
|
||||
|
||||
},
|
||||
[44003]={
|
||||
["value"]="Inicial"
|
||||
@ -121,9 +124,12 @@ local skin = {
|
||||
},
|
||||
[54004]={
|
||||
["value"]="Inicial"
|
||||
},
|
||||
[5400401]={
|
||||
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=skin,count=41
|
||||
data=skin,count=43
|
||||
}
|
||||
return config
|
||||
@ -124,9 +124,18 @@ local avatar = {
|
||||
},
|
||||
[1400101]={
|
||||
|
||||
},
|
||||
[2300201]={
|
||||
|
||||
},
|
||||
[4400201]={
|
||||
|
||||
},
|
||||
[5400401]={
|
||||
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=avatar,count=42
|
||||
data=avatar,count=45
|
||||
}
|
||||
return config
|
||||
@ -355,9 +355,18 @@ local item = {
|
||||
},
|
||||
[5400101]={
|
||||
|
||||
},
|
||||
[2300201]={
|
||||
|
||||
},
|
||||
[4400201]={
|
||||
|
||||
},
|
||||
[5400401]={
|
||||
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=item,count=119
|
||||
data=item,count=122
|
||||
}
|
||||
return config
|
||||
@ -88,6 +88,9 @@ local skin = {
|
||||
},
|
||||
[44002]={
|
||||
|
||||
},
|
||||
[4400201]={
|
||||
|
||||
},
|
||||
[44003]={
|
||||
|
||||
@ -121,9 +124,12 @@ local skin = {
|
||||
},
|
||||
[54004]={
|
||||
|
||||
},
|
||||
[5400401]={
|
||||
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=skin,count=41
|
||||
data=skin,count=43
|
||||
}
|
||||
return config
|
||||
@ -124,9 +124,18 @@ local avatar = {
|
||||
},
|
||||
[1400101]={
|
||||
["desc"]="เกราะรบซาก"
|
||||
},
|
||||
[2300201]={
|
||||
|
||||
},
|
||||
[4400201]={
|
||||
|
||||
},
|
||||
[5400401]={
|
||||
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=avatar,count=42
|
||||
data=avatar,count=45
|
||||
}
|
||||
return config
|
||||
@ -470,9 +470,18 @@ local item = {
|
||||
[5400101]={
|
||||
["name"]="เยื้องกรายเต้นรำ",
|
||||
["desc"]="ชุดใหม่ของผีเสื้อ"
|
||||
},
|
||||
[2300201]={
|
||||
|
||||
},
|
||||
[4400201]={
|
||||
|
||||
},
|
||||
[5400401]={
|
||||
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=item,count=119
|
||||
data=item,count=122
|
||||
}
|
||||
return config
|
||||
@ -88,6 +88,9 @@ local skin = {
|
||||
},
|
||||
[44002]={
|
||||
["value"]="เริ่มต้น"
|
||||
},
|
||||
[4400201]={
|
||||
|
||||
},
|
||||
[44003]={
|
||||
["value"]="เริ่มต้น"
|
||||
@ -121,9 +124,12 @@ local skin = {
|
||||
},
|
||||
[54004]={
|
||||
["value"]="เริ่มต้น"
|
||||
},
|
||||
[5400401]={
|
||||
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=skin,count=41
|
||||
data=skin,count=43
|
||||
}
|
||||
return config
|
||||
@ -124,9 +124,18 @@ local avatar = {
|
||||
},
|
||||
[1400101]={
|
||||
["desc"]="Giáp Di Tích"
|
||||
},
|
||||
[2300201]={
|
||||
|
||||
},
|
||||
[4400201]={
|
||||
|
||||
},
|
||||
[5400401]={
|
||||
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=avatar,count=42
|
||||
data=avatar,count=45
|
||||
}
|
||||
return config
|
||||
@ -470,9 +470,18 @@ local item = {
|
||||
[5400101]={
|
||||
["name"]="Nhảy Múa Nhanh Nhẹn",
|
||||
["desc"]="Quần áo mới của Bươm Bướm."
|
||||
},
|
||||
[2300201]={
|
||||
|
||||
},
|
||||
[4400201]={
|
||||
|
||||
},
|
||||
[5400401]={
|
||||
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=item,count=119
|
||||
data=item,count=122
|
||||
}
|
||||
return config
|
||||
@ -88,6 +88,9 @@ local skin = {
|
||||
},
|
||||
[44002]={
|
||||
["value"]="Ban Đầu"
|
||||
},
|
||||
[4400201]={
|
||||
|
||||
},
|
||||
[44003]={
|
||||
["value"]="Ban Đầu"
|
||||
@ -121,9 +124,12 @@ local skin = {
|
||||
},
|
||||
[54004]={
|
||||
["value"]="Ban Đầu"
|
||||
},
|
||||
[5400401]={
|
||||
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=skin,count=41
|
||||
data=skin,count=43
|
||||
}
|
||||
return config
|
||||
@ -124,9 +124,18 @@ local avatar = {
|
||||
},
|
||||
[1400101]={
|
||||
["desc"]="遺跡戰甲"
|
||||
},
|
||||
[2300201]={
|
||||
|
||||
},
|
||||
[4400201]={
|
||||
|
||||
},
|
||||
[5400401]={
|
||||
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=avatar,count=42
|
||||
data=avatar,count=45
|
||||
}
|
||||
return config
|
||||
@ -470,9 +470,18 @@ local item = {
|
||||
[5400101]={
|
||||
["name"]="翩然起舞",
|
||||
["desc"]="蝴蝶的新服裝。"
|
||||
},
|
||||
[2300201]={
|
||||
|
||||
},
|
||||
[4400201]={
|
||||
|
||||
},
|
||||
[5400401]={
|
||||
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=item,count=119
|
||||
data=item,count=122
|
||||
}
|
||||
return config
|
||||
@ -88,6 +88,9 @@ local skin = {
|
||||
},
|
||||
[44002]={
|
||||
["value"]="初始"
|
||||
},
|
||||
[4400201]={
|
||||
|
||||
},
|
||||
[44003]={
|
||||
["value"]="初始"
|
||||
@ -121,9 +124,12 @@ local skin = {
|
||||
},
|
||||
[54004]={
|
||||
["value"]="初始"
|
||||
},
|
||||
[5400401]={
|
||||
|
||||
}
|
||||
}
|
||||
local config = {
|
||||
data=skin,count=41
|
||||
data=skin,count=43
|
||||
}
|
||||
return config
|
||||
@ -23,6 +23,7 @@ local CONST_PATHS = {
|
||||
ActivityConst = "app/module/activity/activity_const",
|
||||
FourteenDayConst = "app/module/activity/fourteen_day/fourteen_day_const",
|
||||
DungeonRuneConst = "app/module/dungeon_rune/dungeon_rune_const",
|
||||
FullMoonConst = "app/module/activity/full_moon/full_moon_const",
|
||||
}
|
||||
|
||||
if EDITOR_MODE then
|
||||
|
||||
@ -460,6 +460,37 @@ function GFunc.getAttrName(key)
|
||||
return I18N:getText("attr", key, "name")
|
||||
end
|
||||
|
||||
-- 获取任务icon
|
||||
function GFunc.getTaskIcon(taskType, taskTarget)
|
||||
if taskType == GConst.TaskConst.TASK_TYPE.X_ARENA_GRADING then
|
||||
local name = DataManager.ArenaData:getGradingIconName(DataManager.ArenaData:getGradingIdFromScore(taskTarget))
|
||||
if name == "arena_dan_1" then
|
||||
return "13"
|
||||
elseif name == "arena_dan_2" then
|
||||
return "14"
|
||||
elseif name == "arena_dan_3" then
|
||||
return "12"
|
||||
end
|
||||
else
|
||||
return ConfigManager:getConfig("task_type")[taskType].icon
|
||||
end
|
||||
end
|
||||
|
||||
-- 获取任务描述
|
||||
function GFunc.getTaskDesc(taskType, taskTarget)
|
||||
if taskType == GConst.TaskConst.TASK_TYPE.X_ARENA_GRADING then
|
||||
-- 段位显示文本
|
||||
local grading = DataManager.ArenaData:getGradingName(DataManager.ArenaData:getGradingIdFromScore(taskTarget))
|
||||
return I18N:getText("task_type", taskType, "desc", grading)
|
||||
elseif taskType == GConst.TaskConst.TASK_TYPE.X_DUNGEON_ARMOR then
|
||||
-- 防具副本显示章节和关卡
|
||||
local cfg = DataManager.DungeonData:getDungeonDataByType(ModuleManager.MODULE_KEY.DUNGEON_ARMOR):getConfig(taskTarget)
|
||||
return I18N:getText("task_type", taskType, "desc", cfg.chapter, cfg.stage)
|
||||
else
|
||||
return I18N:getText("task_type", taskType, "desc", taskTarget)
|
||||
end
|
||||
end
|
||||
|
||||
function GFunc.getTimeStrWithMS(time)
|
||||
local m = math.floor(time/60)
|
||||
local s = time%60
|
||||
|
||||
8
lua/app/module/activity/full_moon.meta
Normal file
8
lua/app/module/activity/full_moon.meta
Normal file
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 0ee2abea36076ae4d8463dff225a1234
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
28
lua/app/module/activity/full_moon/full_moon_const.lua
Normal file
28
lua/app/module/activity/full_moon/full_moon_const.lua
Normal file
@ -0,0 +1,28 @@
|
||||
local FullMoonConst = {}
|
||||
|
||||
-- 活动id
|
||||
FullMoonConst.ACT_ID = 406
|
||||
|
||||
|
||||
FullMoonConst.ACT_DAYS = 10
|
||||
|
||||
-- 英雄自选礼包分页显示个数
|
||||
FullMoonConst.HERO_GIFT_SHOW_STEP = {
|
||||
4,4,5
|
||||
}
|
||||
|
||||
-- 界面
|
||||
FullMoonConst.PANEL_TYPE = {
|
||||
TASK = 1,
|
||||
CHOOSE_HERO = 2,
|
||||
NEW_HERO = 3,
|
||||
SKIN = 4,
|
||||
}
|
||||
|
||||
FullMoonConst.SKIN_CHALLENGE_ID_1 = 1
|
||||
FullMoonConst.SKIN_CHALLENGE_ID_2 = 2
|
||||
|
||||
FullMoonConst.SKIN_GIFT_ID_1 = 200102
|
||||
FullMoonConst.SKIN_GIFT_ID_2 = 200202
|
||||
|
||||
return FullMoonConst
|
||||
10
lua/app/module/activity/full_moon/full_moon_const.lua.meta
Normal file
10
lua/app/module/activity/full_moon/full_moon_const.lua.meta
Normal file
@ -0,0 +1,10 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 2ce3abbd5316c744c9ea4254adf1a947
|
||||
ScriptedImporter:
|
||||
internalIDToNameTable: []
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
script: {fileID: 11500000, guid: 3b8b241bab4a4ac9a22fcce9c64f1242, type: 3}
|
||||
102
lua/app/module/activity/full_moon/full_moon_manager.lua
Normal file
102
lua/app/module/activity/full_moon/full_moon_manager.lua
Normal file
@ -0,0 +1,102 @@
|
||||
local FullMoonManager = class("FullMoonManager", BaseModule)
|
||||
|
||||
function FullMoonManager:showActMainUI(panelType)
|
||||
UIManager:showUI("app/ui/activity/full_moon/full_moon_ui", panelType)
|
||||
end
|
||||
|
||||
-- 初始化计时器
|
||||
function FullMoonManager:initTimer()
|
||||
self:unscheduleGlobal(self.actSid)
|
||||
|
||||
if DataManager.FullMoonData:isOpenTime() then
|
||||
Logger.logHighlight("圆月活动结束倒计时:"..DataManager.FullMoonData:getEndRemainTime())
|
||||
self.actSid = self:performWithDelayGlobal(function()
|
||||
Logger.logHighlight("圆月活动结束")
|
||||
EventManager:dispatchEvent(EventManager.CUSTOM_EVENT.ACTIVITY_FULL_MOON_END)
|
||||
end, DataManager.FullMoonData:getEndRemainTime())
|
||||
elseif DataManager.FullMoonData:getStartRemainTime() > 0 then
|
||||
Logger.logHighlight("圆月活动开始倒计时:"..DataManager.FullMoonData:getStartRemainTime())
|
||||
self.actSid = self:performWithDelayGlobal(function()
|
||||
Logger.logHighlight("圆月活动开始")
|
||||
self:reqActData()
|
||||
end, DataManager.FullMoonData:getStartRemainTime())
|
||||
end
|
||||
end
|
||||
|
||||
-- 请求活动数据
|
||||
function FullMoonManager:reqActData()
|
||||
if not DataManager.FullMoonData:isOpen() then
|
||||
return
|
||||
end
|
||||
self:sendMessage(ProtoMsgType.FromMsgEnum.FullMoonInfoReq, {}, {}, self.rspActData, nil)
|
||||
end
|
||||
|
||||
function FullMoonManager:rspActData(result)
|
||||
if result.err_code == GConst.ERROR_STR.SUCCESS then
|
||||
DataManager.FullMoonData:onGetActData(result.full_moon)
|
||||
end
|
||||
end
|
||||
|
||||
-- 请求任务奖励
|
||||
function FullMoonManager:reqTaskReward(id)
|
||||
self:sendMessage(ProtoMsgType.FromMsgEnum.FullMoonTaskClaimReq, {id = id}, {}, self.rspTaskReward, BIReport.ITEM_GET_TYPE.FULL_MOON_TASK)
|
||||
end
|
||||
|
||||
function FullMoonManager:rspTaskReward(result)
|
||||
if result.err_code == GConst.ERROR_STR.SUCCESS then
|
||||
DataManager.FullMoonData:onReceivedTaskReward(result.reqData.id, result.finished)
|
||||
GFunc.showRewardBox(result.rewards)
|
||||
end
|
||||
end
|
||||
|
||||
-- 请求任务进度奖励
|
||||
function FullMoonManager:reqTaskProgressReward(id)
|
||||
self:sendMessage(ProtoMsgType.FromMsgEnum.FullMoonRewardClaimReq, {id = id}, {}, self.rspTaskProgressReward, BIReport.ITEM_GET_TYPE.FULL_MOON_TASK_PROG_REWARD)
|
||||
end
|
||||
|
||||
function FullMoonManager:rspTaskProgressReward(result)
|
||||
if result.err_code == GConst.ERROR_STR.SUCCESS then
|
||||
DataManager.FullMoonData:onReceivedTaskProgressReward(result.reqData.id)
|
||||
GFunc.showRewardBox(result.rewards)
|
||||
end
|
||||
end
|
||||
|
||||
-- 自选礼包选择
|
||||
function FullMoonManager:reqGiftChooseHero(index)
|
||||
self:sendMessage(ProtoMsgType.FromMsgEnum.FullMoonCustomGiftChooseReq, {index = index}, {}, self.rspGiftChooseHero, nil)
|
||||
end
|
||||
|
||||
function FullMoonManager:rspGiftChooseHero(result)
|
||||
if result.err_code == GConst.ERROR_STR.SUCCESS then
|
||||
DataManager.FullMoonData:onChooseHeroSuccess(result.reqData.index)
|
||||
end
|
||||
end
|
||||
|
||||
-- 皮肤挑战
|
||||
function FullMoonManager:skinChallenge(id)
|
||||
DataManager.FullMoonData:setCurSkinChallengeId(id)
|
||||
ModuleManager.BattleManager:playBattle(GConst.BattleConst.BATTLE_TYPE.FULL_MOON_SKIN, nil, function()
|
||||
UIManager:closeAllUI()
|
||||
ModuleManager.MaincityManager:showMainCityUI()
|
||||
self:showActMainUI(GConst.FullMoonConst.PANEL_TYPE.SKIN)
|
||||
end)
|
||||
end
|
||||
|
||||
-- 请求皮肤关卡挑战奖励
|
||||
function FullMoonManager:reqChapterSkinClaim(id, combatReport)
|
||||
if DataManager.FullMoonData:isReceivedSkinFirstChallengeReward(id) then
|
||||
ModuleManager.BattleManager:showBattleResultUI(GConst.BattleConst.BATTLE_TYPE.FULL_MOON_SKIN, {}, combatReport or {}, nil, nil, true)
|
||||
return
|
||||
end
|
||||
|
||||
self:sendMessage(ProtoMsgType.FromMsgEnum.FullMoonChapterSkinClaimReq, {id = id, combatReport = combatReport}, {}, self.rspChapterSkinClaim, BIReport.ITEM_GET_TYPE.FULL_MOON_SKIN_CHALLENGE_REWARD)
|
||||
end
|
||||
|
||||
function FullMoonManager:rspChapterSkinClaim(result)
|
||||
if result.err_code == GConst.ERROR_STR.SUCCESS then
|
||||
DataManager.FullMoonData:onReceivedSkinChallengeReward(result.reqData.id)
|
||||
ModuleManager.BattleManager:showBattleResultUI(GConst.BattleConst.BATTLE_TYPE.FULL_MOON_SKIN, result.rewards, result.reqData and result.reqData.combatReport or {}, nil, nil, true)
|
||||
end
|
||||
end
|
||||
|
||||
return FullMoonManager
|
||||
10
lua/app/module/activity/full_moon/full_moon_manager.lua.meta
Normal file
10
lua/app/module/activity/full_moon/full_moon_manager.lua.meta
Normal file
@ -0,0 +1,10 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 5b71325bf902494459246e0b6b8b0799
|
||||
ScriptedImporter:
|
||||
internalIDToNameTable: []
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
script: {fileID: 11500000, guid: 3b8b241bab4a4ac9a22fcce9c64f1242, type: 3}
|
||||
@ -91,6 +91,7 @@ BattleConst.BATTLE_TYPE = {
|
||||
DUNGEON_ARMOR = "7",
|
||||
ACT_BOSS_RUSH = "8",
|
||||
DUNGEON_RUNE = "9",
|
||||
FULL_MOON_SKIN = "10",
|
||||
}
|
||||
|
||||
BattleConst.IS_PVP_BATTLE = {
|
||||
|
||||
@ -16,6 +16,7 @@ local BATTLE_CONTROLLER = {
|
||||
[BattleConst.BATTLE_TYPE.DUNGEON_ARMOR] = "app/module/battle/controller/battle_controller_dungeon_armor",
|
||||
[BattleConst.BATTLE_TYPE.ACT_BOSS_RUSH] = "app/module/battle/controller/battle_controller_boss_rush",
|
||||
[BattleConst.BATTLE_TYPE.DUNGEON_RUNE] = "app/module/battle/controller/battle_controller_dungeon_rune",
|
||||
[BattleConst.BATTLE_TYPE.FULL_MOON_SKIN] = "app/module/battle/controller/battle_controller_full_moon_skin",
|
||||
}
|
||||
|
||||
function BattleManager:showPauseUI(battleType, battleController)
|
||||
|
||||
@ -0,0 +1,67 @@
|
||||
local BattleController = require "app/module/battle/controller/battle_controller"
|
||||
local BattleControllerFullMoonSkin = class("BattleControllerFullMoonSkin", BattleController)
|
||||
|
||||
function BattleControllerFullMoonSkin:getBoardConfig()
|
||||
return ConfigManager:getConfig("chapter_board_dungeon_shards")
|
||||
end
|
||||
|
||||
function BattleControllerFullMoonSkin:getChapterConfig()
|
||||
return ConfigManager:getConfig("chapter_new_skin_fight")
|
||||
end
|
||||
|
||||
function BattleControllerFullMoonSkin:getChapterId()
|
||||
return DataManager.FullMoonData:getCurSkinChallengeId()
|
||||
end
|
||||
|
||||
function BattleControllerFullMoonSkin:controllBattleEnd()
|
||||
self.combatReport = {
|
||||
battleType = GConst.BattleConst.BATTLE_TYPE.FULL_MOON_SKIN,
|
||||
wave = self:getWaveIndex(),
|
||||
victory = self.victory,
|
||||
}
|
||||
local atkReport = {}
|
||||
local teamEntity = self.battleData:getAtkTeam()
|
||||
local members = teamEntity:getAllMembers()
|
||||
local totalDamage = 0
|
||||
for k, v in pairs(members) do
|
||||
local report = {
|
||||
heroId = v:getId(),
|
||||
dmg = v:getDamageCount(),
|
||||
}
|
||||
totalDamage = totalDamage + v:getDamageCount()
|
||||
table.insert(atkReport, report)
|
||||
end
|
||||
self.combatReport.atkReport = atkReport
|
||||
if self.victory then
|
||||
ModuleManager.FullMoonManager:reqChapterSkinClaim(self.chapterId, self.combatReport, totalDamage)
|
||||
end
|
||||
end
|
||||
|
||||
function BattleControllerFullMoonSkin:postWaveOver(atkDead, isQuit)
|
||||
local deathType = BIReport.FIGHT_DEATH_TYPE.SURVIVE
|
||||
local waveEndType = BIReport.FIGHT_WAVE_END_TYPE.WIN
|
||||
if atkDead then
|
||||
if self.isBossWave then
|
||||
deathType = BIReport.FIGHT_DEATH_TYPE.BOSS_FAIL
|
||||
else
|
||||
deathType = BIReport.FIGHT_DEATH_TYPE.NORMAL_FAIL
|
||||
end
|
||||
waveEndType = BIReport.FIGHT_WAVE_END_TYPE.FAIL
|
||||
end
|
||||
|
||||
if isQuit then
|
||||
waveEndType = BIReport.FIGHT_WAVE_END_TYPE.QUIT
|
||||
end
|
||||
|
||||
local duration = self.waveDurationTime
|
||||
local totalTime = self.totalDurationTime
|
||||
local isFianlStep = self:getWaveIndex() >= self.maxWaveIndex
|
||||
|
||||
BIReport:postFightEnd(GConst.BattleConst.BATTLE_TYPE.FULL_MOON_SKIN, self.battleData, self.chapterId, self:getWaveIndex(), duration, totalTime, self.eliminateCount, self.eliminateTotalCount, waveEndType, deathType, 0, true, isFianlStep, self.maxLinkCount)
|
||||
end
|
||||
|
||||
function BattleControllerFullMoonSkin:postFightStart()
|
||||
BIReport:postFightBegin(GConst.BattleConst.BATTLE_TYPE.FULL_MOON_SKIN, self:getWaveIndex(), self.chapterId, 0, 0)
|
||||
end
|
||||
|
||||
return BattleControllerFullMoonSkin
|
||||
@ -0,0 +1,10 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 4d3f99278cc5ab44e81190f7b9819a0b
|
||||
ScriptedImporter:
|
||||
internalIDToNameTable: []
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
script: {fileID: 11500000, guid: 3b8b241bab4a4ac9a22fcce9c64f1242, type: 3}
|
||||
@ -20,6 +20,7 @@ ItemConst.ITEM_ID_FOURTEEN_DAY_EXCHANGE = 51
|
||||
ItemConst.ITEM_ID_GLOD_WING = 49
|
||||
ItemConst.ITEM_ID_SLIVER_WING = 50
|
||||
ItemConst.ITEM_ID_RUNES = 55
|
||||
ItemConst.ITEM_ID_FULL_MOON = 56
|
||||
|
||||
ItemConst.ITEM_TYPE = {
|
||||
RES = 1,
|
||||
|
||||
@ -35,6 +35,7 @@ MainCityConst.LEFT_SIDE_BARS = {
|
||||
"app/ui/main_city/cell/side_bar_hero_fund_cell",
|
||||
"app/ui/main_city/cell/side_bar_seven_days_cell",
|
||||
"app/ui/main_city/cell/side_bar_activity_cell",
|
||||
"app/ui/main_city/cell/side_bar_full_moon_cell",
|
||||
-- gm放最后一个
|
||||
"app/ui/main_city/cell/side_bar_gm_cell"
|
||||
}
|
||||
|
||||
@ -31,6 +31,12 @@ function RunesManager:rspQuenching(result)
|
||||
self.isReqQuenching = false
|
||||
if result.err_code == GConst.ERROR_STR.SUCCESS then
|
||||
DataManager.RunesData:onQuenchingSuccess(result.level, result.exp, result.reqData.hero_id, result.hero_girds.grids)
|
||||
|
||||
if result.auto_count and result.auto_count > 0 then
|
||||
ModuleManager.TaskManager:addTaskProgress(GConst.TaskConst.TASK_TYPE.X_RUNES_QUENCHING, result.auto_count)
|
||||
else
|
||||
ModuleManager.TaskManager:addTaskProgress(GConst.TaskConst.TASK_TYPE.X_RUNES_QUENCHING, 1)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
@ -40,6 +40,9 @@ TaskConst.TASK_TYPE = {
|
||||
X_OPEN_CHAPTER_BOX = 37, -- 开启主线宝箱x个
|
||||
X_UPGRADE_WEAPON = 38, -- 武器升级x次
|
||||
X_UPGRADE_ARMOR = 39, -- 防具升级x次
|
||||
X_BUY_ANYONE = 40, -- 任意购买行为x次
|
||||
X_RUNES_GETED_MATERIALS = 41, -- 获得符文材料x个
|
||||
X_RUNES_QUENCHING = 42, -- 符文锻造x次
|
||||
}
|
||||
|
||||
return TaskConst
|
||||
@ -310,6 +310,18 @@ function TaskManager:xUpgradeArmor()
|
||||
self:dispatchTask(GConst.TaskConst.TASK_TYPE.X_UPGRADE_ARMOR, 1)
|
||||
end
|
||||
|
||||
function TaskManager:xBuyAnyone()
|
||||
self:dispatchTask(GConst.TaskConst.TASK_TYPE.X_BUY_ANYONE, 1)
|
||||
end
|
||||
|
||||
function TaskManager:xRunesGetedMaterials(count)
|
||||
self:dispatchTask(GConst.TaskConst.TASK_TYPE.X_RUNES_GETED_MATERIALS, count)
|
||||
end
|
||||
|
||||
function TaskManager:xRunesQuenching(count)
|
||||
self:dispatchTask(GConst.TaskConst.TASK_TYPE.X_RUNES_QUENCHING, count)
|
||||
end
|
||||
|
||||
---- 没有特殊说明,方法均返回任务增量
|
||||
TaskManager.TYPE_DEAL_FUNC = {
|
||||
[GConst.TaskConst.TASK_TYPE.X_WATCH_AD] = TaskManager.xWatchAd,
|
||||
@ -349,6 +361,9 @@ TaskManager.TYPE_DEAL_FUNC = {
|
||||
[GConst.TaskConst.TASK_TYPE.X_OPEN_CHAPTER_BOX] = TaskManager.xOpenChapterBox,
|
||||
[GConst.TaskConst.TASK_TYPE.X_UPGRADE_WEAPON] = TaskManager.xUpgradeWeapon,
|
||||
[GConst.TaskConst.TASK_TYPE.X_UPGRADE_ARMOR] = TaskManager.xUpgradeArmor,
|
||||
[GConst.TaskConst.TASK_TYPE.X_BUY_ANYONE] = TaskManager.xBuyAnyone,
|
||||
[GConst.TaskConst.TASK_TYPE.X_RUNES_GETED_MATERIALS] = TaskManager.xRunesGetedMaterials,
|
||||
[GConst.TaskConst.TASK_TYPE.X_RUNES_QUENCHING] = TaskManager.xRunesQuenching,
|
||||
}
|
||||
|
||||
function TaskManager:taskGoto(taskType)
|
||||
|
||||
@ -110,6 +110,16 @@ function TipsManager:showDescTips(desc, tarPrefabObj, alignType)
|
||||
UIManager:showUI("app/ui/tips/desc_tips", params)
|
||||
end
|
||||
|
||||
function TipsManager:showChooseRewardTips(title, desc, rewards, callback)
|
||||
local params = {
|
||||
title = title,
|
||||
desc = desc,
|
||||
rewards = rewards,
|
||||
callback = callback,
|
||||
}
|
||||
UIManager:showUI("app/ui/tips/choose_reward_tips", params)
|
||||
end
|
||||
|
||||
function TipsManager:showHeroFragmentTips(itemId)
|
||||
local params = {
|
||||
itemId = itemId
|
||||
|
||||
@ -1,5 +1,7 @@
|
||||
local ProtoMsgType = {
|
||||
FromMsgId = {
|
||||
[5949102] = "FullMoonCustomGiftChooseReq",
|
||||
[5950935] = "FullMoonCustomGiftChooseRsp",
|
||||
[109633552] = "PigLevelDownNtf",
|
||||
[109700242] = "PigLevelDownReq",
|
||||
[109702075] = "PigLevelDownRsp",
|
||||
@ -77,6 +79,8 @@ local ProtoMsgType = {
|
||||
[1433354371] = "ChapterDailyChallengeResetRsp",
|
||||
[1435947790] = "AppStorePaidReq",
|
||||
[1435949623] = "AppStorePaidRsp",
|
||||
[1459267856] = "FullMoonChapterSkinClaimReq",
|
||||
[1459269689] = "FullMoonChapterSkinClaimRsp",
|
||||
[1471116409] = "BindReq",
|
||||
[1471118242] = "BindRsp",
|
||||
[1478006910] = "BossRushBountyClaimReq",
|
||||
@ -106,6 +110,8 @@ local ProtoMsgType = {
|
||||
[1800420732] = "ChapterRuneChallengeStartReq",
|
||||
[1800422565] = "ChapterRuneChallengeStartRsp",
|
||||
[1901321540] = "PipedReq",
|
||||
[1975350605] = "ActivityPVPRankRewardsReq",
|
||||
[1975352438] = "ActivityPVPRankRewardsRsp",
|
||||
[2017336372] = "BossRushSettlementReq",
|
||||
[2017338205] = "BossRushSettlementRsp",
|
||||
[2060508030] = "ChangeAvatarFrameReq",
|
||||
@ -121,6 +127,8 @@ local ProtoMsgType = {
|
||||
[2140119902] = "ActivityPVPDecideHeroRsp",
|
||||
[2164009445] = "BossRushStartReq",
|
||||
[2164011278] = "BossRushStartRsp",
|
||||
[2194306819] = "FullMoonTaskClaimReq",
|
||||
[2194308652] = "FullMoonTaskClaimRsp",
|
||||
[2198847028] = "BossRushBoughtNtf",
|
||||
[2224825865] = "ChapterRuneChallengeSettlementReq",
|
||||
[2224827698] = "ChapterRuneChallengeSettlementRsp",
|
||||
@ -181,6 +189,8 @@ local ProtoMsgType = {
|
||||
[3038153756] = "TaskDailyRefreshRsp",
|
||||
[3039097236] = "SummerBountyClaimReq",
|
||||
[3039099069] = "SummerBountyClaimRsp",
|
||||
[3050641832] = "FullMoonInfoReq",
|
||||
[3050643665] = "FullMoonInfoRsp",
|
||||
[3058879524] = "PVPRankReq",
|
||||
[3058881357] = "PVPRankRsp",
|
||||
[3062745642] = "FundAwardReq",
|
||||
@ -262,6 +272,8 @@ local ProtoMsgType = {
|
||||
[3904150593] = "GMRsp",
|
||||
[3933875617] = "ChapterStartReq",
|
||||
[3933877450] = "ChapterStartRsp",
|
||||
[3991710133] = "FullMoonRewardClaimReq",
|
||||
[3991711966] = "FullMoonRewardClaimRsp",
|
||||
[4010728288] = "ChapterRuneBuySliverReq",
|
||||
[4010730121] = "ChapterRuneBuySliverRsp",
|
||||
[4015942008] = "RuneQuenchingReq",
|
||||
@ -288,6 +300,8 @@ local ProtoMsgType = {
|
||||
[4256335780] = "ExistRsp",
|
||||
},
|
||||
FromMsgToId = {
|
||||
FullMoonCustomGiftChooseReq = 5949102,
|
||||
FullMoonCustomGiftChooseRsp = 5950935,
|
||||
PigLevelDownNtf = 109633552,
|
||||
PigLevelDownReq = 109700242,
|
||||
PigLevelDownRsp = 109702075,
|
||||
@ -365,6 +379,8 @@ local ProtoMsgType = {
|
||||
ChapterDailyChallengeResetRsp = 1433354371,
|
||||
AppStorePaidReq = 1435947790,
|
||||
AppStorePaidRsp = 1435949623,
|
||||
FullMoonChapterSkinClaimReq = 1459267856,
|
||||
FullMoonChapterSkinClaimRsp = 1459269689,
|
||||
BindReq = 1471116409,
|
||||
BindRsp = 1471118242,
|
||||
BossRushBountyClaimReq = 1478006910,
|
||||
@ -394,6 +410,8 @@ local ProtoMsgType = {
|
||||
ChapterRuneChallengeStartReq = 1800420732,
|
||||
ChapterRuneChallengeStartRsp = 1800422565,
|
||||
PipedReq = 1901321540,
|
||||
ActivityPVPRankRewardsReq = 1975350605,
|
||||
ActivityPVPRankRewardsRsp = 1975352438,
|
||||
BossRushSettlementReq = 2017336372,
|
||||
BossRushSettlementRsp = 2017338205,
|
||||
ChangeAvatarFrameReq = 2060508030,
|
||||
@ -409,6 +427,8 @@ local ProtoMsgType = {
|
||||
ActivityPVPDecideHeroRsp = 2140119902,
|
||||
BossRushStartReq = 2164009445,
|
||||
BossRushStartRsp = 2164011278,
|
||||
FullMoonTaskClaimReq = 2194306819,
|
||||
FullMoonTaskClaimRsp = 2194308652,
|
||||
BossRushBoughtNtf = 2198847028,
|
||||
ChapterRuneChallengeSettlementReq = 2224825865,
|
||||
ChapterRuneChallengeSettlementRsp = 2224827698,
|
||||
@ -469,6 +489,8 @@ local ProtoMsgType = {
|
||||
TaskDailyRefreshRsp = 3038153756,
|
||||
SummerBountyClaimReq = 3039097236,
|
||||
SummerBountyClaimRsp = 3039099069,
|
||||
FullMoonInfoReq = 3050641832,
|
||||
FullMoonInfoRsp = 3050643665,
|
||||
PVPRankReq = 3058879524,
|
||||
PVPRankRsp = 3058881357,
|
||||
FundAwardReq = 3062745642,
|
||||
@ -550,6 +572,8 @@ local ProtoMsgType = {
|
||||
GMRsp = 3904150593,
|
||||
ChapterStartReq = 3933875617,
|
||||
ChapterStartRsp = 3933877450,
|
||||
FullMoonRewardClaimReq = 3991710133,
|
||||
FullMoonRewardClaimRsp = 3991711966,
|
||||
ChapterRuneBuySliverReq = 4010728288,
|
||||
ChapterRuneBuySliverRsp = 4010730121,
|
||||
RuneQuenchingReq = 4015942008,
|
||||
@ -576,6 +600,8 @@ local ProtoMsgType = {
|
||||
ExistRsp = 4256335780,
|
||||
},
|
||||
FromMsgEnum = {
|
||||
FullMoonCustomGiftChooseReq = "FullMoonCustomGiftChooseReq",
|
||||
FullMoonCustomGiftChooseRsp = "FullMoonCustomGiftChooseRsp",
|
||||
PigLevelDownNtf = "PigLevelDownNtf",
|
||||
PigLevelDownReq = "PigLevelDownReq",
|
||||
PigLevelDownRsp = "PigLevelDownRsp",
|
||||
@ -653,6 +679,8 @@ local ProtoMsgType = {
|
||||
ChapterDailyChallengeResetRsp = "ChapterDailyChallengeResetRsp",
|
||||
AppStorePaidReq = "AppStorePaidReq",
|
||||
AppStorePaidRsp = "AppStorePaidRsp",
|
||||
FullMoonChapterSkinClaimReq = "FullMoonChapterSkinClaimReq",
|
||||
FullMoonChapterSkinClaimRsp = "FullMoonChapterSkinClaimRsp",
|
||||
BindReq = "BindReq",
|
||||
BindRsp = "BindRsp",
|
||||
BossRushBountyClaimReq = "BossRushBountyClaimReq",
|
||||
@ -682,6 +710,8 @@ local ProtoMsgType = {
|
||||
ChapterRuneChallengeStartReq = "ChapterRuneChallengeStartReq",
|
||||
ChapterRuneChallengeStartRsp = "ChapterRuneChallengeStartRsp",
|
||||
PipedReq = "PipedReq",
|
||||
ActivityPVPRankRewardsReq = "ActivityPVPRankRewardsReq",
|
||||
ActivityPVPRankRewardsRsp = "ActivityPVPRankRewardsRsp",
|
||||
BossRushSettlementReq = "BossRushSettlementReq",
|
||||
BossRushSettlementRsp = "BossRushSettlementRsp",
|
||||
ChangeAvatarFrameReq = "ChangeAvatarFrameReq",
|
||||
@ -697,6 +727,8 @@ local ProtoMsgType = {
|
||||
ActivityPVPDecideHeroRsp = "ActivityPVPDecideHeroRsp",
|
||||
BossRushStartReq = "BossRushStartReq",
|
||||
BossRushStartRsp = "BossRushStartRsp",
|
||||
FullMoonTaskClaimReq = "FullMoonTaskClaimReq",
|
||||
FullMoonTaskClaimRsp = "FullMoonTaskClaimRsp",
|
||||
BossRushBoughtNtf = "BossRushBoughtNtf",
|
||||
ChapterRuneChallengeSettlementReq = "ChapterRuneChallengeSettlementReq",
|
||||
ChapterRuneChallengeSettlementRsp = "ChapterRuneChallengeSettlementRsp",
|
||||
@ -757,6 +789,8 @@ local ProtoMsgType = {
|
||||
TaskDailyRefreshRsp = "TaskDailyRefreshRsp",
|
||||
SummerBountyClaimReq = "SummerBountyClaimReq",
|
||||
SummerBountyClaimRsp = "SummerBountyClaimRsp",
|
||||
FullMoonInfoReq = "FullMoonInfoReq",
|
||||
FullMoonInfoRsp = "FullMoonInfoRsp",
|
||||
PVPRankReq = "PVPRankReq",
|
||||
PVPRankRsp = "PVPRankRsp",
|
||||
FundAwardReq = "FundAwardReq",
|
||||
@ -838,6 +872,8 @@ local ProtoMsgType = {
|
||||
GMRsp = "GMRsp",
|
||||
ChapterStartReq = "ChapterStartReq",
|
||||
ChapterStartRsp = "ChapterStartRsp",
|
||||
FullMoonRewardClaimReq = "FullMoonRewardClaimReq",
|
||||
FullMoonRewardClaimRsp = "FullMoonRewardClaimRsp",
|
||||
ChapterRuneBuySliverReq = "ChapterRuneBuySliverReq",
|
||||
ChapterRuneBuySliverRsp = "ChapterRuneBuySliverRsp",
|
||||
RuneQuenchingReq = "RuneQuenchingReq",
|
||||
|
||||
8
lua/app/ui/activity/full_moon.meta
Normal file
8
lua/app/ui/activity/full_moon.meta
Normal file
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 1332d53647109d0499e22a6659ce1f1e
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
8
lua/app/ui/activity/full_moon/cell.meta
Normal file
8
lua/app/ui/activity/full_moon/cell.meta
Normal file
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: dd6f0549559c9064790b07dc590f84a4
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
60
lua/app/ui/activity/full_moon/cell/full_moon_task_cell.lua
Normal file
60
lua/app/ui/activity/full_moon/cell/full_moon_task_cell.lua
Normal file
@ -0,0 +1,60 @@
|
||||
local FullMoonTaskCell = class("FullMoonTaskCell", BaseCell)
|
||||
|
||||
function FullMoonTaskCell:init()
|
||||
local uiMap = self:getUIMap()
|
||||
self.imgTaskBg = uiMap["full_moon_task_cell.img_task_bg"]
|
||||
self.imgTask = uiMap["full_moon_task_cell.img_task_bg.img_task"]
|
||||
self.txDesc = uiMap["full_moon_task_cell.tx_desc"]
|
||||
self.imgProg = uiMap["full_moon_task_cell.prog.img_prog"]:getComponent(GConst.TYPEOF_UNITY_CLASS.BF_SLIDER)
|
||||
self.txProg = uiMap["full_moon_task_cell.prog.tx_prog"]
|
||||
self.txRewardName = uiMap["full_moon_task_cell.tx_reward_name"]
|
||||
self.imgRewardIcon = uiMap["full_moon_task_cell.icon_reward"]
|
||||
self.txNum = uiMap["full_moon_task_cell.tx_num"]
|
||||
self.finish = uiMap["full_moon_task_cell.finish"]
|
||||
self.txFinish = uiMap["full_moon_task_cell.finish.bg.tx_finish"]
|
||||
|
||||
self:addClickListener(function()
|
||||
if DataManager.FullMoonData:canGetTaskReward(self.taskId) and not DataManager.FullMoonData:isReceivedTaskReward(self.taskId) then
|
||||
ModuleManager.FullMoonManager:reqTaskReward(self.taskId)
|
||||
end
|
||||
end)
|
||||
end
|
||||
|
||||
function FullMoonTaskCell:refresh(id)
|
||||
self.taskId = id
|
||||
local taskType = DataManager.FullMoonData:getTaskType(self.taskId)
|
||||
local total = DataManager.FullMoonData:getTaskTarget(self.taskId)
|
||||
local cur = DataManager.FullMoonData:getTaskProgress(self.taskId)
|
||||
local reward = DataManager.FullMoonData:getTaskReward(self.taskId)
|
||||
self.imgTask:setSprite(GConst.ATLAS_PATH.ICON_TASK, GFunc.getTaskIcon(taskType, total))
|
||||
self.txDesc:setText(GFunc.getTaskDesc(taskType, total))
|
||||
self.imgProg.value = cur / total
|
||||
self.txProg:setText(cur .. "/" .. total)
|
||||
self.txRewardName:setText(GFunc.getRewardName(reward.type, reward.id))
|
||||
self.imgRewardIcon:setSprite(GFunc.getRewardIconRes(reward.type, reward.id))
|
||||
self.txNum:setText(GFunc.getRewardNum(reward))
|
||||
self.txFinish:setText(I18N:getGlobalText(I18N.GlobalConst.STR_COMPLETED))
|
||||
|
||||
self.finish:setActive(false)
|
||||
self.baseObject:removeRedPoint()
|
||||
if DataManager.FullMoonData:canGetTaskReward(self.taskId) then
|
||||
-- 已完成
|
||||
if DataManager.FullMoonData:isReceivedTaskReward(self.taskId) then
|
||||
-- 已领取
|
||||
self.baseObject:setSprite(GConst.ATLAS_PATH.ACT_COMMON, "act_common_bg_2")
|
||||
self.imgTaskBg:setSprite(GConst.ATLAS_PATH.ACT_COMMON, "act_common_board_3")
|
||||
self.finish:setActive(true)
|
||||
else
|
||||
-- 未领取
|
||||
self.baseObject:setSprite(GConst.ATLAS_PATH.ACT_COMMON, "act_common_bg_3")
|
||||
self.imgTaskBg:setSprite(GConst.ATLAS_PATH.ACT_COMMON, "act_common_board_4")
|
||||
self.baseObject:addRedPoint(260, 70, 0.8)
|
||||
end
|
||||
else
|
||||
--未完成
|
||||
self.baseObject:setSprite(GConst.ATLAS_PATH.ACT_COMMON, "act_common_bg_2")
|
||||
self.imgTaskBg:setSprite(GConst.ATLAS_PATH.ACT_COMMON, "act_common_board_3")
|
||||
end
|
||||
end
|
||||
|
||||
return FullMoonTaskCell
|
||||
@ -0,0 +1,10 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 7f22f15dc9b4a6d4385ac1f17fd683b4
|
||||
ScriptedImporter:
|
||||
internalIDToNameTable: []
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
script: {fileID: 11500000, guid: 3b8b241bab4a4ac9a22fcce9c64f1242, type: 3}
|
||||
@ -0,0 +1,34 @@
|
||||
local FullMoonTaskProgCell = class("FullMoonTaskProgCell", BaseCell)
|
||||
|
||||
function FullMoonTaskProgCell:init()
|
||||
local uiMap = self:getUIMap()
|
||||
self.imgProg = uiMap["prog_reward.img_prog"]
|
||||
self.txProg = uiMap["prog_reward.img_prog.tx_prog"]
|
||||
self.rewardCell = uiMap["prog_reward.reward_cell"]:addLuaComponent(GConst.TYPEOF_LUA_CLASS.REWARD_CELL)
|
||||
end
|
||||
|
||||
function FullMoonTaskProgCell:refresh(id)
|
||||
local canGet = DataManager.FullMoonData:isReachTaskProgressReward(id)
|
||||
local isReceived = DataManager.FullMoonData:isReceivedTaskProgressReward(id)
|
||||
|
||||
self.txProg:setText(DataManager.FullMoonData:getTaskProgressTarget(id))
|
||||
self.rewardCell:refreshByConfig(DataManager.FullMoonData:getTaskProgressReward(id), isReceived, isReceived)
|
||||
if canGet then
|
||||
self.imgProg:setSprite(GConst.ATLAS_PATH.ACT_COMMON, "act_common_bg_7")
|
||||
if not isReceived then
|
||||
self.rewardCell.baseObject:addRedPoint(50, 50, 0.6)
|
||||
self.rewardCell:addClickListener(function()
|
||||
ModuleManager.FullMoonManager:reqTaskProgressReward(id)
|
||||
end)
|
||||
else
|
||||
self.rewardCell.baseObject:removeRedPoint()
|
||||
self.rewardCell:addClickListener(nil)
|
||||
end
|
||||
else
|
||||
self.imgProg:setSprite(GConst.ATLAS_PATH.ACT_COMMON, "act_common_bg_8")
|
||||
self.rewardCell.baseObject:removeRedPoint()
|
||||
self.rewardCell:addClickListener(nil)
|
||||
end
|
||||
end
|
||||
|
||||
return FullMoonTaskProgCell
|
||||
@ -0,0 +1,10 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 77ab55a8c675c344f86e75e0c68481dc
|
||||
ScriptedImporter:
|
||||
internalIDToNameTable: []
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
script: {fileID: 11500000, guid: 3b8b241bab4a4ac9a22fcce9c64f1242, type: 3}
|
||||
130
lua/app/ui/activity/full_moon/full_moon_choose_hero_comp.lua
Normal file
130
lua/app/ui/activity/full_moon/full_moon_choose_hero_comp.lua
Normal file
@ -0,0 +1,130 @@
|
||||
local FullMoonChooseHeroComp = class("FullMoonChooseHeroComp", LuaComponent)
|
||||
|
||||
function FullMoonChooseHeroComp:init()
|
||||
local uiMap = self:getUIMap()
|
||||
-- self.spineBanner = uiMap["choose_hero_panel.spine_banner"]
|
||||
self.txTitle = uiMap["choose_hero_panel.tx_title"]
|
||||
self.txTips = uiMap["choose_hero_panel.tx_tips"]
|
||||
self.btnBuy = uiMap["choose_hero_panel.btn_buy"]
|
||||
self.txBuy = uiMap["choose_hero_panel.btn_buy.tx_buy"]
|
||||
self.rewards = uiMap["choose_hero_panel.rewards"]:getComponent(GConst.TYPEOF_UNITY_CLASS.BF_HORIZONTAL_OR_VERTICAL_LAYOUT)
|
||||
self.rewardCells = {}
|
||||
for i = 1, 3 do
|
||||
table.insert(self.rewardCells, uiMap["choose_hero_panel.rewards.pop_reward_cell_" .. i]:addLuaComponent(GConst.TYPEOF_LUA_CLASS.POP_REWARD_CELL))
|
||||
end
|
||||
self.gifts = uiMap["choose_hero_panel.gifts"]:getComponent(GConst.TYPEOF_UNITY_CLASS.BF_HORIZONTAL_OR_VERTICAL_LAYOUT)
|
||||
self.giftItems = {}
|
||||
for i = 1, 5 do
|
||||
table.insert(self.giftItems, uiMap["choose_hero_panel.gifts.gift_" .. i])
|
||||
end
|
||||
|
||||
-- self.spineBanner:playAnim("animation", true, true)
|
||||
self.txTitle:setText(I18N:getGlobalText(I18N.GlobalConst.ACTIVITY_MOON_DESC_4))
|
||||
self.txTips:setText(I18N:getGlobalText(I18N.GlobalConst.ACTIVITY_MOON_DESC_6))
|
||||
|
||||
self.btnBuy:addClickListener(function()
|
||||
if not DataManager.FullMoonData:getChooseHeroIndex() then
|
||||
self:showChoose()
|
||||
return
|
||||
end
|
||||
PayManager:purchasePackage(self.selectGiftId, PayManager.PURCHARSE_TYPE.ACT_GIFT)
|
||||
end)
|
||||
end
|
||||
|
||||
function FullMoonChooseHeroComp:refresh()
|
||||
self.curGiftId = DataManager.FullMoonData:getCurChooseHeroGiftId()
|
||||
self.selectGiftId = self.curGiftId
|
||||
self:refreshGifts()
|
||||
end
|
||||
|
||||
-- 刷新礼包显示
|
||||
function FullMoonChooseHeroComp:refreshGifts()
|
||||
local chooseFunc = function()
|
||||
self:showChoose()
|
||||
end
|
||||
local gift = DataManager.ShopData:getActGiftConfig()[self.selectGiftId]
|
||||
|
||||
self.txTips:setActive(self.selectGiftId ~= self.curGiftId)
|
||||
self.btnBuy:setActive(self.selectGiftId == self.curGiftId)
|
||||
if not DataManager.FullMoonData:isGiftBought(self.selectGiftId) then
|
||||
self.btnBuy:setTouchEnable(true)
|
||||
self.btnBuy:setSprite(GConst.ATLAS_PATH.COMMON, "common_btn_green_1")
|
||||
self.txBuy:setText(GFunc.getFormatPrice(gift.recharge_id))
|
||||
else
|
||||
self.btnBuy:setTouchEnable(false)
|
||||
self.btnBuy:setSprite(GConst.ATLAS_PATH.COMMON, "common_btn_grey_1")
|
||||
self.txBuy:setText(I18N:getGlobalText(I18N.GlobalConst.SHOP_DESC_20))
|
||||
end
|
||||
|
||||
for index, cell in ipairs(self.rewardCells) do
|
||||
if gift.reward[index] then
|
||||
cell:setVisible(true)
|
||||
cell:refresh(gift.reward[index].id, gift.reward[index].num, true)
|
||||
elseif index == #gift.reward + 1 then
|
||||
cell:setVisible(true)
|
||||
if DataManager.FullMoonData:getChooseHeroIndex() then
|
||||
local choose = DataManager.FullMoonData:getChooseRewards(self.selectGiftId, true)[DataManager.FullMoonData:getChooseHeroIndex()]
|
||||
-- Logger.logHighlight(DataManager.FullMoonData:getChooseHeroIndex())
|
||||
cell:refresh(choose.id, choose.num, true)
|
||||
cell:refreshChoose(chooseFunc)
|
||||
else
|
||||
cell:refreshOnlyChoose(chooseFunc)
|
||||
end
|
||||
else
|
||||
cell:setVisible(false)
|
||||
end
|
||||
end
|
||||
self.rewards:RefreshLayout()
|
||||
|
||||
local ids = DataManager.FullMoonData:getCurStepChooseHeroGiftIds()
|
||||
for index, item in ipairs(self.giftItems) do
|
||||
if ids[index] then
|
||||
item:setActive(true)
|
||||
local map = item:genAllChildren()
|
||||
local imgGift = map["img_gift"]
|
||||
local imgBught = map["img_bught"]
|
||||
local imgSelect = map["img_select"]
|
||||
|
||||
if ids[index] == self.curGiftId then
|
||||
imgGift:setSprite(GConst.ATLAS_PATH.ACT_COMMON, "act_common_chest_2")
|
||||
elseif ids[index] > self.curGiftId then
|
||||
imgGift:setSprite(GConst.ATLAS_PATH.ACT_COMMON, "act_common_chest_3")
|
||||
else
|
||||
imgGift:setSprite(GConst.ATLAS_PATH.ACT_COMMON, "act_common_chest_1")
|
||||
end
|
||||
imgSelect:setActive(ids[index] == self.selectGiftId)
|
||||
imgBught:setActive(DataManager.FullMoonData:isGiftBought(ids[index]))
|
||||
item:addClickListener(function()
|
||||
self:onSelectGift(ids[index])
|
||||
end)
|
||||
else
|
||||
item:setActive(false)
|
||||
end
|
||||
end
|
||||
self.gifts:RefreshLayout()
|
||||
end
|
||||
|
||||
-- 选择礼包
|
||||
function FullMoonChooseHeroComp:onSelectGift(id)
|
||||
if id < self.curGiftId then
|
||||
-- 已购礼包不允许点击
|
||||
return
|
||||
end
|
||||
self.selectGiftId = id
|
||||
self:refreshGifts()
|
||||
end
|
||||
|
||||
-- 自选弹窗
|
||||
function FullMoonChooseHeroComp:showChoose()
|
||||
ModuleManager.TipsManager:showChooseRewardTips(
|
||||
I18N:getGlobalText(I18N.GlobalConst.ACTIVITY_MOON_DESC_7),
|
||||
I18N:getGlobalText(I18N.GlobalConst.ACTIVITY_MOON_DESC_8),
|
||||
DataManager.FullMoonData:getChooseRewards(self.selectGiftId),
|
||||
function(index)
|
||||
index = DataManager.FullMoonData:getChooseRewardsIndexByCanChooseIndex(index)
|
||||
ModuleManager.FullMoonManager:reqGiftChooseHero(index)
|
||||
end
|
||||
)
|
||||
end
|
||||
|
||||
return FullMoonChooseHeroComp
|
||||
@ -0,0 +1,10 @@
|
||||
fileFormatVersion: 2
|
||||
guid: ff32f3cd22038324e8daab0f06524093
|
||||
ScriptedImporter:
|
||||
internalIDToNameTable: []
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
script: {fileID: 11500000, guid: 3b8b241bab4a4ac9a22fcce9c64f1242, type: 3}
|
||||
100
lua/app/ui/activity/full_moon/full_moon_new_hero_comp.lua
Normal file
100
lua/app/ui/activity/full_moon/full_moon_new_hero_comp.lua
Normal file
@ -0,0 +1,100 @@
|
||||
local FullMoonNewHeroComp = class("FullMoonNewHeroComp", LuaComponent)
|
||||
|
||||
function FullMoonNewHeroComp:init()
|
||||
local uiMap = self:getUIMap()
|
||||
-- self.spineBanner = uiMap["new_hero_panel.spine_banner"]
|
||||
self.txTitle = uiMap["new_hero_panel.tx_title"]
|
||||
self.txTips = uiMap["new_hero_panel.tx_tips"]
|
||||
self.btnBuy = uiMap["new_hero_panel.btn_buy"]
|
||||
self.txBuy = uiMap["new_hero_panel.btn_buy.tx_buy"]
|
||||
self.rewards = uiMap["new_hero_panel.rewards"]:getComponent(GConst.TYPEOF_UNITY_CLASS.BF_HORIZONTAL_OR_VERTICAL_LAYOUT)
|
||||
self.rewardCells = {}
|
||||
for i = 1, 3 do
|
||||
table.insert(self.rewardCells, uiMap["new_hero_panel.rewards.pop_reward_cell_" .. i]:addLuaComponent(GConst.TYPEOF_LUA_CLASS.POP_REWARD_CELL))
|
||||
end
|
||||
self.gifts = uiMap["new_hero_panel.gifts"]:getComponent(GConst.TYPEOF_UNITY_CLASS.BF_HORIZONTAL_OR_VERTICAL_LAYOUT)
|
||||
self.giftItems = {}
|
||||
for i = 1, 5 do
|
||||
table.insert(self.giftItems, uiMap["new_hero_panel.gifts.gift_" .. i])
|
||||
end
|
||||
|
||||
-- self.spineBanner:playAnim("animation", true, true)
|
||||
self.txTitle:setText(I18N:getGlobalText(I18N.GlobalConst.ACTIVITY_MOON_DESC_5))
|
||||
self.txTips:setText(I18N:getGlobalText(I18N.GlobalConst.ACTIVITY_MOON_DESC_6))
|
||||
|
||||
self.btnBuy:addClickListener(function()
|
||||
PayManager:purchasePackage(self.selectGiftId, PayManager.PURCHARSE_TYPE.ACT_GIFT)
|
||||
end)
|
||||
end
|
||||
|
||||
function FullMoonNewHeroComp:refresh()
|
||||
self.curGiftId = DataManager.FullMoonData:getCurNewHeroGiftId()
|
||||
self.selectGiftId = self.curGiftId
|
||||
self:refreshGifts()
|
||||
end
|
||||
|
||||
-- 刷新礼包显示
|
||||
function FullMoonNewHeroComp:refreshGifts()
|
||||
local gift = DataManager.ShopData:getActGiftConfig()[self.selectGiftId]
|
||||
|
||||
self.txTips:setActive(self.selectGiftId ~= self.curGiftId)
|
||||
self.btnBuy:setActive(self.selectGiftId == self.curGiftId)
|
||||
if not DataManager.FullMoonData:isGiftBought(self.selectGiftId) then
|
||||
self.btnBuy:setTouchEnable(true)
|
||||
self.btnBuy:setSprite(GConst.ATLAS_PATH.COMMON, "common_btn_green_1")
|
||||
self.txBuy:setText(GFunc.getFormatPrice(gift.recharge_id))
|
||||
else
|
||||
self.btnBuy:setTouchEnable(false)
|
||||
self.btnBuy:setSprite(GConst.ATLAS_PATH.COMMON, "common_btn_grey_1")
|
||||
self.txBuy:setText(I18N:getGlobalText(I18N.GlobalConst.SHOP_DESC_20))
|
||||
end
|
||||
|
||||
for index, cell in ipairs(self.rewardCells) do
|
||||
if gift.reward[index] then
|
||||
cell:setVisible(true)
|
||||
cell:refresh(gift.reward[index].id, gift.reward[index].num, true)
|
||||
else
|
||||
cell:setVisible(false)
|
||||
end
|
||||
end
|
||||
self.rewards:RefreshLayout()
|
||||
|
||||
local ids = DataManager.FullMoonData:getCurStepNewHeroGiftIds()
|
||||
for index, item in ipairs(self.giftItems) do
|
||||
if ids[index] then
|
||||
item:setActive(true)
|
||||
local map = item:genAllChildren()
|
||||
local imgGift = map["img_gift"]
|
||||
local imgBught = map["img_bught"]
|
||||
local imgSelect = map["img_select"]
|
||||
|
||||
if ids[index] == self.curGiftId then
|
||||
imgGift:setSprite(GConst.ATLAS_PATH.ACT_COMMON, "act_common_chest_2")
|
||||
elseif ids[index] > self.curGiftId then
|
||||
imgGift:setSprite(GConst.ATLAS_PATH.ACT_COMMON, "act_common_chest_3")
|
||||
else
|
||||
imgGift:setSprite(GConst.ATLAS_PATH.ACT_COMMON, "act_common_chest_1")
|
||||
end
|
||||
imgSelect:setActive(ids[index] == self.selectGiftId)
|
||||
imgBught:setActive(DataManager.FullMoonData:isGiftBought(ids[index]))
|
||||
item:addClickListener(function()
|
||||
self:onSelectGift(ids[index])
|
||||
end)
|
||||
else
|
||||
item:setActive(false)
|
||||
end
|
||||
end
|
||||
self.gifts:RefreshLayout()
|
||||
end
|
||||
|
||||
-- 选择礼包
|
||||
function FullMoonNewHeroComp:onSelectGift(id)
|
||||
if id < self.curGiftId then
|
||||
-- 已购礼包不允许点击
|
||||
return
|
||||
end
|
||||
self.selectGiftId = id
|
||||
self:refreshGifts()
|
||||
end
|
||||
|
||||
return FullMoonNewHeroComp
|
||||
@ -0,0 +1,10 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 8d0203e3e0bcce8458287cbbb13b18be
|
||||
ScriptedImporter:
|
||||
internalIDToNameTable: []
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
script: {fileID: 11500000, guid: 3b8b241bab4a4ac9a22fcce9c64f1242, type: 3}
|
||||
144
lua/app/ui/activity/full_moon/full_moon_skin_comp.lua
Normal file
144
lua/app/ui/activity/full_moon/full_moon_skin_comp.lua
Normal file
@ -0,0 +1,144 @@
|
||||
local FullMoonSkinComp = class("FullMoonSkinComp", LuaComponent)
|
||||
|
||||
function FullMoonSkinComp:init()
|
||||
local uiMap = self:getUIMap()
|
||||
self.txTitle = uiMap["skin_panel.banner.title.tx_title"]
|
||||
self.txBannerDesc1 = uiMap["skin_panel.banner.content.desc1.tx_desc1"]
|
||||
self.txBannerDesc2 = uiMap["skin_panel.banner.content.desc2.tx_desc2"]
|
||||
-- 礼包1
|
||||
self.spineSkin1 = uiMap["skin_panel.skin1.spine_skin1"]
|
||||
self.txDesc1 = uiMap["skin_panel.skin1.bg_title.tx_title"]
|
||||
self.btnBuy1 = uiMap["skin_panel.skin1.btn_buy"]
|
||||
self.txBuy1 = uiMap["skin_panel.skin1.btn_buy.tx_buy"]
|
||||
self.challenge1 = uiMap["skin_panel.skin1.challenge"]
|
||||
self.challengeTag1 = uiMap["skin_panel.skin1.challenge.tag"]
|
||||
self.imgChallengeTag1 = uiMap["skin_panel.skin1.challenge.tag.content.img"]
|
||||
self.txChallengeTag1 = uiMap["skin_panel.skin1.challenge.tag.content.tx_num"]
|
||||
self.rewardCells1 = {}
|
||||
for i = 1, 3 do
|
||||
table.insert(self.rewardCells1, uiMap["skin_panel.skin1.rewards.reward_cell_" .. i]:addLuaComponent(GConst.TYPEOF_LUA_CLASS.REWARD_CELL))
|
||||
end
|
||||
-- 礼包2
|
||||
self.spineSkin2 = uiMap["skin_panel.skin2.spine_skin2"]
|
||||
self.txDesc2 = uiMap["skin_panel.skin2.bg_title.tx_title"]
|
||||
self.btnBuy2 = uiMap["skin_panel.skin2.btn_buy"]
|
||||
self.txBuy2 = uiMap["skin_panel.skin2.btn_buy.tx_buy"]
|
||||
self.challenge2 = uiMap["skin_panel.skin2.challenge"]
|
||||
self.challengeTag2 = uiMap["skin_panel.skin2.challenge.tag"]
|
||||
self.imgChallengeTag2 = uiMap["skin_panel.skin2.challenge.tag.content.img"]
|
||||
self.txChallengeTag2 = uiMap["skin_panel.skin2.challenge.tag.content.tx_num"]
|
||||
self.rewardCells2 = {}
|
||||
for i = 1, 3 do
|
||||
table.insert(self.rewardCells2, uiMap["skin_panel.skin2.rewards.reward_cell_" .. i]:addLuaComponent(GConst.TYPEOF_LUA_CLASS.REWARD_CELL))
|
||||
end
|
||||
|
||||
self.txTitle:setText(I18N:getGlobalText(I18N.GlobalConst.ACTIVITY_MOON_DESC_9))
|
||||
|
||||
self.challenge1:addClickListener(function()
|
||||
ModuleManager.FullMoonManager:skinChallenge(GConst.FullMoonConst.SKIN_CHALLENGE_ID_1)
|
||||
end)
|
||||
self.challenge2:addClickListener(function()
|
||||
ModuleManager.FullMoonManager:skinChallenge(GConst.FullMoonConst.SKIN_CHALLENGE_ID_2)
|
||||
end)
|
||||
self.btnBuy1:addClickListener(function()
|
||||
PayManager:purchasePackage(GConst.FullMoonConst.SKIN_GIFT_ID_1, PayManager.PURCHARSE_TYPE.ACT_GIFT)
|
||||
end)
|
||||
self.btnBuy2:addClickListener(function()
|
||||
PayManager:purchasePackage(GConst.FullMoonConst.SKIN_GIFT_ID_2, PayManager.PURCHARSE_TYPE.ACT_GIFT)
|
||||
end)
|
||||
LocalData:recordTodayActSummerWatchedSkin()
|
||||
end
|
||||
|
||||
function FullMoonSkinComp:refresh()
|
||||
-- 礼包1
|
||||
if not DataManager.FullMoonData:isReceivedSkinFirstChallengeReward(GConst.FullMoonConst.SKIN_CHALLENGE_ID_1) then
|
||||
self.challengeTag1:setActive(true)
|
||||
local reward = DataManager.FullMoonData:getSkinFirstChallengeReward(GConst.FullMoonConst.SKIN_CHALLENGE_ID_1)
|
||||
self.imgChallengeTag1:setSprite(GFunc.getIconRes(reward.id))
|
||||
self.txChallengeTag1:setText(reward.num)
|
||||
GFunc.centerImgAndTx(self.imgChallengeTag1, self.txChallengeTag1)
|
||||
else
|
||||
self.challengeTag1:setActive(false)
|
||||
end
|
||||
local gift1 = DataManager.ShopData:getActGiftConfig()[GConst.FullMoonConst.SKIN_GIFT_ID_1]
|
||||
local skinId1,heroId1
|
||||
for idx, reward in ipairs(gift1.reward) do
|
||||
if ConfigManager:getConfig("item")[reward.id].type == GConst.ItemConst.ITEM_TYPE.SKIN then
|
||||
skinId1 = DataManager.SkinData:getSkinIdByItemId(reward.id)
|
||||
heroId1 = DataManager.SkinData:getHeroIdBySkinId(skinId1)
|
||||
end
|
||||
end
|
||||
if skinId1 and heroId1 then
|
||||
self.spineSkin1:getSkeletonGraphic().enabled = false
|
||||
self.spineSkin1:loadAssetAsync(DataManager.SkinData:getModelId(skinId1), function()
|
||||
self.spineSkin1:getSkeletonGraphic().enabled = true
|
||||
self.spineSkin1:playAnim("idle", true, true, true)
|
||||
end, true)
|
||||
self.txBannerDesc1:setText(DataManager.HeroData:getHeroById(heroId1):getName() .. "-" .. DataManager.SkinData:getName(skinId1) .. "(" .. I18N:getGlobalText(I18N.GlobalConst.ACT_DESC_9) .. ")")
|
||||
end
|
||||
self.txDesc1:setText(I18N:getGlobalText(I18N.GlobalConst.ACTIVITY_MOON_DESC_10, DataManager.HeroData:getHeroById(heroId1):getName()))
|
||||
for index, cell in ipairs(self.rewardCells1) do
|
||||
if gift1.reward[index] then
|
||||
cell:setVisible(true)
|
||||
cell:refreshByConfig(gift1.reward[index])
|
||||
else
|
||||
cell:setVisible(false)
|
||||
end
|
||||
end
|
||||
if DataManager.ShopData:getGiftRemainBuyNum(GConst.FullMoonConst.SKIN_GIFT_ID_1) > 0 then
|
||||
self.btnBuy1:setTouchEnable(true)
|
||||
self.btnBuy1:setSprite(GConst.ATLAS_PATH.COMMON, "common_btn_green_2")
|
||||
self.txBuy1:setText(GFunc.getFormatPrice(gift1.recharge_id))
|
||||
else
|
||||
self.btnBuy1:setTouchEnable(false)
|
||||
self.btnBuy1:setSprite(GConst.ATLAS_PATH.COMMON, "common_btn_grey_2")
|
||||
self.txBuy1:setText(I18N:getGlobalText(I18N.GlobalConst.SHOP_DESC_20))
|
||||
end
|
||||
|
||||
-- 礼包2
|
||||
if not DataManager.FullMoonData:isReceivedSkinFirstChallengeReward(GConst.FullMoonConst.SKIN_CHALLENGE_ID_2) then
|
||||
self.challengeTag2:setActive(true)
|
||||
local reward = DataManager.FullMoonData:getSkinFirstChallengeReward(GConst.FullMoonConst.SKIN_CHALLENGE_ID_2)
|
||||
self.imgChallengeTag2:setSprite(GFunc.getIconRes(reward.id))
|
||||
self.txChallengeTag2:setText(reward.num)
|
||||
GFunc.centerImgAndTx(self.imgChallengeTag2, self.txChallengeTag2)
|
||||
else
|
||||
self.challengeTag2:setActive(false)
|
||||
end
|
||||
local gift2 = DataManager.ShopData:getActGiftConfig()[GConst.FullMoonConst.SKIN_GIFT_ID_2]
|
||||
local skinId2,heroId2
|
||||
for idx, reward in ipairs(gift2.reward) do
|
||||
if ConfigManager:getConfig("item")[reward.id].type == GConst.ItemConst.ITEM_TYPE.SKIN then
|
||||
skinId2 = DataManager.SkinData:getSkinIdByItemId(reward.id)
|
||||
heroId2 = DataManager.SkinData:getHeroIdBySkinId(skinId2)
|
||||
end
|
||||
end
|
||||
if skinId2 and heroId2 then
|
||||
self.spineSkin2:getSkeletonGraphic().enabled = false
|
||||
self.spineSkin2:loadAssetAsync(DataManager.SkinData:getModelId(skinId2), function()
|
||||
self.spineSkin2:getSkeletonGraphic().enabled = true
|
||||
self.spineSkin2:playAnim("idle", true, true, true)
|
||||
end, true)
|
||||
self.txBannerDesc2:setText(DataManager.HeroData:getHeroById(heroId2):getName() .. "-" .. DataManager.SkinData:getName(skinId2) .. "(" .. I18N:getGlobalText(I18N.GlobalConst.ACT_DESC_9) .. ")")
|
||||
end
|
||||
self.txDesc2:setText(I18N:getGlobalText(I18N.GlobalConst.ACTIVITY_MOON_DESC_10, DataManager.HeroData:getHeroById(heroId2):getName()))
|
||||
for index, cell in ipairs(self.rewardCells2) do
|
||||
if gift2.reward[index] then
|
||||
cell:setVisible(true)
|
||||
cell:refreshByConfig(gift2.reward[index])
|
||||
else
|
||||
cell:setVisible(false)
|
||||
end
|
||||
end
|
||||
if DataManager.ShopData:getGiftRemainBuyNum(GConst.FullMoonConst.SKIN_GIFT_ID_2) > 0 then
|
||||
self.btnBuy2:setTouchEnable(true)
|
||||
self.btnBuy2:setSprite(GConst.ATLAS_PATH.COMMON, "common_btn_green_2")
|
||||
self.txBuy2:setText(GFunc.getFormatPrice(gift2.recharge_id))
|
||||
else
|
||||
self.btnBuy2:setTouchEnable(false)
|
||||
self.btnBuy2:setSprite(GConst.ATLAS_PATH.COMMON, "common_btn_grey_2")
|
||||
self.txBuy2:setText(I18N:getGlobalText(I18N.GlobalConst.SHOP_DESC_20))
|
||||
end
|
||||
end
|
||||
|
||||
return FullMoonSkinComp
|
||||
10
lua/app/ui/activity/full_moon/full_moon_skin_comp.lua.meta
Normal file
10
lua/app/ui/activity/full_moon/full_moon_skin_comp.lua.meta
Normal file
@ -0,0 +1,10 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 2bdec32481442b648a69cea1bf0a2bc9
|
||||
ScriptedImporter:
|
||||
internalIDToNameTable: []
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
script: {fileID: 11500000, guid: 3b8b241bab4a4ac9a22fcce9c64f1242, type: 3}
|
||||
74
lua/app/ui/activity/full_moon/full_moon_task_comp.lua
Normal file
74
lua/app/ui/activity/full_moon/full_moon_task_comp.lua
Normal file
@ -0,0 +1,74 @@
|
||||
local FullMoonTaskComp = class("FullMoonTaskComp", LuaComponent)
|
||||
|
||||
function FullMoonTaskComp:init()
|
||||
local uiMap = self:getUIMap()
|
||||
self.listProg = uiMap["task_panel.prog.list_prog"]:addLuaComponent(GConst.TYPEOF_LUA_CLASS.SCROLL_RECT_BASE)
|
||||
self.content = uiMap["task_panel.prog.list_prog.viewport.content"]
|
||||
self.prog = uiMap["task_panel.prog.list_prog.viewport.content.prog"]
|
||||
self.imgProg = uiMap["task_panel.prog.list_prog.viewport.content.prog.img_prog"]:getComponent(GConst.TYPEOF_UNITY_CLASS.BF_SLIDER)
|
||||
self.listTask = uiMap["task_panel.list_task"]:addLuaComponent(GConst.TYPEOF_LUA_CLASS.SCROLL_RECT_BASE)
|
||||
self.spineSkin = uiMap["task_panel.prog.spine_skin"]
|
||||
self.imgScore = uiMap["task_panel.prog.score.img_score"]
|
||||
self.txScore = uiMap["task_panel.prog.score.tx_score"]
|
||||
self.txSkin = uiMap["task_panel.prog.skin_desc.skin.tx_skin"]
|
||||
self.txAllFinish = uiMap["task_panel.tx_all_finish"]
|
||||
|
||||
local skinId,heroId
|
||||
for id, data in pairs(ConfigManager:getConfig("activity_full_moon_reward")) do
|
||||
if ConfigManager:getConfig("item")[data.reward.id].type == GConst.ItemConst.ITEM_TYPE.SKIN then
|
||||
skinId = DataManager.SkinData:getSkinIdByItemId(data.reward.id)
|
||||
heroId = DataManager.SkinData:getHeroIdBySkinId(skinId)
|
||||
end
|
||||
end
|
||||
if heroId and skinId then
|
||||
self.txSkin:setText(DataManager.HeroData:getHeroById(heroId):getName() .. "-" .. DataManager.SkinData:getName(skinId) .. "(" .. I18N:getGlobalText(I18N.GlobalConst.ACT_DESC_9) .. ")")
|
||||
|
||||
self.spineSkin:getSkeletonGraphic().enabled = false
|
||||
self.spineSkin:loadAssetAsync(DataManager.SkinData:getModelId(skinId), function()
|
||||
self.spineSkin:getSkeletonGraphic().enabled = true
|
||||
self.spineSkin:playAnim("idle", true, true, true)
|
||||
end, true)
|
||||
end
|
||||
end
|
||||
|
||||
function FullMoonTaskComp:refresh()
|
||||
self.txScore:setText(DataManager.FullMoonData:getTaskFinishNum())
|
||||
GFunc.centerImgAndTx(self.imgScore, self.txScore)
|
||||
|
||||
-- 任务列表
|
||||
local tasks = DataManager.FullMoonData:getTaskListSort()
|
||||
if tasks then
|
||||
self.txAllFinish:setActive(false)
|
||||
self.listTask:addInitCallback(function()
|
||||
return "app/ui/activity/full_moon/cell/full_moon_task_cell"
|
||||
end)
|
||||
self.listTask:addRefreshCallback(function(index, cell)
|
||||
cell:refresh(tasks[index].id)
|
||||
end)
|
||||
self.listTask:clearCells()
|
||||
self.listTask:refillCells(#tasks)
|
||||
else
|
||||
self.txAllFinish:setActive(true)
|
||||
self.txAllFinish:setText(I18N:getGlobalText(I18N.GlobalConst.ACTIVITY_MOON_DESC_11))
|
||||
end
|
||||
|
||||
-- 任务进度奖励列表
|
||||
self.listProg:addInitCallback(function()
|
||||
return "app/ui/activity/full_moon/cell/full_moon_task_prog_cell"
|
||||
end)
|
||||
self.listProg:addRefreshCallback(function(index, cell)
|
||||
cell:refresh(DataManager.FullMoonData:getTaskProgressRewardIdByIndex(index))
|
||||
end)
|
||||
self.listProg:clearCells()
|
||||
self.listProg:refillCells(DataManager.FullMoonData:getTaskProgressRewardTotalNum())
|
||||
local idx = DataManager.FullMoonData:getCurTaskProgressRewardIndex()
|
||||
-- Logger.logHighlight(idx)
|
||||
self.listProg:moveToIndex(idx)
|
||||
|
||||
local maxIndex = DataManager.FullMoonData:getTaskProgressRewardTotalNum()
|
||||
local cellWidth = self.listProg:getCellWidth()
|
||||
self.prog:setSizeDeltaX(cellWidth * maxIndex)
|
||||
self.imgProg.value = DataManager.FullMoonData:getTaskFinishNum() / DataManager.FullMoonData:getTaskTotalNum()
|
||||
end
|
||||
|
||||
return FullMoonTaskComp
|
||||
10
lua/app/ui/activity/full_moon/full_moon_task_comp.lua.meta
Normal file
10
lua/app/ui/activity/full_moon/full_moon_task_comp.lua.meta
Normal file
@ -0,0 +1,10 @@
|
||||
fileFormatVersion: 2
|
||||
guid: c992c98a31d8ac74398f2cba0db13c33
|
||||
ScriptedImporter:
|
||||
internalIDToNameTable: []
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
script: {fileID: 11500000, guid: 3b8b241bab4a4ac9a22fcce9c64f1242, type: 3}
|
||||
232
lua/app/ui/activity/full_moon/full_moon_ui.lua
Normal file
232
lua/app/ui/activity/full_moon/full_moon_ui.lua
Normal file
@ -0,0 +1,232 @@
|
||||
local FullMoonUI = class("FullMoonUI", BaseUI)
|
||||
local COMP_TASK = "app/ui/activity/full_moon/full_moon_task_comp"
|
||||
local COMP_CHOOSE_HERO = "app/ui/activity/full_moon/full_moon_choose_hero_comp"
|
||||
local COMP_NEW_HERO = "app/ui/activity/full_moon/full_moon_new_hero_comp"
|
||||
local COMP_SKIN = "app/ui/activity/full_moon/full_moon_skin_comp"
|
||||
|
||||
function FullMoonUI:isFullScreen()
|
||||
return false
|
||||
end
|
||||
|
||||
function FullMoonUI:getPrefabPath()
|
||||
return "assets/prefabs/ui/activity/full_moon/full_moon_ui.prefab"
|
||||
end
|
||||
|
||||
function FullMoonUI:onPressBackspace()
|
||||
self:closeUI()
|
||||
end
|
||||
|
||||
function FullMoonUI:ctor(param)
|
||||
if param then
|
||||
self.panelType = param
|
||||
else
|
||||
self.panelType = GConst.FullMoonConst.PANEL_TYPE.TASK -- 默认进入任务页签
|
||||
end
|
||||
end
|
||||
|
||||
function FullMoonUI:onLoadRootComplete()
|
||||
local uiMap = self.root:genAllChildren()
|
||||
-- 通用
|
||||
self.txTitle = uiMap["full_moon_ui.img_title.tx_title"]
|
||||
self.btnClose = uiMap["full_moon_ui.common.btn_close"]
|
||||
self.txCountdown = uiMap["full_moon_ui.countdown.tx_countdown"]
|
||||
self.bg_task = uiMap["full_moon_ui.common.bg_task"]
|
||||
self.bg_gift = uiMap["full_moon_ui.common.bg_gift"]
|
||||
-- 子界面
|
||||
self.taskPanel = uiMap["full_moon_ui.task_panel"]
|
||||
self.chooseHeroPanel = uiMap["full_moon_ui.choose_hero_panel"]
|
||||
self.newHeroPanel = uiMap["full_moon_ui.new_hero_panel"]
|
||||
self.skinPanel = uiMap["full_moon_ui.skin_panel"]
|
||||
-- 任务标签
|
||||
self.btnTask = uiMap["full_moon_ui.common.btns.btn_task"]
|
||||
self.txTask1 = uiMap["full_moon_ui.common.btns.btn_task.tx_btn"]
|
||||
self.txTask2 = uiMap["full_moon_ui.common.btns.btn_task.select.tx_select"]
|
||||
self.selectTask = uiMap["full_moon_ui.common.btns.btn_task.select"]
|
||||
-- 自选英雄礼包标签
|
||||
self.btnChooseHero = uiMap["full_moon_ui.common.btns.btn_choose_hero"]
|
||||
self.txChooseHero1 = uiMap["full_moon_ui.common.btns.btn_choose_hero.tx_btn"]
|
||||
self.txChooseHero2 = uiMap["full_moon_ui.common.btns.btn_choose_hero.select.tx_select"]
|
||||
self.selectChooseHero = uiMap["full_moon_ui.common.btns.btn_choose_hero.select"]
|
||||
-- 新英雄礼包标签
|
||||
self.btnNewHero = uiMap["full_moon_ui.common.btns.btn_new_hero"]
|
||||
self.txNewHero1 = uiMap["full_moon_ui.common.btns.btn_new_hero.tx_btn"]
|
||||
self.txNewHero2 = uiMap["full_moon_ui.common.btns.btn_new_hero.select.tx_select"]
|
||||
self.selectNewHero = uiMap["full_moon_ui.common.btns.btn_new_hero.select"]
|
||||
-- 皮肤标签
|
||||
self.btnSkin = uiMap["full_moon_ui.common.btns.btn_skin"]
|
||||
self.txSkin1 = uiMap["full_moon_ui.common.btns.btn_skin.tx_btn"]
|
||||
self.txSkin2 = uiMap["full_moon_ui.common.btns.btn_skin.select.tx_select"]
|
||||
self.selectSkin = uiMap["full_moon_ui.common.btns.btn_skin.select"]
|
||||
|
||||
self.txTitle:setText(I18N:getGlobalText(I18N.GlobalConst.ACTIVITY_MOON_DESC_1))
|
||||
self.txTask1:setText(I18N:getGlobalText(I18N.GlobalConst.TASK_NAME))
|
||||
self.txTask2:setText(I18N:getGlobalText(I18N.GlobalConst.TASK_NAME))
|
||||
self.txChooseHero1:setText(I18N:getGlobalText(I18N.GlobalConst.ACTIVITY_MOON_DESC_2))
|
||||
self.txChooseHero2:setText(I18N:getGlobalText(I18N.GlobalConst.ACTIVITY_MOON_DESC_2))
|
||||
self.txNewHero1:setText(I18N:getGlobalText(I18N.GlobalConst.ACTIVITY_MOON_DESC_3))
|
||||
self.txNewHero2:setText(I18N:getGlobalText(I18N.GlobalConst.ACTIVITY_MOON_DESC_3))
|
||||
self.txSkin1:setText(I18N:getGlobalText(I18N.GlobalConst.ACT_DESC_3))
|
||||
self.txSkin2:setText(I18N:getGlobalText(I18N.GlobalConst.ACT_DESC_3))
|
||||
DataManager.FullMoonData:showActPanel()
|
||||
|
||||
self.btnTask:addClickListener(function()
|
||||
self.panelType = GConst.FullMoonConst.PANEL_TYPE.TASK
|
||||
self:onRefresh()
|
||||
end)
|
||||
self.btnChooseHero:addClickListener(function()
|
||||
self.panelType = GConst.FullMoonConst.PANEL_TYPE.CHOOSE_HERO
|
||||
self:onRefresh()
|
||||
end)
|
||||
self.btnNewHero:addClickListener(function()
|
||||
self.panelType = GConst.FullMoonConst.PANEL_TYPE.NEW_HERO
|
||||
self:onRefresh()
|
||||
end)
|
||||
self.btnSkin:addClickListener(function()
|
||||
self.panelType = GConst.FullMoonConst.PANEL_TYPE.SKIN
|
||||
self:onRefresh()
|
||||
end)
|
||||
self.btnClose:addClickListener(function()
|
||||
self:closeUI()
|
||||
end)
|
||||
self:addEventListener(EventManager.CUSTOM_EVENT.ACTIVITY_FULL_MOON_END, function()
|
||||
self:closeUI()
|
||||
end)
|
||||
self:bind(DataManager.FullMoonData, "isDirty", function()
|
||||
self:onRefresh()
|
||||
end)
|
||||
self:bind(DataManager.ShopData, "isDirty", function()
|
||||
self:onRefresh()
|
||||
end)
|
||||
end
|
||||
|
||||
function FullMoonUI:onRefresh()
|
||||
-- 倒计时
|
||||
if self.actCountdownSid then
|
||||
self.txCountdown:unscheduleGlobal(self.actCountdownSid)
|
||||
end
|
||||
self.txCountdown:setText(GFunc.getTimeStrWithHMS2(DataManager.FullMoonData:getEndRemainTime()))
|
||||
self.actCountdownSid = self.txCountdown:scheduleGlobal(function()
|
||||
self.txCountdown:setText(GFunc.getTimeStrWithHMS2(DataManager.FullMoonData:getEndRemainTime()))
|
||||
end, 1)
|
||||
|
||||
if self.panelType == GConst.FullMoonConst.PANEL_TYPE.TASK then
|
||||
self:showTaskInfo()
|
||||
elseif self.panelType == GConst.FullMoonConst.PANEL_TYPE.CHOOSE_HERO then
|
||||
self:showChooseHeroInfo()
|
||||
elseif self.panelType == GConst.FullMoonConst.PANEL_TYPE.NEW_HERO then
|
||||
self:showNewHeroInfo()
|
||||
elseif self.panelType == GConst.FullMoonConst.PANEL_TYPE.SKIN then
|
||||
self:showSkinInfo()
|
||||
end
|
||||
self:refreshRedPoint()
|
||||
end
|
||||
|
||||
-- 刷新标签红点
|
||||
function FullMoonUI:refreshRedPoint()
|
||||
-- if DataManager.FullMoonData:hasTaskRedPoint() then
|
||||
-- self.btnTask:addRedPoint(-65, -5, 0.6)
|
||||
-- else
|
||||
-- self.btnTask:removeRedPoint()
|
||||
-- end
|
||||
-- if DataManager.FullMoonData:hasBountyRedPoint() then
|
||||
-- self.btnBounty:addRedPoint(-65, -5, 0.6)
|
||||
-- else
|
||||
-- self.btnBounty:removeRedPoint()
|
||||
-- end
|
||||
-- if DataManager.FullMoonData:hasSkinRedPoint() then
|
||||
-- self.btnSkin:addRedPoint(-65, -5, 0.6)
|
||||
-- else
|
||||
-- self.btnSkin:removeRedPoint()
|
||||
-- end
|
||||
-- if DataManager.FullMoonData:hasHeroRedPoint() then
|
||||
-- self.btnHero:addRedPoint(-65, -5, 0.6)
|
||||
-- else
|
||||
-- self.btnHero:removeRedPoint()
|
||||
-- end
|
||||
end
|
||||
|
||||
function FullMoonUI:showTaskInfo()
|
||||
self.taskPanel:setActive(true)
|
||||
self.selectTask:setActive(true)
|
||||
self.chooseHeroPanel:setActive(false)
|
||||
self.selectChooseHero:setActive(false)
|
||||
self.newHeroPanel:setActive(false)
|
||||
self.selectNewHero:setActive(false)
|
||||
self.skinPanel:setActive(false)
|
||||
self.selectSkin:setActive(false)
|
||||
self.bg_task:setActive(true)
|
||||
self.bg_gift:setActive(false)
|
||||
|
||||
if not self.compTask then
|
||||
self.taskPanel:initPrefabHelper()
|
||||
self.taskPanel:genAllChildren()
|
||||
self.compTask = self.taskPanel:addLuaComponent(COMP_TASK)
|
||||
end
|
||||
|
||||
self.compTask:refresh()
|
||||
end
|
||||
|
||||
function FullMoonUI:showChooseHeroInfo()
|
||||
self.taskPanel:setActive(false)
|
||||
self.selectTask:setActive(false)
|
||||
self.chooseHeroPanel:setActive(true)
|
||||
self.selectChooseHero:setActive(true)
|
||||
self.newHeroPanel:setActive(false)
|
||||
self.selectNewHero:setActive(false)
|
||||
self.skinPanel:setActive(false)
|
||||
self.selectSkin:setActive(false)
|
||||
self.bg_task:setActive(false)
|
||||
self.bg_gift:setActive(true)
|
||||
|
||||
if not self.chooseHeroComp then
|
||||
self.chooseHeroPanel:initPrefabHelper()
|
||||
self.chooseHeroPanel:genAllChildren()
|
||||
self.chooseHeroComp = self.chooseHeroPanel:addLuaComponent(COMP_CHOOSE_HERO)
|
||||
end
|
||||
|
||||
self.chooseHeroComp:refresh()
|
||||
end
|
||||
|
||||
function FullMoonUI:showNewHeroInfo()
|
||||
self.taskPanel:setActive(false)
|
||||
self.selectTask:setActive(false)
|
||||
self.chooseHeroPanel:setActive(false)
|
||||
self.selectChooseHero:setActive(false)
|
||||
self.newHeroPanel:setActive(true)
|
||||
self.selectNewHero:setActive(true)
|
||||
self.skinPanel:setActive(false)
|
||||
self.selectSkin:setActive(false)
|
||||
self.bg_task:setActive(false)
|
||||
self.bg_gift:setActive(true)
|
||||
|
||||
if not self.newHeroComp then
|
||||
self.newHeroPanel:initPrefabHelper()
|
||||
self.newHeroPanel:genAllChildren()
|
||||
self.newHeroComp = self.newHeroPanel:addLuaComponent(COMP_NEW_HERO)
|
||||
end
|
||||
|
||||
self.newHeroComp:refresh()
|
||||
end
|
||||
|
||||
function FullMoonUI:showSkinInfo()
|
||||
self.taskPanel:setActive(false)
|
||||
self.selectTask:setActive(false)
|
||||
self.chooseHeroPanel:setActive(false)
|
||||
self.selectChooseHero:setActive(false)
|
||||
self.newHeroPanel:setActive(false)
|
||||
self.selectNewHero:setActive(false)
|
||||
self.skinPanel:setActive(true)
|
||||
self.selectSkin:setActive(true)
|
||||
self.bg_task:setActive(false)
|
||||
self.bg_gift:setActive(false)
|
||||
|
||||
if not self.compSkin then
|
||||
self.skinPanel:initPrefabHelper()
|
||||
self.skinPanel:genAllChildren()
|
||||
self.compSkin = self.skinPanel:addLuaComponent(COMP_SKIN)
|
||||
end
|
||||
|
||||
self.compSkin:refresh()
|
||||
end
|
||||
|
||||
return FullMoonUI
|
||||
10
lua/app/ui/activity/full_moon/full_moon_ui.lua.meta
Normal file
10
lua/app/ui/activity/full_moon/full_moon_ui.lua.meta
Normal file
@ -0,0 +1,10 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 89c9eb8cb84d89441b6f18941c24b880
|
||||
ScriptedImporter:
|
||||
internalIDToNameTable: []
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
script: {fileID: 11500000, guid: 3b8b241bab4a4ac9a22fcce9c64f1242, type: 3}
|
||||
@ -4,6 +4,7 @@ local EFFECT_LIGHT = "assets/prefabs/effects/ui/vfx_ui_arena_gift_b02.prefab"
|
||||
|
||||
function RewardCell:init()
|
||||
local uiMap = self:getUIMap()
|
||||
self.content = uiMap["reward_cell.content"]
|
||||
self.icon = uiMap["reward_cell.item_bg.icon"]
|
||||
self.frameBg = uiMap["reward_cell.item_bg"]
|
||||
self.mask = uiMap["reward_cell.item_bg.mask"]
|
||||
@ -23,6 +24,10 @@ function RewardCell:init()
|
||||
self.skinQlt = uiMap["reward_cell.skin.img_qlt"]
|
||||
-- 特效
|
||||
self.rootEffect = uiMap["reward_cell.root_effect"]
|
||||
-- 选中框
|
||||
self.select = uiMap["reward_cell.content.item_bg.select"]
|
||||
-- 自选
|
||||
self.choose = uiMap["reward_cell.choose"]
|
||||
|
||||
self:hideFrameAnimation()
|
||||
self.baseObject:addClickListener(function()
|
||||
@ -50,6 +55,12 @@ function RewardCell:refresh(reward)
|
||||
self:showFirstPass(false)
|
||||
end
|
||||
|
||||
-- 展示自选
|
||||
function RewardCell:refreshByChoose()
|
||||
self.choose:setVisible(true)
|
||||
self.content:setVisible(false)
|
||||
end
|
||||
|
||||
function RewardCell:refreshByConfig(reward, mask, check)
|
||||
self:showMask(mask, check)
|
||||
if reward.type == GConst.REWARD_TYPE.ITEM then
|
||||
@ -79,7 +90,10 @@ function RewardCell:refreshItemById(itemId, count, mask, check)
|
||||
end
|
||||
|
||||
function RewardCell:_refreshItem(info, count)
|
||||
self.choose:setVisible(false)
|
||||
self.select:setVisible(false)
|
||||
self.lock:setVisible(false)
|
||||
self.content:setVisible(true)
|
||||
self.numTx:setVisible(true)
|
||||
self.frameBg:setSprite(GConst.ATLAS_PATH.ICON_ITEM, GConst.FRAME_QLT[info.qlt])
|
||||
if count and count > 0 then
|
||||
@ -221,4 +235,9 @@ function RewardCell:showLight(show, ui)
|
||||
end
|
||||
end
|
||||
|
||||
-- 展示选中框
|
||||
function RewardCell:showSelect(show)
|
||||
self.select:setActive(show == true)
|
||||
end
|
||||
|
||||
return RewardCell
|
||||
46
lua/app/ui/main_city/cell/side_bar_full_moon_cell.lua
Normal file
46
lua/app/ui/main_city/cell/side_bar_full_moon_cell.lua
Normal file
@ -0,0 +1,46 @@
|
||||
local SideBarBaseCellComp = require "app/ui/main_city/cell/side_bar_base_cell"
|
||||
local SideBarFullMoonCell = class("SideBarFullMoonCell", SideBarBaseCellComp)
|
||||
|
||||
function SideBarFullMoonCell:getModuleKey()
|
||||
return ModuleManager.MODULE_KEY.ACTIVITY
|
||||
end
|
||||
|
||||
function SideBarFullMoonCell:getIsOpen()
|
||||
return DataManager.FullMoonData:isOpen() and DataManager.FullMoonData:isOpenTime()
|
||||
end
|
||||
|
||||
function SideBarFullMoonCell:getSpineName()
|
||||
return "ui_main_btn_act_fullmoon"
|
||||
end
|
||||
|
||||
function SideBarFullMoonCell:onClick()
|
||||
ModuleManager.FullMoonManager:showActMainUI()
|
||||
end
|
||||
|
||||
function SideBarFullMoonCell:getIsShowRedPoint()
|
||||
return DataManager.FullMoonData:hasEntryRedPoint()
|
||||
end
|
||||
|
||||
function SideBarFullMoonCell:onRefresh()
|
||||
self.timeBg:setVisible(true)
|
||||
self:_refreshTime()
|
||||
end
|
||||
|
||||
function SideBarFullMoonCell:updateTime()
|
||||
if self:getIsOpen() then
|
||||
self:_refreshTime()
|
||||
else
|
||||
self:closeBtn()
|
||||
end
|
||||
end
|
||||
|
||||
function SideBarFullMoonCell:_refreshTime()
|
||||
local remainTime = DataManager.FullMoonData:getEndRemainTime()
|
||||
if remainTime >= 0 then
|
||||
self.timeTx:setText(GFunc.getTimeStr(remainTime))
|
||||
else
|
||||
self.timeTx:setText("00:00:00")
|
||||
end
|
||||
end
|
||||
|
||||
return SideBarFullMoonCell
|
||||
10
lua/app/ui/main_city/cell/side_bar_full_moon_cell.lua.meta
Normal file
10
lua/app/ui/main_city/cell/side_bar_full_moon_cell.lua.meta
Normal file
@ -0,0 +1,10 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 4ba87a7695be4af42842b7637db142ae
|
||||
ScriptedImporter:
|
||||
internalIDToNameTable: []
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
script: {fileID: 11500000, guid: 3b8b241bab4a4ac9a22fcce9c64f1242, type: 3}
|
||||
@ -1111,6 +1111,13 @@ function MainCityUI:checkMainPop()
|
||||
return
|
||||
end
|
||||
|
||||
-- 圆月活动
|
||||
local showType = DataManager.FullMoonData:getNeedShowActPanel()
|
||||
if showType then
|
||||
ModuleManager.FullMoonManager:showActMainUI(showType)
|
||||
return
|
||||
end
|
||||
|
||||
-- 金猪满了后下次进主城要弹出来
|
||||
if DataManager.GoldPigData:getPopFlag() and not DataManager.TutorialData:getIsInTutorial() then
|
||||
DataManager.GoldPigData:markPop()
|
||||
|
||||
@ -3,6 +3,8 @@ local PopRewardCell = class("PopRewardCell", BaseCell)
|
||||
function PopRewardCell:init()
|
||||
local uiMap = self.baseObject:genAllChildren()
|
||||
self.bg = uiMap["pop_reward_cell.bg"]
|
||||
self.choose = uiMap["pop_reward_cell.choose"]
|
||||
self.imgChoose = uiMap["pop_reward_cell.img_choose"]
|
||||
if not self.itemCell then
|
||||
self.itemCell = CellManager:addCellComp(uiMap["pop_reward_cell.item_cell"], GConst.TYPEOF_LUA_CLASS.ITEM_CELL)
|
||||
end
|
||||
@ -10,9 +12,18 @@ function PopRewardCell:init()
|
||||
self.popHeroCell = CellManager:addCellComp(uiMap["pop_reward_cell.pop_hero_cell"], GConst.TYPEOF_LUA_CLASS.POP_HERO_CELL)
|
||||
end
|
||||
self.descTx = uiMap["pop_reward_cell.desc_text"]
|
||||
self:addClickListener(function()
|
||||
if self.clickCallback then
|
||||
self.clickCallback()
|
||||
end
|
||||
end)
|
||||
end
|
||||
|
||||
-- 显示道具
|
||||
function PopRewardCell:refresh(id, num, showBg)
|
||||
self.choose:setActive(false)
|
||||
self.imgChoose:setActive(false)
|
||||
self:setClickListener(nil)
|
||||
local cfgInfo = ConfigManager:getConfig("item")[id]
|
||||
if cfgInfo then
|
||||
self.bg:setVisible(showBg)
|
||||
@ -44,7 +55,23 @@ function PopRewardCell:refresh(id, num, showBg)
|
||||
end
|
||||
end
|
||||
|
||||
function PopRewardCell:addClickListener(callback)
|
||||
-- 显示可选
|
||||
function PopRewardCell:refreshChoose(clickFunc)
|
||||
self.imgChoose:setActive(true)
|
||||
self:setClickListener(clickFunc)
|
||||
end
|
||||
|
||||
-- 只显示可选
|
||||
function PopRewardCell:refreshOnlyChoose(clickFunc)
|
||||
self.choose:setActive(true)
|
||||
self.imgChoose:setActive(false)
|
||||
self.itemCell:getBaseObject():setActive(false)
|
||||
self.popHeroCell:getBaseObject():setActive(false)
|
||||
self.descTx:setText(I18N:getGlobalText(I18N.GlobalConst.REWARD_DESC))
|
||||
self:setClickListener(clickFunc)
|
||||
end
|
||||
|
||||
function PopRewardCell:setClickListener(callback)
|
||||
self.clickCallback = callback
|
||||
end
|
||||
|
||||
|
||||
69
lua/app/ui/tips/choose_reward_tips.lua
Normal file
69
lua/app/ui/tips/choose_reward_tips.lua
Normal file
@ -0,0 +1,69 @@
|
||||
local ChooseRewardTips = class("ChooseRewardTips", BaseUI)
|
||||
|
||||
function ChooseRewardTips:ctor(params)
|
||||
self.strTitle = params.title
|
||||
self.strDesc = params.desc
|
||||
self.chooseRewards = params.rewards
|
||||
self.chooseCallback = params.callback
|
||||
end
|
||||
|
||||
function ChooseRewardTips:onPressBackspace()
|
||||
self:closeUI()
|
||||
end
|
||||
|
||||
function ChooseRewardTips:getPrefabPath()
|
||||
return "assets/prefabs/ui/tips/choose_reward_tips.prefab"
|
||||
end
|
||||
|
||||
function ChooseRewardTips:isFullScreen()
|
||||
return false
|
||||
end
|
||||
|
||||
function ChooseRewardTips:onClose()
|
||||
if self.chooseCallback and self.selectIndex then
|
||||
self.chooseCallback(self.selectIndex)
|
||||
end
|
||||
end
|
||||
|
||||
function ChooseRewardTips:onLoadRootComplete()
|
||||
local uiMap = self.root:genAllChildren()
|
||||
|
||||
self.txDesc = uiMap["choose_reward_tips.content.tx_desc"]
|
||||
self.txTitle = uiMap["choose_reward_tips.content.tx_title"]
|
||||
self.scrollRectComp = uiMap["choose_reward_tips.content.scroll_rect"]:addLuaComponent(GConst.TYPEOF_LUA_CLASS.SCROLL_RECT_BASE)
|
||||
self.btnClose = uiMap["choose_reward_tips.content.btn_close"]
|
||||
self.rewardCell = uiMap["choose_reward_tips.content.reward_cell"]:addLuaComponent(GConst.TYPEOF_LUA_CLASS.REWARD_CELL)
|
||||
|
||||
self.selectIndex = nil
|
||||
self.txTitle:setText(self.strTitle or I18N:getGlobalText(I18N.GlobalConst.HERO_CARD_TIPS_DESC))
|
||||
self.txDesc:setText(self.strDesc or I18N:getGlobalText(I18N.GlobalConst.HERO_CARD_TIPS_DESC))
|
||||
self.rewardCell:refreshByChoose()
|
||||
self:initScrollRect()
|
||||
|
||||
self.btnClose:addClickListener(function()
|
||||
self:closeUI()
|
||||
end)
|
||||
end
|
||||
|
||||
function ChooseRewardTips:initScrollRect()
|
||||
self.scrollRectComp:addInitCallback(function()
|
||||
return GConst.TYPEOF_LUA_CLASS.REWARD_CELL
|
||||
end)
|
||||
self.scrollRectComp:addRefreshCallback(function(index, cell)
|
||||
cell:refreshByConfig(self.chooseRewards[index])
|
||||
cell:showSelect(index == self.selectIndex)
|
||||
cell:addClickListener(function()
|
||||
self:onSelectReward(index)
|
||||
end)
|
||||
end)
|
||||
self.scrollRectComp:clearCells()
|
||||
self.scrollRectComp:refillCells(#self.chooseRewards)
|
||||
end
|
||||
|
||||
function ChooseRewardTips:onSelectReward(index)
|
||||
self.selectIndex = index
|
||||
self.rewardCell:refreshByConfig(self.chooseRewards[self.selectIndex])
|
||||
self.scrollRectComp:updateAllCell()
|
||||
end
|
||||
|
||||
return ChooseRewardTips
|
||||
10
lua/app/ui/tips/choose_reward_tips.lua.meta
Normal file
10
lua/app/ui/tips/choose_reward_tips.lua.meta
Normal file
@ -0,0 +1,10 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 5bb2d9a852b0b394abd828365adc09d3
|
||||
ScriptedImporter:
|
||||
internalIDToNameTable: []
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
script: {fileID: 11500000, guid: 3b8b241bab4a4ac9a22fcce9c64f1242, type: 3}
|
||||
8
lua/app/userdata/activity/full_moon.meta
Normal file
8
lua/app/userdata/activity/full_moon.meta
Normal file
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: aaa5662ae70c08140b8b3f2dde2fb87c
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
584
lua/app/userdata/activity/full_moon/full_moon_data.lua
Normal file
584
lua/app/userdata/activity/full_moon/full_moon_data.lua
Normal file
@ -0,0 +1,584 @@
|
||||
local FullMoonData = class("FullMoonData", BaseData)
|
||||
|
||||
function FullMoonData:ctor()
|
||||
self.data.isDirty = false
|
||||
end
|
||||
|
||||
function FullMoonData:clear()
|
||||
DataManager:unregisterCrossDayFunc("FullMoonData")
|
||||
end
|
||||
|
||||
-- 设置活动数据
|
||||
function FullMoonData:setActStatus(data)
|
||||
data = data or GConst.EMPTY_TABLE
|
||||
|
||||
self.startTime = GFunc.formatTimeStep(data.start_at)
|
||||
self.endTime = GFunc.formatTimeStep(data.end_at)
|
||||
|
||||
if EDITOR_MODE then
|
||||
Logger.logHighlight("圆月活动开启时间:")
|
||||
Logger.printTable(data)
|
||||
end
|
||||
end
|
||||
|
||||
-- 获取活动数据成功
|
||||
function FullMoonData:onGetActData(data)
|
||||
data = data or GConst.EMPTY_TABLE
|
||||
|
||||
self.taskFinished = data.finished or 0-- 任务奖励总计
|
||||
self.taskStatus = data.tasks or GConst.EMPTY_TABLE
|
||||
self.taskProgReward = data.claimed or GConst.EMPTY_TABLE
|
||||
-- self.curHeroGiftId = data.custom_gift_id
|
||||
self.curHeroGiftChoose = data.custom_gift_choose
|
||||
-- self.curNewHeroGiftId = data.hero_gift_id
|
||||
self.chapterSkinClaimed = data.chapter_skin_claimed or GConst.EMPTY_TABLE
|
||||
|
||||
if self:isOpenTime() then
|
||||
-- 注册任务进度监听
|
||||
for id, data in ipairs(ConfigManager:getConfig("activity_full_moon_quest")) do
|
||||
ModuleManager.TaskManager:registerTask("FullMoonData", data.type, function(count)
|
||||
self:addTaskProgress(data.type, count)
|
||||
end)
|
||||
end
|
||||
end
|
||||
|
||||
if EDITOR_MODE then
|
||||
Logger.logHighlight("圆月活动数据:")
|
||||
Logger.printTable(data)
|
||||
end
|
||||
-- 跨天
|
||||
DataManager:registerCrossDayFunc("FullMoonData", function()
|
||||
if not self:isOpen() then
|
||||
return
|
||||
end
|
||||
if not self:isOpenTime() then
|
||||
return
|
||||
end
|
||||
|
||||
ModuleManager.FullMoonManager:reqActData()
|
||||
end)
|
||||
|
||||
self.isInitedData = true
|
||||
self:setDirty()
|
||||
end
|
||||
|
||||
function FullMoonData:setDirty()
|
||||
self.data.isDirty = not self.data.isDirty
|
||||
end
|
||||
|
||||
function FullMoonData:isOpen()
|
||||
if GFunc.isShenhe() then
|
||||
return false
|
||||
end
|
||||
if not ModuleManager:getIsOpen(ModuleManager.MODULE_KEY.ACTIVITY, true) then
|
||||
return false
|
||||
end
|
||||
return true
|
||||
end
|
||||
|
||||
-- 是否在活动配置时间内
|
||||
function FullMoonData:isOpenTime()
|
||||
if self.startTime == nil or self.startTime <= 0 then
|
||||
return false
|
||||
end
|
||||
if self.endTime == nil or self.endTime <= 0 then
|
||||
return false
|
||||
end
|
||||
return Time:getServerTime() >= self.startTime and Time:getServerTime() <= self.endTime
|
||||
end
|
||||
|
||||
-- 获取活动开启剩余时间(秒)
|
||||
function FullMoonData:getStartRemainTime()
|
||||
if self.startTime == nil or self.startTime <= 0 then
|
||||
return 0
|
||||
end
|
||||
return self.startTime - Time:getServerTime()
|
||||
end
|
||||
|
||||
-- 获取活动结束剩余时间(秒)
|
||||
function FullMoonData:getEndRemainTime()
|
||||
if self.endTime == nil or self.endTime <= 0 then
|
||||
return 0
|
||||
end
|
||||
return self.endTime - Time:getServerTime()
|
||||
end
|
||||
|
||||
-- 获取需要展示的活动界面
|
||||
function FullMoonData:getNeedShowActPanel()
|
||||
if not self:isOpen() then
|
||||
return nil
|
||||
end
|
||||
if not self:isOpenTime() then
|
||||
return nil
|
||||
end
|
||||
if not self.isInitedData then
|
||||
return nil
|
||||
end
|
||||
if self.isWatchedActPanel then
|
||||
return nil
|
||||
end
|
||||
|
||||
if not self:isAllBoughtSkinGifts() then
|
||||
return GConst.FullMoonConst.PANEL_TYPE.SKIN
|
||||
end
|
||||
|
||||
if not self:isAllBoughtNewHeroGifts() then
|
||||
return GConst.FullMoonConst.PANEL_TYPE.NEW_HERO
|
||||
end
|
||||
|
||||
if not self:isAllBoughtChooseHeroGifts() then
|
||||
return GConst.FullMoonConst.PANEL_TYPE.CHOOSE_HERO
|
||||
end
|
||||
|
||||
if not self:isTaskAllRewardReceived() then
|
||||
return GConst.FullMoonConst.PANEL_TYPE.TASK
|
||||
end
|
||||
|
||||
return nil
|
||||
end
|
||||
|
||||
-- 展示活动界面
|
||||
function FullMoonData:showActPanel()
|
||||
self.isWatchedActPanel = true
|
||||
end
|
||||
|
||||
-- 是否有入口红点
|
||||
function FullMoonData:hasEntryRedPoint()
|
||||
return self:hasTaskRedPoint()
|
||||
end
|
||||
|
||||
-- 任务--------------------------------------------------------------------------------------------------
|
||||
|
||||
-- 是否奖励全领完
|
||||
function FullMoonData:isTaskAllRewardReceived()
|
||||
for index, id in ipairs(self:getTaskListSort()) do
|
||||
if not self:isReceivedTaskReward(id) then
|
||||
return false
|
||||
end
|
||||
end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
-- 是否有任务红点
|
||||
function FullMoonData:hasTaskRedPoint()
|
||||
for index, id in ipairs(table.keys(ConfigManager:getConfig("activity_full_moon_quest"))) do
|
||||
if self:canGetTaskReward(id) and not self:isReceivedTaskReward(id) then
|
||||
return true
|
||||
end
|
||||
end
|
||||
|
||||
for index, id in ipairs(table.keys(ConfigManager:getConfig("activity_full_moon_reward"))) do
|
||||
if self:isReachTaskProgressReward(id) and not self:isReceivedTaskProgressReward(id) then
|
||||
return true
|
||||
end
|
||||
end
|
||||
|
||||
return false
|
||||
end
|
||||
|
||||
-- 获取任务完成个数
|
||||
function FullMoonData:getTaskFinishNum()
|
||||
return self.taskFinished
|
||||
end
|
||||
|
||||
-- 获取任务完成总目标个数
|
||||
function FullMoonData:getTaskTotalNum()
|
||||
local max
|
||||
for id, value in pairs(ConfigManager:getConfig("activity_full_moon_reward")) do
|
||||
if max == nil or max < value.quest then
|
||||
max = value.quest
|
||||
end
|
||||
end
|
||||
|
||||
return max
|
||||
end
|
||||
|
||||
-- 获取下标对应的任务进度奖励id
|
||||
function FullMoonData:getTaskProgressRewardIdByIndex(index)
|
||||
for id, value in pairs(ConfigManager:getConfig("activity_full_moon_reward")) do
|
||||
if index == 1 then
|
||||
return id
|
||||
end
|
||||
index = index - 1
|
||||
end
|
||||
end
|
||||
|
||||
-- 获取任务进度奖励总个数
|
||||
function FullMoonData:getTaskProgressRewardTotalNum()
|
||||
return table.nums(ConfigManager:getConfig("activity_full_moon_reward"))
|
||||
end
|
||||
|
||||
-- 获取任务进度奖励
|
||||
function FullMoonData:getTaskProgressReward(id)
|
||||
return ConfigManager:getConfig("activity_full_moon_reward")[id].reward
|
||||
end
|
||||
|
||||
-- 获取任务进度目标
|
||||
function FullMoonData:getTaskProgressTarget(id)
|
||||
return ConfigManager:getConfig("activity_full_moon_reward")[id].quest
|
||||
end
|
||||
|
||||
-- 任务进度奖励是否满足领取条件
|
||||
function FullMoonData:isReachTaskProgressReward(id)
|
||||
return self:getTaskFinishNum() >= self:getTaskProgressTarget(id)
|
||||
end
|
||||
|
||||
-- 任务进度奖励是否已领取
|
||||
function FullMoonData:isReceivedTaskProgressReward(id)
|
||||
return self.taskProgReward[id]
|
||||
end
|
||||
|
||||
-- 获取当前定位的任务进度奖励index
|
||||
function FullMoonData:getCurTaskProgressRewardIndex()
|
||||
local index = 0
|
||||
|
||||
for id, data in pairs(ConfigManager:getConfig("activity_full_moon_reward")) do
|
||||
index = index + 1
|
||||
if self:isReachTaskProgressReward(id) and not self:isReceivedTaskProgressReward(id) then
|
||||
return index
|
||||
end
|
||||
end
|
||||
|
||||
index = 0
|
||||
local curStage = self:getTaskProgressRewardId()
|
||||
for id, data in pairs(ConfigManager:getConfig("activity_full_moon_reward")) do
|
||||
index = index + 1
|
||||
if curStage == id then
|
||||
return index
|
||||
end
|
||||
end
|
||||
|
||||
return nil
|
||||
end
|
||||
|
||||
-- 获取任务奖励阶段id
|
||||
function FullMoonData:getTaskProgressRewardId()
|
||||
local finish = self:getTaskFinishNum()
|
||||
local curId
|
||||
for id, data in pairs(ConfigManager:getConfig("activity_full_moon_reward")) do
|
||||
if finish >= data.quest then
|
||||
curId = id
|
||||
else
|
||||
break
|
||||
end
|
||||
finish = finish - data.quest
|
||||
end
|
||||
|
||||
return curId
|
||||
end
|
||||
|
||||
-- 获取今日任务列表
|
||||
function FullMoonData:getTaskListSort()
|
||||
local ids = {}
|
||||
|
||||
for id, data in pairs(self.taskStatus) do
|
||||
local sort = id + 10000000
|
||||
if self:canGetTaskReward(id) and not self:isReceivedTaskReward(id) then
|
||||
sort = sort - 100000
|
||||
end
|
||||
if self:isReceivedTaskReward(id) then
|
||||
sort = sort + 100000
|
||||
end
|
||||
table.insert(ids, {id = id, sort = sort})
|
||||
end
|
||||
table.sort(ids, function (a, b)
|
||||
return a.sort < b.sort
|
||||
end)
|
||||
|
||||
-- Logger.logHighlight("任务列表排序:")
|
||||
-- Logger.printTable(ids)
|
||||
return ids
|
||||
end
|
||||
|
||||
-- 获取任务类型
|
||||
function FullMoonData:getTaskType(id)
|
||||
return ConfigManager:getConfig("activity_full_moon_quest")[id].type
|
||||
end
|
||||
|
||||
-- 获取任务目标
|
||||
function FullMoonData:getTaskTarget(id)
|
||||
return ConfigManager:getConfig("activity_full_moon_quest")[id].number
|
||||
end
|
||||
|
||||
-- 获取任务奖励
|
||||
function FullMoonData:getTaskReward(id)
|
||||
return ConfigManager:getConfig("activity_full_moon_quest")[id].reward
|
||||
end
|
||||
|
||||
-- 获取任务进度
|
||||
function FullMoonData:getTaskProgress(id)
|
||||
if self:getTaskType(id) == GConst.TaskConst.TASK_TYPE.X_PLAYER_LV_REACH then
|
||||
-- 玩家等级实时处理
|
||||
return DataManager.PlayerData:getLv()
|
||||
end
|
||||
return self.taskStatus[id] and self.taskStatus[id].progress or 0
|
||||
end
|
||||
|
||||
-- 任务是否完成
|
||||
function FullMoonData:canGetTaskReward(id)
|
||||
return self:getTaskProgress(id) >= self:getTaskTarget(id)
|
||||
end
|
||||
|
||||
-- 任务奖励是否已领取
|
||||
function FullMoonData:isReceivedTaskReward(id)
|
||||
if self.taskStatus[id] == nil then
|
||||
return false
|
||||
end
|
||||
|
||||
return self.taskStatus[id].claimed
|
||||
end
|
||||
|
||||
-- 添加任务进度
|
||||
function FullMoonData:addTaskProgress(taskType, count)
|
||||
-- Logger.logHighlight("任务进度改变:"..tostring(taskType)..","..tostring(count))
|
||||
if not self:isOpen() then
|
||||
return
|
||||
end
|
||||
if not self:isOpenTime() then
|
||||
return
|
||||
end
|
||||
|
||||
for id, data in pairs(self.taskStatus) do
|
||||
local tt = self:getTaskType(id)
|
||||
if tt == taskType then
|
||||
if self.taskStatus[id] == nil then
|
||||
self.taskStatus[id] = {}
|
||||
self.taskStatus[id].progress = 0
|
||||
end
|
||||
self.taskStatus[id].progress = self.taskStatus[id].progress + count
|
||||
end
|
||||
end
|
||||
|
||||
self:setDirty()
|
||||
end
|
||||
|
||||
-- 领取任务奖励成功
|
||||
function FullMoonData:onReceivedTaskReward(id, finished)
|
||||
self.taskFinished = finished
|
||||
if self.taskStatus[id] then
|
||||
self.taskStatus[id].claimed = true
|
||||
end
|
||||
self:setDirty()
|
||||
end
|
||||
|
||||
-- 领取任务进度奖励成功
|
||||
function FullMoonData:onReceivedTaskProgressReward(id)
|
||||
self.taskProgReward[id] = true
|
||||
self:setDirty()
|
||||
end
|
||||
|
||||
-- 英雄自选连购礼包--------------------------------------------------------------------------------------------------
|
||||
|
||||
-- 所有自选英雄礼包都被购买
|
||||
function FullMoonData:isAllBoughtChooseHeroGifts()
|
||||
for index, id in ipairs(self:getChooseHeroGiftIds()) do
|
||||
if not self:isGiftBought(id) then
|
||||
return false
|
||||
end
|
||||
end
|
||||
return true
|
||||
end
|
||||
|
||||
-- 获取英雄自选礼包ids
|
||||
function FullMoonData:getChooseHeroGiftIds()
|
||||
if self.chooseHeroIds == nil then
|
||||
self.chooseHeroIds = table.keys(DataManager.ShopData:getGiftsByType(PayManager.PURCHARSE_ACT_TYPE.FULL_MOON_HERO_GIFT))
|
||||
table.sort(self.chooseHeroIds)
|
||||
end
|
||||
|
||||
return self.chooseHeroIds
|
||||
end
|
||||
|
||||
-- 当前所处的英雄礼包
|
||||
function FullMoonData:getCurChooseHeroGiftId()
|
||||
for index, id in pairs(self:getChooseHeroGiftIds()) do
|
||||
if not self:isGiftBought(id) then
|
||||
return id
|
||||
end
|
||||
end
|
||||
|
||||
return self:getChooseHeroGiftIds()[#self:getChooseHeroGiftIds()]
|
||||
end
|
||||
|
||||
-- 获取当前组礼包ids
|
||||
function FullMoonData:getCurStepChooseHeroGiftIds()
|
||||
local ids = self:getChooseHeroGiftIds()
|
||||
local curId = self:getCurChooseHeroGiftId()
|
||||
local result = {}
|
||||
local step = 1
|
||||
|
||||
local idx = 0
|
||||
for index, value in ipairs(GConst.FullMoonConst.HERO_GIFT_SHOW_STEP) do
|
||||
result[index] = {}
|
||||
for i = 1, value do
|
||||
idx = idx + 1
|
||||
if curId == ids[idx] then
|
||||
step = index
|
||||
end
|
||||
if ids[idx] then
|
||||
table.insert(result[index], ids[idx])
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
return result[step]
|
||||
end
|
||||
|
||||
-- 当前自选英雄的下标
|
||||
function FullMoonData:getChooseHeroIndex()
|
||||
return self.curHeroGiftChoose > 0 and self.curHeroGiftChoose or nil
|
||||
end
|
||||
|
||||
-- 获取固定奖励
|
||||
function FullMoonData:getFixedRewards(id)
|
||||
return DataManager.ShopData:getActGiftConfig()[id].reward
|
||||
end
|
||||
|
||||
-- 获取自选奖励
|
||||
function FullMoonData:getChooseRewards(id, isAll)
|
||||
|
||||
local rewards = {}
|
||||
|
||||
if not isAll then
|
||||
for index, reward in ipairs(DataManager.ShopData:getActGiftConfig()[id].choose_reward) do
|
||||
local info = ConfigManager:getConfig("item")[reward.id]
|
||||
if info.type == GConst.ItemConst.ITEM_TYPE.HERO_FRAGMENT then
|
||||
if DataManager.HeroData:getHeroIsActive(info.parameter) then
|
||||
table.insert(rewards, reward)
|
||||
end
|
||||
end
|
||||
end
|
||||
else
|
||||
rewards = DataManager.ShopData:getActGiftConfig()[id].choose_reward
|
||||
end
|
||||
|
||||
return rewards
|
||||
end
|
||||
|
||||
-- 获取可选择的自选奖励下标对应的全部自选奖励下标
|
||||
function FullMoonData:getChooseRewardsIndexByCanChooseIndex(index)
|
||||
local selectReward = self:getChooseRewards(self:getCurChooseHeroGiftId())[index]
|
||||
local result = {}
|
||||
for idx, reward in ipairs(self:getChooseRewards(self:getCurChooseHeroGiftId(), true)) do
|
||||
if reward == selectReward then
|
||||
return idx
|
||||
end
|
||||
end
|
||||
|
||||
Logger.logError("未找到"..index)
|
||||
return result
|
||||
end
|
||||
|
||||
-- 自选成功
|
||||
function FullMoonData:onChooseHeroSuccess(index)
|
||||
self.curHeroGiftChoose = index
|
||||
self:setDirty()
|
||||
end
|
||||
|
||||
-- 新英雄连购礼包--------------------------------------------------------------------------------------------------
|
||||
|
||||
-- 所有新英雄礼包都被购买
|
||||
function FullMoonData:isAllBoughtNewHeroGifts()
|
||||
for index, id in ipairs(self:getNewHeroGiftIds()) do
|
||||
if not self:isGiftBought(id) then
|
||||
return false
|
||||
end
|
||||
end
|
||||
return true
|
||||
end
|
||||
|
||||
-- 获取新英雄礼包ids
|
||||
function FullMoonData:getNewHeroGiftIds()
|
||||
if self.newHeroIds == nil then
|
||||
self.newHeroIds = table.keys(DataManager.ShopData:getGiftsByType(PayManager.PURCHARSE_ACT_TYPE.FULL_MOON_NEW_HERO_GIFT))
|
||||
table.sort(self.newHeroIds)
|
||||
end
|
||||
|
||||
return self.newHeroIds
|
||||
end
|
||||
|
||||
-- 当前所处的新英雄礼包
|
||||
function FullMoonData:getCurNewHeroGiftId()
|
||||
for index, id in pairs(self:getNewHeroGiftIds()) do
|
||||
if DataManager.ShopData:getGiftBoughtNum(PayManager.PURCHARSE_TYPE.ACT_GIFT, id) == 0 then
|
||||
return id
|
||||
end
|
||||
end
|
||||
|
||||
return self:getNewHeroGiftIds()[#self:getNewHeroGiftIds()]
|
||||
end
|
||||
|
||||
-- 获取当前组礼包ids
|
||||
function FullMoonData:getCurStepNewHeroGiftIds()
|
||||
local ids = self:getNewHeroGiftIds()
|
||||
local curId = self:getCurNewHeroGiftId()
|
||||
local result = {}
|
||||
local step = 1
|
||||
|
||||
local idx = 0
|
||||
for index, value in ipairs(GConst.FullMoonConst.HERO_GIFT_SHOW_STEP) do
|
||||
result[index] = {}
|
||||
for i = 1, value do
|
||||
idx = idx + 1
|
||||
if curId == ids[idx] then
|
||||
step = index
|
||||
end
|
||||
if ids[idx] then
|
||||
table.insert(result[index], ids[idx])
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
return result[step]
|
||||
end
|
||||
|
||||
-- 皮肤礼包--------------------------------------------------------------------------------------------------
|
||||
|
||||
-- 所有皮肤礼包都被购买
|
||||
function FullMoonData:isAllBoughtSkinGifts()
|
||||
for index, id in ipairs(table.keys(DataManager.ShopData:getGiftsByType(PayManager.PURCHARSE_ACT_TYPE.FULL_MOON_SKIN_GIFT))) do
|
||||
if not self:isGiftBought(id) then
|
||||
return false
|
||||
end
|
||||
end
|
||||
return true
|
||||
end
|
||||
|
||||
-- 皮肤礼包剩余购买次数
|
||||
function FullMoonData:getSkinGiftRemainBuyNum(id)
|
||||
return DataManager.ShopData:getGiftRemainBuyNum(PayManager.PURCHARSE_TYPE.ACT_GIFT, id)
|
||||
end
|
||||
|
||||
-- 获取皮肤挑战首通奖励
|
||||
function FullMoonData:getSkinFirstChallengeReward(id)
|
||||
return ConfigManager:getConfig("chapter_new_skin_fight")[id].reward[1]
|
||||
end
|
||||
|
||||
-- 皮肤挑战首通奖励是否已领取
|
||||
function FullMoonData:isReceivedSkinFirstChallengeReward(id)
|
||||
return self.chapterSkinClaimed[id]
|
||||
end
|
||||
|
||||
-- 设置当前皮肤挑战关卡id
|
||||
function FullMoonData:setCurSkinChallengeId(id)
|
||||
self.curSkinChallengeId = id
|
||||
end
|
||||
|
||||
-- 获取当前皮肤挑战关卡id
|
||||
function FullMoonData:getCurSkinChallengeId()
|
||||
return self.curSkinChallengeId
|
||||
end
|
||||
|
||||
-- 皮肤挑战奖励领取成功
|
||||
function FullMoonData:onReceivedSkinChallengeReward(id)
|
||||
self.chapterSkinClaimed[id] = true
|
||||
self:setDirty()
|
||||
end
|
||||
|
||||
-- 礼包是否已购买
|
||||
function FullMoonData:isGiftBought(id)
|
||||
return DataManager.ShopData:getGiftBoughtNum(PayManager.PURCHARSE_TYPE.ACT_GIFT, id) > 0
|
||||
end
|
||||
|
||||
return FullMoonData
|
||||
10
lua/app/userdata/activity/full_moon/full_moon_data.lua.meta
Normal file
10
lua/app/userdata/activity/full_moon/full_moon_data.lua.meta
Normal file
@ -0,0 +1,10 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 26e9c0c4a4691ed41a638980ce937de9
|
||||
ScriptedImporter:
|
||||
internalIDToNameTable: []
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
script: {fileID: 11500000, guid: 3b8b241bab4a4ac9a22fcce9c64f1242, type: 3}
|
||||
@ -164,6 +164,10 @@ function ItemData:addItem(data, itemGetType)
|
||||
else
|
||||
BIReport:postVitGet(data.count, itemGetType)
|
||||
end
|
||||
elseif data.id == GConst.ItemConst.ITEM_ID_RUNES then
|
||||
if data.count > 0 then
|
||||
ModuleManager.TaskManager:addTaskProgress(GConst.TaskConst.TASK_TYPE.X_RUNES_GETED_MATERIALS, data.count)
|
||||
end
|
||||
else
|
||||
if data.count < 0 then
|
||||
BIReport:postItemUse(data.count, data.id, itemGetType)
|
||||
|
||||
@ -202,6 +202,7 @@ function PlayerData:addPayment(rechargeId)
|
||||
self.data.payAmount = self.data.payAmount + cfg.price
|
||||
self.data.payCount = self.data.payCount + 1
|
||||
self.pay_counts[rechargeId] = (self.pay_counts[rechargeId] or 0) + 1
|
||||
ModuleManager.TaskManager:addTaskProgress(GConst.TaskConst.TASK_TYPE.X_BUY_ANYONE)
|
||||
end
|
||||
|
||||
function PlayerData:getPayCount()
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user