2021-04-20 13:58:00 +08:00
|
|
|
local TimeLimitedCall= quick_class("TimeLimitedCall")
|
2020-06-28 17:48:49 +08:00
|
|
|
|
2020-08-21 11:23:46 +08:00
|
|
|
local ActivityDetail = require("Modules/DynamicActivity/ActivityDetail")--活动详情
|
|
|
|
local RewardPreview = require("Modules/DynamicActivity/RewardPreview")--奖励预览
|
2020-06-28 17:48:49 +08:00
|
|
|
local sortingOrder = 0
|
|
|
|
local lotterySetting=ConfigManager.GetConfig(ConfigName.LotterySetting)
|
|
|
|
local privilegeConfig=ConfigManager.GetConfig(ConfigName.PrivilegeTypeConfig)
|
|
|
|
local artResourcesConfig =ConfigManager.GetConfig(ConfigName.ArtResourcesConfig)
|
|
|
|
local itemConfig=ConfigManager.GetConfig(ConfigName.ItemConfig)
|
|
|
|
local heroConfig=ConfigManager.GetConfig(ConfigName.HeroConfig)
|
2020-09-24 17:26:27 +08:00
|
|
|
local parent
|
|
|
|
local activityId = 0
|
|
|
|
local singleRecruit = nil
|
|
|
|
local tenRecruit = nil
|
2020-06-28 17:48:49 +08:00
|
|
|
--按钮类型
|
|
|
|
local bType={
|
|
|
|
Btn1=1,
|
|
|
|
Btn10=2
|
|
|
|
}
|
|
|
|
|
2020-09-24 17:26:27 +08:00
|
|
|
local activityType = {
|
|
|
|
--破阵诛仙 限时召唤
|
|
|
|
[4301] = {
|
|
|
|
bg = "Bg1",
|
|
|
|
hero = {
|
2020-10-13 20:36:01 +08:00
|
|
|
[1]={name="Bg1/hero1",id=10001,hero="x_xianshizaohuan_fx"}, --伏羲
|
|
|
|
[2]={name="Bg1/hero3",id=10041,hero="x_xianshizaohuan_ttjz"}, --通天教主
|
|
|
|
[3]={name="Bg1/hero2",id=10089,hero="x_xianshizaohuan_rd"}, --燃灯
|
2020-09-24 17:26:27 +08:00
|
|
|
},
|
2021-01-26 17:08:39 +08:00
|
|
|
title = "x_xianshizaohuan_solgan_zh",
|
2020-09-24 17:26:27 +08:00
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
|
|
|
--勇冠三军 限时召唤
|
|
|
|
[4302] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
2021-03-24 18:16:30 +08:00
|
|
|
[1]={name="Bg2/hero1",id=10009,hero="t_tianxiangjiren_shenjiang33"},
|
|
|
|
[2]={name="Bg2/hero3",id=10014,hero="s_shibukedang_shenjiang1"},
|
2021-03-24 18:01:33 +08:00
|
|
|
[3]={name="Bg2/hero2",id=10026,hero="s_yongwangzhiqian_shenjiang2"},
|
2020-09-24 17:26:27 +08:00
|
|
|
},
|
2021-01-26 17:08:39 +08:00
|
|
|
title = "c_ydsj_slogan_zh",
|
2020-09-24 17:26:27 +08:00
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
|
|
|
--叱咤风云 限时召唤
|
|
|
|
[4303] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
2021-04-01 12:30:37 +08:00
|
|
|
[1]={name="Bg2/hero1",id=10041,hero="x_xuanjimiaosuan_shenjiang3"},
|
2021-03-30 14:22:37 +08:00
|
|
|
[2]={name="Bg2/hero3",id=10024,hero="d_danxinbixue_shenjiang3"},
|
|
|
|
[3]={name="Bg2/hero2",id=10003,hero="s_suoxiangpimi_shenjiang2"},
|
2020-09-24 17:26:27 +08:00
|
|
|
},
|
2021-01-26 17:08:39 +08:00
|
|
|
title = "c_ccfy_slogan_zh",
|
2020-09-24 17:26:27 +08:00
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
2020-09-29 15:35:08 +08:00
|
|
|
--叱咤风云 限时召唤
|
|
|
|
[4304] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
2021-04-07 11:24:49 +08:00
|
|
|
[1]={name="Bg2/hero1",id=10026,hero="y_yishandaohai_shenjiang1"},
|
|
|
|
[2]={name="Bg2/hero3",id=10006,hero="c_ygsj_kuang001_nmw"},
|
|
|
|
[3]={name="Bg2/hero2",id=10011,hero="y_yunchouweiwo_shenjiang1"},
|
2020-09-29 15:35:08 +08:00
|
|
|
},
|
2021-01-26 17:08:39 +08:00
|
|
|
title = "d_danxinbixue_zi_zh",
|
2020-09-29 15:35:08 +08:00
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
2020-10-13 20:36:01 +08:00
|
|
|
--势不可挡 限时召唤
|
2020-10-16 13:58:51 +08:00
|
|
|
[4305] = {
|
2020-10-13 20:36:01 +08:00
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
|
|
|
[1]={name="Bg2/hero1",id=10014,hero="s_shibukedang_shenjiang1"}, ----哪吒
|
|
|
|
[2]={name="Bg2/hero3",id=10090,hero="s_shibukedang_shenjiang3"}, --阎罗王
|
2020-10-23 17:35:47 +08:00
|
|
|
[3]={name="Bg2/hero2",id=10085,hero="s_shibukedang_shenjiang4"}, ----敖丙
|
2020-10-13 20:36:01 +08:00
|
|
|
},
|
2021-01-26 17:08:39 +08:00
|
|
|
title = "s_shibukedang_zi_zh",
|
2020-10-13 20:36:01 +08:00
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
2020-10-21 14:13:07 +08:00
|
|
|
--勇往直前 限时召唤
|
|
|
|
[4306] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
2020-11-04 00:15:26 +08:00
|
|
|
[1]={name="Bg2/hero1",id=10089,hero="s_yongwangzhiqian_shenjiang1"}, ----燃灯
|
2020-10-21 14:13:07 +08:00
|
|
|
[2]={name="Bg2/hero3",id=10015,hero="s_yongwangzhiqian_shenjiang3"}, --伏虎罗汉
|
|
|
|
[3]={name="Bg2/hero2",id=10026,hero="s_yongwangzhiqian_shenjiang2"}, ----东华帝君
|
|
|
|
},
|
2021-01-26 17:08:39 +08:00
|
|
|
title = "s_yongwangzhiqian_zi_zh",
|
2020-10-21 14:13:07 +08:00
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
2020-10-28 14:10:20 +08:00
|
|
|
--运筹帷幄 限时召唤
|
|
|
|
[4307] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
|
|
|
[1]={name="Bg2/hero1",id=10011,hero="y_yunchouweiwo_shenjiang1"}, ----雷震子
|
2020-10-28 18:36:54 +08:00
|
|
|
[2]={name="Bg2/hero2",id=10041,hero="y_yunchouweiwo_shenjiang2"}, --通天教主
|
|
|
|
[3]={name="Bg2/hero3",id=10022,hero="y_yunchouweiwo_shenjiang3"}, ----达摩
|
2020-10-28 14:10:20 +08:00
|
|
|
},
|
2021-01-26 17:08:39 +08:00
|
|
|
title = "y_yunchouweiwo_zi_zh",
|
2020-10-28 14:10:20 +08:00
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
2020-11-12 15:10:52 +08:00
|
|
|
--移山倒海 限时召唤
|
2020-11-06 10:49:08 +08:00
|
|
|
[4308] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
|
|
|
[1]={name="Bg2/hero1",id=10026,hero="y_yishandaohai_shenjiang1"}, ----东华帝君
|
|
|
|
[2]={name="Bg2/hero2",id=10085,hero="s_shibukedang_shenjiang4"}, --敖丙
|
|
|
|
[3]={name="Bg2/hero3",id=10013,hero="y_yishandaohai_shenjiang2"}, ----吕洞宾
|
|
|
|
},
|
2021-01-26 17:08:39 +08:00
|
|
|
title = "y_yishandaohai_zi_zh",
|
2020-11-06 10:49:08 +08:00
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
2020-11-12 15:10:52 +08:00
|
|
|
--玄机妙算 限时召唤
|
|
|
|
[4309] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
|
|
|
[1]={name="Bg2/hero1",id=10003,hero="d_danxinbixue_shenjiang1"}, --猪八戒
|
|
|
|
[2]={name="Bg2/hero2",id=10023,hero="x_xuanjimiaosuan_shenjiang2"}, --孙悟空
|
2020-11-13 15:50:42 +08:00
|
|
|
[3]={name="Bg2/hero3",id=10041,hero="x_xuanjimiaosuan_shenjiang3"}, --通天教主
|
2020-11-12 15:10:52 +08:00
|
|
|
},
|
2021-01-26 17:08:39 +08:00
|
|
|
title = "x_xuanjimiaosuan_zi_zh",
|
2020-11-12 15:10:52 +08:00
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
2020-11-18 18:15:50 +08:00
|
|
|
--降龙伏虎 限时召唤
|
2020-11-19 10:35:21 +08:00
|
|
|
[4310] = {
|
2020-11-18 18:15:50 +08:00
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
|
|
|
[1]={name="Bg2/hero1",id=10012,hero="x_xianglongfuhu_shenjiang1"}, --降龙
|
|
|
|
[2]={name="Bg2/hero2",id=10015,hero="x_xianglongfuhu_shenjiang2"}, --伏虎
|
|
|
|
[3]={name="Bg2/hero3",id=10017,hero="x_xianglongfuhu_shenjiang3"}, --嫦娥
|
|
|
|
},
|
2021-01-26 17:08:39 +08:00
|
|
|
title = "x_xianglongfuhu_zi_zh",
|
2020-11-18 18:15:50 +08:00
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
2020-12-03 15:00:49 +08:00
|
|
|
--旗开得胜 限时召唤
|
2020-11-25 21:02:16 +08:00
|
|
|
[4311] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
|
|
|
[1]={name="Bg2/hero1",id=10026,hero="y_yishandaohai_shenjiang1"}, ----东华帝君
|
|
|
|
[2]={name="Bg2/hero2",id=10013,hero="q_qikaidesheng_shenjiang2"}, ---吕洞宾
|
|
|
|
[3]={name="Bg2/hero3",id=10023,hero="c_ccfy_kuang03"}, --孙悟空
|
|
|
|
},
|
2021-01-26 17:08:39 +08:00
|
|
|
title = "q_qikaidesheng_zi_zh",
|
2020-11-25 21:02:16 +08:00
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
2020-12-03 15:00:49 +08:00
|
|
|
--变幻莫测 限时召唤
|
|
|
|
[4312] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
2020-09-20 00:15:43 +08:00
|
|
|
[1]={name="Bg2/hero1",id=10002,hero="b_bianhuanmoce_shenjiang1"}, ----洛神
|
|
|
|
[2]={name="Bg2/hero2",id=10033,hero="b_bianhuanmoce_shenjiang2"}, ---净光天女
|
2020-09-17 12:25:03 +08:00
|
|
|
[3]={name="Bg2/hero3",id=10015,hero="s_yongwangzhiqian_shenjiang3"}, --伏虎罗汉
|
2020-12-03 15:00:49 +08:00
|
|
|
},
|
2021-01-26 17:08:39 +08:00
|
|
|
title = "b_bianhuanmoce_zi_zh",
|
2020-12-03 15:00:49 +08:00
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
2020-12-10 11:35:56 +08:00
|
|
|
--博文多识 限时召唤
|
|
|
|
[4313] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
|
|
|
[1]={name="Bg2/hero1",id=10008,hero="b_bowenduoshi_shenjiang1"}, ----精卫
|
|
|
|
[2]={name="Bg2/hero2",id=10014,hero="c_ccfy_kuang01"}, ---哪吒
|
2021-02-25 10:20:14 +08:00
|
|
|
[3]={name="Bg2/hero3",id=10013,hero="y_yishandaohai_shenjiang2"}, --吕洞宾
|
2020-12-10 11:35:56 +08:00
|
|
|
},
|
2021-01-26 17:08:39 +08:00
|
|
|
title = "b_bowenduoshi_zi_zh",
|
2020-12-10 11:35:56 +08:00
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
2021-01-26 17:08:39 +08:00
|
|
|
-- 天相吉人
|
2020-12-17 15:34:21 +08:00
|
|
|
[4314] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
|
|
|
[1]={name="Bg2/hero1",id=10087,hero="t_tianxiangjiren_shenjiang1"}, ----娥皇
|
2020-12-17 15:46:28 +08:00
|
|
|
[2]={name="Bg2/hero2",id=10043,hero="t_tianxiangjiren_shenjiang2"}, ---太阴星君
|
|
|
|
[3]={name="Bg2/hero3",id=10033,hero="t_tianxiangjiren_shenjiang3"}, --净光天女
|
2020-12-17 15:34:21 +08:00
|
|
|
},
|
2021-01-26 17:08:39 +08:00
|
|
|
title = "t_tianxiangjiren_zi_zh",
|
2020-12-17 15:34:21 +08:00
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
2020-12-24 10:21:26 +08:00
|
|
|
--博文多识 限时召唤
|
|
|
|
[4315] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
2021-01-04 15:21:46 +08:00
|
|
|
[1]={name="Bg2/hero1",id=10014,hero="s_shibukedang_shenjiang1"}, ----哪吒
|
|
|
|
[2]={name="Bg2/hero2",id=10003,hero="s_suoxiangpimi_shenjiang2"}, ---猪八戒
|
2020-12-24 10:21:26 +08:00
|
|
|
[3]={name="Bg2/hero3",id=10002,hero="b_bianhuanmoce_shenjiang1"}, --洛神
|
|
|
|
},
|
2021-01-26 17:08:39 +08:00
|
|
|
title = "s_suoxiangpimi_zi_zh",
|
2020-12-24 10:21:26 +08:00
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
2020-12-30 15:56:11 +08:00
|
|
|
--狭路相逢 限时召唤
|
|
|
|
[4316] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
2021-01-04 15:21:46 +08:00
|
|
|
[1]={name="Bg2/hero1",id=10014,hero="s_shibukedang_shenjiang1"}, ----哪吒
|
|
|
|
[2]={name="Bg2/hero2",id=10003,hero="s_suoxiangpimi_shenjiang2"}, ---猪八戒
|
2020-12-30 15:56:11 +08:00
|
|
|
[3]={name="Bg2/hero3",id=10002,hero="b_bianhuanmoce_shenjiang1"}, --洛神
|
|
|
|
},
|
2021-01-26 17:08:39 +08:00
|
|
|
title = "x_xialuxiangfeng_zi_zh",
|
2020-12-30 15:56:11 +08:00
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
2021-01-07 16:22:36 +08:00
|
|
|
--铜墙铁壁 限时召唤
|
|
|
|
[4317] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
|
|
|
[1]={name="Bg2/hero1",id=10043,hero="t_tongqiangtiebi_shenjiang1"}, ----太阴星君
|
|
|
|
[2]={name="Bg2/hero2",id=10019,hero="t_tongqiangtiebi_shenjiang2"}, ---巨灵神
|
|
|
|
[3]={name="Bg2/hero3",id=10016,hero="t_tongqiangtiebi_shenjiang3"}, --蚩尤
|
|
|
|
},
|
2021-01-26 17:08:39 +08:00
|
|
|
title = "t_tongqiangtiebi_zi_zh",
|
2021-01-07 16:22:36 +08:00
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
2021-01-12 10:39:41 +08:00
|
|
|
--破阵诛仙 限时召唤
|
|
|
|
[4318] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
2021-01-12 10:59:04 +08:00
|
|
|
[1]={name="Bg2/hero1",id=10003,hero="d_danxinbixue_shenjiang1"}, --猪八戒
|
|
|
|
[2]={name="Bg2/hero3",id=10004,hero="x_xianshizaohuan_shenjiang3"}, --慈航道人
|
|
|
|
[3]={name="Bg2/hero2",id=10023,hero="c_ccfy_kuang03"}, --孙悟空
|
2021-01-12 10:39:41 +08:00
|
|
|
},
|
2021-02-04 11:22:59 +08:00
|
|
|
title = "x_xianshizaohuan_solgan01_zh",
|
2021-01-12 10:39:41 +08:00
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
|
|
|
--勇冠三军 限时召唤
|
|
|
|
[4319] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
|
|
|
[1]={name="Bg2/hero1",id=10018,hero="c_ygsj_kuang001"}, --九命猫
|
|
|
|
[2]={name="Bg2/hero3",id=10019,hero="c_ygsj_kuang003"}, --巨灵神
|
|
|
|
[3]={name="Bg2/hero2",id=10024,hero="c_ygsj_kuang002"}, --姜子牙
|
|
|
|
},
|
2021-02-04 11:22:59 +08:00
|
|
|
title = "c_ydsj_slogan_zh",
|
2021-01-12 10:39:41 +08:00
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
2021-01-25 20:34:16 +08:00
|
|
|
--勇冠三军 限时召唤
|
|
|
|
[4319] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
|
|
|
[1]={name="Bg2/hero1",id=10018,hero="c_ygsj_kuang001"}, --九命猫
|
|
|
|
[2]={name="Bg2/hero3",id=10019,hero="c_ygsj_kuang003"}, --巨灵神
|
|
|
|
[3]={name="Bg2/hero2",id=10024,hero="c_ygsj_kuang002"}, --姜子牙
|
|
|
|
},
|
2021-02-26 13:47:04 +08:00
|
|
|
title = "c_ydsj_slogan_zh",
|
2021-01-25 20:34:16 +08:00
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
|
|
|
--勇冠三军 限时召唤
|
|
|
|
[4320] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
|
|
|
[1]={name="Bg2/hero1",id=10040,hero="d_danxinbixue_shenjiang11"}, --杨戬
|
|
|
|
[2]={name="Bg2/hero3",id=10024,hero="d_danxinbixue_shenjiang3"}, --姜子牙
|
|
|
|
[3]={name="Bg2/hero2",id=10026,hero="s_yongwangzhiqian_shenjiang2"}, ----东华帝君
|
|
|
|
},
|
2021-02-26 13:47:04 +08:00
|
|
|
title = "d_danxinbixue_zi_zh",
|
2021-01-25 20:34:16 +08:00
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
|
|
|
--勇冠三军 限时召唤
|
|
|
|
[4321] = {
|
2021-01-26 12:01:01 +08:00
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
|
|
|
[1]={name="Bg2/hero1",id=10040,hero="d_danxinbixue_shenjiang11"}, --杨戬
|
|
|
|
[2]={name="Bg2/hero3",id=10024,hero="d_danxinbixue_shenjiang3"}, --姜子牙
|
|
|
|
[3]={name="Bg2/hero2",id=10026,hero="s_yongwangzhiqian_shenjiang2"}, ----东华帝君
|
|
|
|
},
|
2021-02-26 13:47:04 +08:00
|
|
|
title = "d_danxinbixue_zi_zh",
|
2021-01-26 12:01:01 +08:00
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
|
|
|
--勇冠三军 限时召唤
|
|
|
|
[4322] = {
|
2021-01-25 20:34:16 +08:00
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
|
|
|
[1]={name="Bg2/hero1",id=10092,hero="s_shibukedang_shenjiang11"}, --杨戬
|
|
|
|
[2]={name="Bg2/hero2",id=10041,hero="y_yunchouweiwo_shenjiang2"}, --通天教主
|
|
|
|
[3]={name="Bg2/hero3",id=10087,hero="s_shibukedang_shenjiang33"}, ----娥皇
|
|
|
|
},
|
2021-02-26 13:47:04 +08:00
|
|
|
title = "s_shibukedang_zi_zh",
|
2021-01-25 20:34:16 +08:00
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
2021-02-18 10:52:02 +08:00
|
|
|
--勇冠三军 限时召唤
|
|
|
|
[4323] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
|
|
|
[1]={name="Bg2/hero1",id=10026,hero="y_yishandaohai_shenjiang1"}, ----东华帝君
|
|
|
|
[2]={name="Bg2/hero2",id=10033,hero="b_bianhuanmoce_shenjiang2"}, ---净光天女
|
|
|
|
[3]={name="Bg2/hero3",id=10091,hero="s_yongwangzhiqian_shenjiang33"}, ----白骨精
|
|
|
|
},
|
2021-02-26 13:47:04 +08:00
|
|
|
title = "s_yongwangzhiqian_zi_zh",
|
2021-02-18 10:52:02 +08:00
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
2021-02-25 10:20:14 +08:00
|
|
|
--勇冠三军 限时召唤
|
|
|
|
[4324] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
|
|
|
[1]={name="Bg2/hero1",id=10003,hero="d_danxinbixue_shenjiang1"}, --猪八戒
|
|
|
|
[2]={name="Bg2/hero2",id=10023,hero="x_xuanjimiaosuan_shenjiang2"}, --孙悟空
|
|
|
|
[3]={name="Bg2/hero3",id=10041,hero="x_xuanjimiaosuan_shenjiang3"}, --通天教主
|
|
|
|
},
|
2021-03-04 23:14:42 +08:00
|
|
|
title = "y_yunchouweiwo_zi_zh",
|
2021-02-25 10:20:14 +08:00
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
|
|
|
--勇冠三军 限时召唤
|
|
|
|
[4325] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
|
|
|
[1]={name="Bg2/hero1",id=10013,hero="y_yishandaohai_shenjiang2"}, ----吕洞宾
|
|
|
|
[2]={name="Bg2/hero2",id=10014,hero="c_ccfy_kuang01"}, --哪吒
|
|
|
|
[3]={name="Bg2/hero3",id=10033,hero="t_tianxiangjiren_shenjiang3"}, --净光天女
|
|
|
|
},
|
2021-03-04 23:14:42 +08:00
|
|
|
title = "y_yishandaohai_zi_zh",
|
2021-02-25 10:20:14 +08:00
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
2021-03-11 10:59:49 +08:00
|
|
|
--玄机妙算 限时召唤
|
|
|
|
[4326] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
|
|
|
[1]={name="Bg2/hero1",id=10007,hero="x_xuanjimiaosuan_shenjiang1"}, --唐僧
|
2021-03-12 12:08:24 +08:00
|
|
|
[2]={name="Bg2/hero2",id=10040,hero="c_ygsj_kuang01"}, --杨戬
|
|
|
|
[3]={name="Bg2/hero3",id=10023,hero="c_ccfy_kuang03"}, --孙悟空
|
2021-03-11 10:59:49 +08:00
|
|
|
},
|
|
|
|
title = "x_xuanjimiaosuan_zi_zh",
|
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
|
|
|
--降龙伏虎 限时召唤
|
|
|
|
[4327] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
2021-03-12 12:08:24 +08:00
|
|
|
[1]={name="Bg2/hero1",id=10014,hero="s_shibukedang_shenjiang1"}, --哪吒
|
|
|
|
[2]={name="Bg2/hero2",id=10011,hero="y_yunchouweiwo_shenjiang1"}, --雷震子
|
|
|
|
[3]={name="Bg2/hero3",id=10090,hero="x_xianglongfuhu_shenjiang22"}, --阎罗王
|
2021-03-11 10:59:49 +08:00
|
|
|
},
|
|
|
|
title = "x_xianglongfuhu_zi_zh",
|
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
|
|
|
--旗开得胜 限时召唤
|
|
|
|
[4328] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
2021-03-24 13:57:08 +08:00
|
|
|
[1]={name="Bg2/hero1",id=10040,hero="d_danxinbixue_shenjiang11"},
|
|
|
|
[2]={name="Bg2/hero2",id=10092,hero="s_shibukedang_shenjiang11"},
|
|
|
|
[3]={name="Bg2/hero3",id=10026,hero="y_yishandaohai_shenjiang1"},
|
2021-03-11 10:59:49 +08:00
|
|
|
},
|
2021-03-24 13:57:08 +08:00
|
|
|
title = "b_bowenduoshi_zi_zh",
|
2021-03-11 10:59:49 +08:00
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
|
|
|
--变幻莫测 限时召唤
|
|
|
|
[4329] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
2021-03-24 13:57:08 +08:00
|
|
|
[1]={name="Bg2/hero1",id=10003,hero="d_danxinbixue_shenjiang1"}, ----洛神
|
|
|
|
[2]={name="Bg2/hero2",id=10041,hero="y_yunchouweiwo_shenjiang2"}, ---净光天女
|
|
|
|
[3]={name="Bg2/hero3",id=10011,hero="y_yunchouweiwo_shenjiang1"}, --伏虎罗汉
|
2021-03-11 10:59:49 +08:00
|
|
|
},
|
2021-03-24 13:57:08 +08:00
|
|
|
title = "t_tianxiangjiren_zi_zh",
|
2021-03-11 10:59:49 +08:00
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
|
|
|
--博文多识 限时召唤
|
|
|
|
[4330] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
2021-04-08 17:03:00 +08:00
|
|
|
[1]={name="Bg2/hero1",id=10092,hero="s_shibukedang_shenjiang11"}, ----精卫
|
2021-04-09 16:20:26 +08:00
|
|
|
[2]={name="Bg2/hero2",id=10033,hero="timelimit_putishushen2"}, ---哪吒
|
2021-04-08 17:03:00 +08:00
|
|
|
[3]={name="Bg2/hero3",id=10090,hero="x_xianglongfuhu_shenjiang22"}, --吕洞宾
|
2021-03-11 10:59:49 +08:00
|
|
|
},
|
2021-04-08 17:03:00 +08:00
|
|
|
title = "s_suoxiangpimi_zi_zh",
|
2021-03-11 10:59:49 +08:00
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
|
|
|
-- 天相吉人
|
|
|
|
[4331] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
2021-04-08 17:03:00 +08:00
|
|
|
[1]={name="Bg2/hero1",id=10024,hero="d_danxinbixue_shenjiang3"}, ----娥皇
|
|
|
|
[2]={name="Bg2/hero2",id=10023,hero="x_xuanjimiaosuan_shenjiang2"}, ---太阴星君
|
2021-04-09 15:22:27 +08:00
|
|
|
[3]={name="Bg2/hero3",id=10041,hero="x_xuanjimiaosuan_shenjiang3"}, --净光天女
|
2021-03-11 10:59:49 +08:00
|
|
|
},
|
2021-04-08 17:03:00 +08:00
|
|
|
title = "x_xialuxiangfeng_zi_zh",
|
2021-03-11 10:59:49 +08:00
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
|
|
|
--博文多识 限时召唤
|
|
|
|
[4332] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
|
|
|
[1]={name="Bg2/hero1",id=10014,hero="s_shibukedang_shenjiang1"}, ----哪吒
|
|
|
|
[2]={name="Bg2/hero2",id=10003,hero="s_suoxiangpimi_shenjiang2"}, ---猪八戒
|
|
|
|
[3]={name="Bg2/hero3",id=10002,hero="b_bianhuanmoce_shenjiang1"}, --洛神
|
|
|
|
},
|
|
|
|
title = "s_suoxiangpimi_zi_zh",
|
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
|
|
|
--狭路相逢 限时召唤
|
|
|
|
[4333] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
|
|
|
[1]={name="Bg2/hero1",id=10014,hero="s_shibukedang_shenjiang1"}, ----哪吒
|
|
|
|
[2]={name="Bg2/hero2",id=10003,hero="s_suoxiangpimi_shenjiang2"}, ---猪八戒
|
|
|
|
[3]={name="Bg2/hero3",id=10002,hero="b_bianhuanmoce_shenjiang1"}, --洛神
|
|
|
|
},
|
|
|
|
title = "x_xialuxiangfeng_zi_zh",
|
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
|
|
|
--铜墙铁壁 限时召唤
|
|
|
|
[4334] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
|
|
|
[1]={name="Bg2/hero1",id=10043,hero="t_tongqiangtiebi_shenjiang1"}, ----太阴星君
|
|
|
|
[2]={name="Bg2/hero2",id=10019,hero="t_tongqiangtiebi_shenjiang2"}, ---巨灵神
|
|
|
|
[3]={name="Bg2/hero3",id=10016,hero="t_tongqiangtiebi_shenjiang3"}, --蚩尤
|
|
|
|
},
|
|
|
|
title = "t_tongqiangtiebi_zi_zh",
|
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
|
|
|
--破阵诛仙 限时召唤
|
|
|
|
[4335] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
|
|
|
[1]={name="Bg2/hero1",id=10003,hero="d_danxinbixue_shenjiang1"}, --猪八戒
|
|
|
|
[2]={name="Bg2/hero3",id=10004,hero="x_xianshizaohuan_shenjiang3"}, --慈航道人
|
|
|
|
[3]={name="Bg2/hero2",id=10023,hero="c_ccfy_kuang03"}, --孙悟空
|
|
|
|
},
|
|
|
|
title = "x_xianshizaohuan_solgan01_zh",
|
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
|
|
|
--勇冠三军 限时召唤
|
|
|
|
[4336] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
|
|
|
[1]={name="Bg2/hero1",id=10018,hero="c_ygsj_kuang001"}, --九命猫
|
|
|
|
[2]={name="Bg2/hero3",id=10019,hero="c_ygsj_kuang003"}, --巨灵神
|
|
|
|
[3]={name="Bg2/hero2",id=10024,hero="c_ygsj_kuang002"}, --姜子牙
|
|
|
|
},
|
|
|
|
title = "c_ydsj_slogan_zh",
|
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
|
|
|
--勇冠三军 限时召唤
|
|
|
|
[4337] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
|
|
|
[1]={name="Bg2/hero1",id=10018,hero="c_ygsj_kuang001"}, --九命猫
|
|
|
|
[2]={name="Bg2/hero3",id=10019,hero="c_ygsj_kuang003"}, --巨灵神
|
|
|
|
[3]={name="Bg2/hero2",id=10024,hero="x_xianglongfuhu_shenjiang3"}, --姜子牙
|
|
|
|
},
|
|
|
|
title = "c_ydsj_slogan_zh",
|
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
|
|
|
--勇冠三军 限时召唤
|
|
|
|
[4338] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
|
|
|
[1]={name="Bg2/hero1",id=10040,hero="d_danxinbixue_shenjiang11"}, --杨戬
|
|
|
|
[2]={name="Bg2/hero3",id=10024,hero="d_danxinbixue_shenjiang3"}, --姜子牙
|
|
|
|
[3]={name="Bg2/hero2",id=10026,hero="s_yongwangzhiqian_shenjiang2"}, ----东华帝君
|
|
|
|
},
|
|
|
|
title = "d_danxinbixue_zi_zh",
|
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
|
|
|
--勇冠三军 限时召唤
|
|
|
|
[4339] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
|
|
|
[1]={name="Bg2/hero1",id=10040,hero="d_danxinbixue_shenjiang11"}, --杨戬
|
|
|
|
[2]={name="Bg2/hero3",id=10024,hero="d_danxinbixue_shenjiang3"}, --姜子牙
|
|
|
|
[3]={name="Bg2/hero2",id=10026,hero="s_yongwangzhiqian_shenjiang2"}, ----东华帝君
|
|
|
|
},
|
|
|
|
title = "d_danxinbixue_zi_zh",
|
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
|
|
|
--勇冠三军 限时召唤
|
|
|
|
[4340] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
|
|
|
[1]={name="Bg2/hero1",id=10092,hero="s_shibukedang_shenjiang11"}, --杨戬
|
|
|
|
[2]={name="Bg2/hero2",id=10041,hero="y_yunchouweiwo_shenjiang2"}, --通天教主
|
|
|
|
[3]={name="Bg2/hero3",id=10087,hero="s_shibukedang_shenjiang33"}, ----娥皇
|
|
|
|
},
|
|
|
|
title = "s_shibukedang_zi_zh",
|
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
|
|
|
--勇冠三军 限时召唤
|
|
|
|
[4341] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
|
|
|
[1]={name="Bg2/hero1",id=10026,hero="y_yishandaohai_shenjiang1"}, ----东华帝君
|
|
|
|
[2]={name="Bg2/hero2",id=10033,hero="b_bianhuanmoce_shenjiang2"}, ---净光天女
|
|
|
|
[3]={name="Bg2/hero3",id=10091,hero="s_yongwangzhiqian_shenjiang33"}, ----白骨精
|
|
|
|
},
|
|
|
|
title = "s_yongwangzhiqian_zi_zh",
|
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
|
|
|
--勇冠三军 限时召唤
|
|
|
|
[4342] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
|
|
|
[1]={name="Bg2/hero1",id=10003,hero="d_danxinbixue_shenjiang1"}, --猪八戒
|
|
|
|
[2]={name="Bg2/hero2",id=10023,hero="x_xuanjimiaosuan_shenjiang2"}, --孙悟空
|
|
|
|
[3]={name="Bg2/hero3",id=10041,hero="x_xuanjimiaosuan_shenjiang3"}, --通天教主
|
|
|
|
},
|
|
|
|
title = "y_yunchouweiwo_zi_zh",
|
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
|
|
|
--勇冠三军 限时召唤
|
|
|
|
[4343] = {
|
|
|
|
bg = "Bg2",
|
|
|
|
hero = {
|
|
|
|
[1]={name="Bg2/hero1",id=10013,hero="y_yishandaohai_shenjiang2"}, ----吕洞宾
|
|
|
|
[2]={name="Bg2/hero2",id=10014,hero="c_ccfy_kuang01"}, --哪吒
|
|
|
|
[3]={name="Bg2/hero3",id=10033,hero="t_tianxiangjiren_shenjiang3"}, --净光天女
|
|
|
|
},
|
|
|
|
title = "y_yishandaohai_zi_zh",
|
|
|
|
helptype = HELP_TYPE.TimeLimitedCall
|
|
|
|
},
|
2020-09-24 17:26:27 +08:00
|
|
|
}
|
|
|
|
--type与lotterySetting表中的id对应
|
2021-04-09 12:26:35 +08:00
|
|
|
local btns={ [bType.Btn1]={name="btngroup/once",isInfo=Language[10478]}, [bType.Btn10]={name="btngroup/ten",isInfo=Language[10479]}}
|
2020-09-24 17:26:27 +08:00
|
|
|
local curLv = 0 --当前阶段id
|
2020-07-28 20:09:41 +08:00
|
|
|
local itemView
|
2020-06-28 17:48:49 +08:00
|
|
|
|
|
|
|
function TimeLimitedCall:ctor(mainPanel, gameObject)
|
|
|
|
self.mainPanel = mainPanel
|
|
|
|
self.gameObject = gameObject
|
|
|
|
self:InitComponent(gameObject)
|
|
|
|
self:BindEvent()
|
|
|
|
|
|
|
|
end
|
|
|
|
function TimeLimitedCall:InitComponent(gameObject)
|
2020-09-02 14:07:57 +08:00
|
|
|
self.helpBtn = Util.GetGameObject(self.gameObject,"help")
|
2020-06-28 17:48:49 +08:00
|
|
|
self.helpPosition=self.helpBtn:GetComponent("RectTransform").localPosition
|
2020-09-24 17:26:27 +08:00
|
|
|
|
2020-09-02 14:07:57 +08:00
|
|
|
self.activityBtn = Util.GetGameObject(self.gameObject,"activity")
|
2020-09-24 17:26:27 +08:00
|
|
|
self.rewardBtn = Util.GetGameObject(self.gameObject,"rewardBtn")
|
2020-08-03 20:01:59 +08:00
|
|
|
self.rewardBtn:SetActive(false)--(暂时关闭)
|
2020-09-24 17:26:27 +08:00
|
|
|
|
|
|
|
self.timeupdate=Util.GetGameObject(self.gameObject,"timeupdate"):GetComponent("Text") --免费次数剩余刷新时间
|
2020-07-14 11:34:40 +08:00
|
|
|
self.upper=Util.GetGameObject(self.gameObject,"maxtimes/times"):GetComponent("Text") ---召唤上限
|
2020-09-24 17:26:27 +08:00
|
|
|
|
|
|
|
self.getBtn=Util.GetGameObject(self.gameObject,"nextlevel")
|
|
|
|
self.slider = Util.GetGameObject(self.getBtn, "Slider"):GetComponent("Slider")
|
|
|
|
self.sliderText=Util.GetGameObject(self.getBtn,"Text"):GetComponent("Text")
|
|
|
|
self.nextReward = Util.GetGameObject(self.getBtn, "reward")
|
|
|
|
|
2020-06-28 17:48:49 +08:00
|
|
|
self.detail= Util.GetGameObject(self.gameObject, "detail")
|
2020-07-08 16:23:04 +08:00
|
|
|
self.detail.gameObject:SetActive(false)
|
2020-06-28 17:48:49 +08:00
|
|
|
self.reward= Util.GetGameObject(self.gameObject, "reward")
|
2020-07-08 16:23:04 +08:00
|
|
|
self.reward.gameObject:SetActive(false)
|
2020-06-28 17:48:49 +08:00
|
|
|
|
2020-09-24 17:26:27 +08:00
|
|
|
self.effect=Util.GetGameObject(self.nextReward,"juneng_chenggong")
|
2020-07-06 20:35:39 +08:00
|
|
|
|
2020-09-24 17:26:27 +08:00
|
|
|
self.recruitTimeUpdate = Util.GetGameObject(self.gameObject,"recruitTimesUpdate/Text1") :GetComponent("Text") --活动剩余时间
|
|
|
|
self.recruitTimesUpdate = Util.GetGameObject(self.gameObject,"recruitTimesUpdate/Text") :GetComponent("Text") --保底剩余次数
|
2021-02-25 16:12:46 +08:00
|
|
|
|
2021-02-25 17:31:26 +08:00
|
|
|
ForceRebuildLayout(Util.GetGameObject(self.gameObject,"Bg1/Image (7)").transform)
|
|
|
|
ForceRebuildLayout(Util.GetGameObject(self.gameObject,"Bg2/Image (7)").transform)
|
2021-02-25 16:12:46 +08:00
|
|
|
|
2020-06-28 17:48:49 +08:00
|
|
|
end
|
|
|
|
|
|
|
|
function TimeLimitedCall:BindEvent()
|
2020-09-24 17:26:27 +08:00
|
|
|
|
2020-06-28 17:48:49 +08:00
|
|
|
Util.AddClick(self.helpBtn, function()
|
2020-09-24 17:26:27 +08:00
|
|
|
UIManager.OpenPanel(UIName.HelpPopup,activityType[activityId].helptype,self.helpPosition.x,self.helpPosition.y)
|
2020-06-28 17:48:49 +08:00
|
|
|
end)
|
|
|
|
Util.AddClick(self.activityBtn, function()
|
2020-07-08 16:19:46 +08:00
|
|
|
ActivityDetail.new(self.detail,1)
|
2020-06-28 17:48:49 +08:00
|
|
|
end)
|
|
|
|
|
2020-09-24 17:26:27 +08:00
|
|
|
Util.AddClick(self.rewardBtn, function()
|
2020-06-28 17:48:49 +08:00
|
|
|
local fb = ConfigManager.GetConfigData(ConfigName.FakeBattle, 1001)
|
|
|
|
local testFightData = {
|
|
|
|
fightData = loadstring("return "..fb.FightData)(),
|
|
|
|
fightSeed = fb.TimeSeed,
|
|
|
|
fightType = 0,
|
|
|
|
maxRound = 20
|
|
|
|
}
|
|
|
|
UIManager.OpenPanel(UIName.BattlePanel, testFightData, BATTLE_TYPE.Test)
|
|
|
|
end)
|
|
|
|
end
|
|
|
|
|
2021-01-26 17:08:39 +08:00
|
|
|
local actTypePos = {
|
|
|
|
[1] = Vector3.New(117,49,0),
|
|
|
|
[2] = Vector3.New(91,79,0),
|
|
|
|
[3] = Vector3.New(104,49,0),
|
|
|
|
}
|
|
|
|
|
2020-09-24 17:26:27 +08:00
|
|
|
function TimeLimitedCall:OnShow(_sortingOrder,_parent)
|
|
|
|
parent = _parent
|
2020-06-28 17:48:49 +08:00
|
|
|
sortingOrder = _sortingOrder
|
|
|
|
self.gameObject:SetActive(true)
|
2020-09-24 17:26:27 +08:00
|
|
|
|
|
|
|
for n,m in pairs(activityType) do
|
|
|
|
Util.GetGameObject(self.gameObject,m.bg):SetActive(false)
|
|
|
|
end
|
|
|
|
|
|
|
|
activityId = ActivityGiftManager.IsActivityTypeOpen(ActivityTypeDef.FindFairy)
|
2021-01-14 14:22:32 +08:00
|
|
|
if not activityId or activityId <= 0 then return end
|
2020-10-15 11:06:45 +08:00
|
|
|
LogBlue("限时招募 activityId:"..activityId)
|
2020-09-24 17:26:27 +08:00
|
|
|
Util.GetGameObject(self.gameObject,activityType[activityId].bg):SetActive(true)
|
|
|
|
Util.GetGameObject(self.gameObject,activityType[activityId].bg.."/Image (3)"):GetComponent("Image").sprite = Util.LoadSprite(activityType[activityId].title)
|
|
|
|
local array = ConfigManager.GetAllConfigsDataByKey(ConfigName.LotterySetting,"ActivityId",activityId)
|
|
|
|
singleRecruit = array[1]
|
|
|
|
tenRecruit = array[2]
|
|
|
|
|
|
|
|
local UpHero = RecruitManager.GetRewardPreviewData(PRE_REWARD_POOL_TYPE.TIME_LIMITED_UP)
|
|
|
|
table.sort(UpHero,function(a,b) return a.Reward[1] < b.Reward[1] end)
|
|
|
|
for n,m in ipairs(activityType[activityId].hero) do
|
2021-01-26 17:08:39 +08:00
|
|
|
local tempGo = Util.GetGameObject(self.gameObject,m.name)
|
2021-03-12 12:08:24 +08:00
|
|
|
local ima = Util.GetGameObject(tempGo,"hero"):GetComponent("Image")
|
|
|
|
ima.sprite=Util.LoadSprite(m.hero)
|
2020-09-24 17:26:27 +08:00
|
|
|
local configinfo= ConfigManager.GetConfigDataByKey(ConfigName.HeroConfig, "Id", m.id)
|
|
|
|
--LogGreen("configinfo.PropertyName:"..configinfo.PropertyName)
|
2021-01-26 17:08:39 +08:00
|
|
|
Util.GetGameObject(tempGo,"icon"):GetComponent("Image").sprite=Util.LoadSprite(GetJobSpriteStrByJobNum(configinfo.PropertyName))
|
2021-01-29 11:15:36 +08:00
|
|
|
if GetCurLanguage() ~= 0 and LengthString(GetLanguageStrById(GetLanguageStrById(configinfo.ReadingName))) > 6 then
|
|
|
|
Util.GetGameObject(tempGo,"name"):GetComponent("Text").text = SubString(GetLanguageStrById(GetLanguageStrById(configinfo.ReadingName)),5).."..."
|
2021-01-29 14:36:50 +08:00
|
|
|
else
|
|
|
|
Util.GetGameObject(tempGo,"name"):GetComponent("Text").text=GetLanguageStrById(GetLanguageStrById(configinfo.ReadingName))
|
2021-01-29 11:15:36 +08:00
|
|
|
end
|
2021-01-26 17:08:39 +08:00
|
|
|
if activityType[activityId].bg == "Bg1" then
|
|
|
|
SetTextVerTial(Util.GetGameObject(tempGo,"name"),actTypePos[n],"MiddleLeft",1)
|
|
|
|
end
|
2020-09-24 17:26:27 +08:00
|
|
|
Util.AddOnceClick(Util.GetGameObject(self.gameObject,m.name), function()
|
|
|
|
UIManager.OpenPanel(UIName.RoleGetInfoPopup, false, m.id, 5)
|
|
|
|
end)
|
2020-06-28 17:48:49 +08:00
|
|
|
end
|
|
|
|
|
2021-01-26 17:08:39 +08:00
|
|
|
|
|
|
|
|
2020-06-28 17:48:49 +08:00
|
|
|
self:RefreshGetHeroTimes()
|
|
|
|
self:TimeCountDown()
|
|
|
|
self:RefreshNextLevelReward()
|
|
|
|
end
|
|
|
|
|
|
|
|
function TimeLimitedCall:RefreshNextLevelReward()
|
2020-07-07 16:35:57 +08:00
|
|
|
local curLvstate = 0
|
2020-09-24 17:26:27 +08:00
|
|
|
local info= ActivityGiftManager.GetActivityTypeInfo(ActivityTypeDef.FindFairy)
|
2020-07-07 16:35:57 +08:00
|
|
|
local curTimes = 0
|
2020-09-24 17:26:27 +08:00
|
|
|
local data1 = ConfigManager.GetAllConfigsDataByKey(ConfigName.ActivityRewardConfig,"ActivityId",activityId) --通过活动id获取阶段任务
|
2020-06-28 17:48:49 +08:00
|
|
|
local rewarditem
|
|
|
|
for n,m in ipairs(data1) do
|
2020-09-24 17:26:27 +08:00
|
|
|
curTimes,curLvstate = self:GetMissionStateById(m.Id,activityId)
|
2020-07-06 20:35:39 +08:00
|
|
|
if(curTimes>=m.Values[1][1]) then
|
2020-06-28 17:48:49 +08:00
|
|
|
if curLvstate==0 then
|
|
|
|
curLvstate=0
|
|
|
|
curLv=m.Id
|
|
|
|
rewarditem=m
|
|
|
|
break
|
|
|
|
end
|
|
|
|
else
|
|
|
|
curLvstate=2
|
|
|
|
curLv=m.Id
|
|
|
|
rewarditem=m
|
|
|
|
break
|
|
|
|
end
|
|
|
|
end
|
2020-07-08 19:16:04 +08:00
|
|
|
--所有任务都已完成
|
|
|
|
if not rewarditem then
|
|
|
|
curLvstate = -1
|
|
|
|
rewarditem = data1[#data1]
|
|
|
|
curLv=data1[#data1].Id
|
|
|
|
end
|
2020-07-09 10:04:20 +08:00
|
|
|
OperatingManager.TimeLimitedTimes = curTimes
|
2020-07-28 20:09:41 +08:00
|
|
|
if not itemView then
|
|
|
|
itemView= SubUIManager.Open(SubUIConfig.ItemView,self.nextReward.transform)
|
|
|
|
end
|
|
|
|
itemView:OnOpen(false, {rewarditem.Reward[1][1],rewarditem.Reward[1][2]}, 0.73, false)
|
|
|
|
itemView.gameObject:SetActive(true)
|
|
|
|
Util.GetGameObject(itemView.gameObject,"item/frame"):GetComponent("Button").enabled=false
|
2020-06-28 17:48:49 +08:00
|
|
|
if (curLvstate==0) then
|
2020-07-28 20:09:41 +08:00
|
|
|
-- self.slider.gameObject:SetActive(false)\
|
|
|
|
local temp = curTimes <= rewarditem.Values[1][1] and curTimes or rewarditem.Values[1][1]
|
|
|
|
Util.GetGameObject(self.slider.gameObject,"Text"):GetComponent("Text").text=temp.."/"..rewarditem.Values[1][1]
|
|
|
|
self.slider.value=temp /rewarditem.Values[1][1]
|
2020-06-28 17:48:49 +08:00
|
|
|
local vec=self.sliderText.transform:GetComponent("RectTransform").anchoredPosition3D
|
2020-06-30 18:59:44 +08:00
|
|
|
vec.y=22.4
|
2020-06-28 17:48:49 +08:00
|
|
|
self.sliderText.transform:GetComponent("RectTransform").anchoredPosition3D=vec
|
2021-04-09 12:26:35 +08:00
|
|
|
self.sliderText.text=Language[10507]
|
2020-06-30 18:59:44 +08:00
|
|
|
self.sliderText.fontSize=26
|
2020-06-28 17:48:49 +08:00
|
|
|
Util.AddOnceClick(self.getBtn,function()
|
2020-09-24 17:26:27 +08:00
|
|
|
NetManager.GetActivityRewardRequest(curLv, activityId,
|
2020-06-28 17:48:49 +08:00
|
|
|
function(respond)
|
|
|
|
UIManager.OpenPanel(UIName.RewardItemPopup, respond, 1)
|
|
|
|
self:RefreshNextLevelReward()
|
|
|
|
self:RefreshGetHeroTimes()
|
|
|
|
end)
|
|
|
|
end)
|
|
|
|
self.effect.gameObject:SetActive(true)
|
2020-07-08 19:16:04 +08:00
|
|
|
elseif (curLvstate==-1) then
|
2020-07-28 20:09:41 +08:00
|
|
|
self.slider.value=1
|
|
|
|
Util.GetGameObject(self.slider.gameObject,"Text"):GetComponent("Text").text="300/300"
|
2021-04-09 12:26:35 +08:00
|
|
|
self.sliderText.text=Language[10509]
|
2020-07-08 19:16:04 +08:00
|
|
|
Util.AddOnceClick(self.getBtn,function()
|
|
|
|
RewardPreview.new(self.reward)
|
|
|
|
end)
|
2020-06-28 17:48:49 +08:00
|
|
|
else
|
|
|
|
self.slider.gameObject:SetActive(true)
|
2020-06-30 18:59:44 +08:00
|
|
|
Util.GetGameObject(self.slider.gameObject,"Text"):GetComponent("Text").text=curTimes.."/"..rewarditem.Values[1][1]
|
2020-06-28 17:48:49 +08:00
|
|
|
local vec=self.sliderText.transform:GetComponent("RectTransform").anchoredPosition3D
|
2020-06-30 18:59:44 +08:00
|
|
|
vec.y=22.4
|
2020-09-24 17:26:27 +08:00
|
|
|
self.sliderText.transform:GetComponent("RectTransform").anchoredPosition3D = vec
|
2021-04-09 12:26:35 +08:00
|
|
|
self.sliderText.text=Language[10510]..curTimes.."/"..rewarditem.Values[1][1]
|
2020-06-30 18:59:44 +08:00
|
|
|
self.sliderText.fontSize=26
|
2020-06-28 17:48:49 +08:00
|
|
|
self.slider.value=curTimes/rewarditem.Values[1][1]
|
|
|
|
self.effect.gameObject:SetActive(false)
|
|
|
|
Util.AddOnceClick(self.getBtn,function()
|
|
|
|
RewardPreview.new(self.reward)
|
|
|
|
end)
|
|
|
|
end
|
2020-07-08 16:19:46 +08:00
|
|
|
|
2020-09-24 17:26:27 +08:00
|
|
|
|
|
|
|
|
|
|
|
local reMaintimes = info.value
|
|
|
|
--LogBlue("reMaintimes:"..reMaintimes)
|
|
|
|
--LogGreen("singleRecruit.MergePool:"..singleRecruit.MergePool)
|
|
|
|
local totalTimes = ConfigManager.GetConfigDataByKey(ConfigName.LotterySpecialConfig,"Type",singleRecruit.MergePool).Count
|
|
|
|
reMaintimes = totalTimes - reMaintimes
|
2020-07-13 11:15:53 +08:00
|
|
|
if reMaintimes == 0 then
|
2020-09-24 17:26:27 +08:00
|
|
|
reMaintimes = totalTimes
|
2020-07-13 11:15:53 +08:00
|
|
|
end
|
2020-09-24 17:26:27 +08:00
|
|
|
|
2021-04-09 12:26:35 +08:00
|
|
|
self.recruitTimesUpdate.text = string.format(Language[10511],reMaintimes)
|
2020-07-08 16:19:46 +08:00
|
|
|
|
2020-10-21 23:18:39 +08:00
|
|
|
local timeDown = info.endTime - PlayerManager.serverTime
|
2021-04-09 12:26:35 +08:00
|
|
|
self.recruitTimeUpdate.text = string.format(Language[10512]..self:TimeToDHMS(timeDown))
|
2020-12-28 11:53:07 +08:00
|
|
|
if self.recruitTime then
|
|
|
|
self.recruitTime:Stop()
|
|
|
|
self.recruitTime = nil
|
|
|
|
end
|
|
|
|
self.recruitTime = Timer.New(function()
|
2020-10-21 23:18:39 +08:00
|
|
|
if timeDown < 1 then
|
2021-04-09 12:26:35 +08:00
|
|
|
self.recruitTimeUpdate.text = string.format(Language[10512]..self:TimeToDHMS(0))
|
2020-10-21 23:18:39 +08:00
|
|
|
else
|
|
|
|
timeDown = timeDown - 1
|
2021-04-09 12:26:35 +08:00
|
|
|
self.recruitTimeUpdate.text = string.format(Language[10512]..self:TimeToDHMS(timeDown))
|
2020-10-21 23:18:39 +08:00
|
|
|
end
|
2020-12-28 11:53:07 +08:00
|
|
|
end, 1, -1, true)
|
2021-01-26 17:08:39 +08:00
|
|
|
self.recruitTime:Start()
|
2020-07-08 16:19:46 +08:00
|
|
|
end
|
|
|
|
--- 将一段时间转换为天时分秒
|
|
|
|
function TimeLimitedCall:TimeToDHMS(second)
|
|
|
|
local day = math.floor(second / (24 * 3600))
|
|
|
|
local minute = math.floor(second / 60) % 60
|
2020-10-21 23:18:39 +08:00
|
|
|
local sec = math.floor(second % 60)
|
2020-07-08 16:19:46 +08:00
|
|
|
local hour = math.floor(math.floor(second - day * 24 * 3600 - sec - minute * 60) / 3600)
|
|
|
|
if day <= 0 and hour <= 0 then
|
2021-04-09 12:26:35 +08:00
|
|
|
return string.format(Language[10472],minute, sec)
|
2020-07-08 16:19:46 +08:00
|
|
|
else
|
2021-04-09 12:26:35 +08:00
|
|
|
return string.format(Language[10473],day, hour)
|
2020-07-08 16:19:46 +08:00
|
|
|
end
|
2020-06-28 17:48:49 +08:00
|
|
|
end
|
|
|
|
|
|
|
|
function TimeLimitedCall:GetMissionStateById(num,activityId)
|
|
|
|
local mission= ActivityGiftManager.GetActivityInfo(activityId,num) --从后端获取到的阶段数据
|
2020-07-06 20:35:39 +08:00
|
|
|
return mission.progress,mission.state
|
2020-06-28 17:48:49 +08:00
|
|
|
end
|
|
|
|
|
|
|
|
--刷新剩余次数
|
|
|
|
function TimeLimitedCall:RefreshGetHeroTimes()
|
2020-09-24 17:26:27 +08:00
|
|
|
local freeTimesId=lotterySetting[singleRecruit.Id].FreeTimes
|
|
|
|
local maxtimesId=lotterySetting[singleRecruit.Id].MaxTimes --lotterySetting表中的MaxTimes对应privilegeConfig表中的id
|
2020-07-06 20:35:39 +08:00
|
|
|
local curTimes=PrivilegeManager.GetPrivilegeUsedTimes(maxtimesId)
|
2021-04-09 12:26:35 +08:00
|
|
|
self.upper.text= Language[10483]..curTimes.."/"..privilegeConfig[maxtimesId].Condition[1][2]--特权上限
|
2020-07-20 10:02:12 +08:00
|
|
|
self.timeupdate.gameObject:SetActive(true)
|
2020-06-28 17:48:49 +08:00
|
|
|
local freeTime= 0
|
|
|
|
if freeTimesId>0 then
|
2020-07-13 11:15:53 +08:00
|
|
|
freeTime = PrivilegeManager.GetPrivilegeRemainValue(freeTimesId)
|
2020-06-28 17:48:49 +08:00
|
|
|
RecruitManager.freeUseTimeList[freeTimesId]=freeTime
|
|
|
|
end
|
|
|
|
--按钮赋值
|
|
|
|
for n, m in ipairs(btns) do
|
|
|
|
local btn=Util.GetGameObject(self.gameObject,m.name)
|
|
|
|
local redPot=Util.GetGameObject(btn.gameObject,"redPoint")
|
|
|
|
local info=Util.GetGameObject(btn.gameObject,"layout/Text"):GetComponent("Text")
|
|
|
|
local icon=Util.GetGameObject(btn.gameObject,"layout/icon"):GetComponent("Image")
|
|
|
|
local num=Util.GetGameObject(btn.gameObject,"layout/num"):GetComponent("Text")
|
|
|
|
|
|
|
|
--存在免费次数 并且 免费>=1 并且是1按钮
|
|
|
|
local isFree=freeTime and freeTime >= 1 and n==bType.Btn1
|
|
|
|
redPot.gameObject:SetActive(isFree)
|
|
|
|
icon.gameObject:SetActive(not isFree)
|
|
|
|
num.gameObject:SetActive(not isFree)
|
2020-07-20 10:02:12 +08:00
|
|
|
if n==bType.Btn1 and isFree then
|
|
|
|
self.timeupdate.gameObject:SetActive(false)
|
|
|
|
end
|
2020-06-28 17:48:49 +08:00
|
|
|
|
|
|
|
local itemId=0
|
|
|
|
local itemNum=0
|
2020-09-24 17:26:27 +08:00
|
|
|
local type = 0
|
|
|
|
if n==bType.Btn1 then
|
|
|
|
type = singleRecruit.Id
|
|
|
|
else
|
|
|
|
type = tenRecruit.Id
|
|
|
|
end
|
|
|
|
local d=RecruitManager.GetExpendData(type)
|
2020-06-28 17:48:49 +08:00
|
|
|
if(isFree) then
|
2021-04-09 12:26:35 +08:00
|
|
|
info.text=Language[10493]
|
2020-07-14 11:34:40 +08:00
|
|
|
else
|
2020-06-28 17:48:49 +08:00
|
|
|
itemId=d[1]
|
|
|
|
itemNum=d[2]
|
|
|
|
icon.sprite=Util.LoadSprite(artResourcesConfig[itemConfig[itemId].ResourceID].Name)
|
|
|
|
info.text=m.isInfo
|
2020-06-30 18:59:44 +08:00
|
|
|
num.text= tostring(itemNum)
|
2020-06-28 17:48:49 +08:00
|
|
|
end
|
|
|
|
|
|
|
|
Util.AddOnceClick(btn,function()
|
|
|
|
if not isFree then
|
|
|
|
if BagManager.GetItemCountById(itemId)<d[2] then
|
2021-04-09 12:26:35 +08:00
|
|
|
PopupTipPanel.ShowTip(GetLanguageStrById(itemConfig[itemId].Name)..Language[10486])
|
2020-06-28 17:48:49 +08:00
|
|
|
return
|
|
|
|
end
|
|
|
|
end
|
2020-07-28 15:24:11 +08:00
|
|
|
local state = PlayerPrefs.GetInt(PlayerManager.uid.."GeneralPopup_RecruitConfirm"..RecruitType.TimeLimitTen)
|
2020-06-28 17:48:49 +08:00
|
|
|
if n==bType.Btn1 then
|
|
|
|
if PrivilegeManager.GetPrivilegeUsedTimes(maxtimesId)+1>privilegeConfig[maxtimesId].Condition[1][2] then
|
2021-04-09 12:26:35 +08:00
|
|
|
PopupTipPanel.ShowTip(Language[10485])
|
2020-06-28 17:48:49 +08:00
|
|
|
return
|
|
|
|
end
|
2020-07-28 15:24:11 +08:00
|
|
|
local recruitOne = function()
|
2020-09-24 17:26:27 +08:00
|
|
|
RecruitManager.RecruitRequest(singleRecruit.Id, function(msg)
|
2020-07-28 15:24:11 +08:00
|
|
|
PrivilegeManager.RefreshPrivilegeUsedTimes(maxtimesId,1)--记录抽卡次数
|
2020-12-29 14:24:45 +08:00
|
|
|
UIManager.OpenPanel(UIName.SingleRecruitPanel, msg.drop.Hero[1],singleRecruit.Id,bType.Btn1,{RecruitType.TimeLimitSingle,RecruitType.TimeLimitTen})
|
2020-07-28 15:24:11 +08:00
|
|
|
CheckRedPointStatus(RedPointType.TimeLimited)
|
|
|
|
end,freeTimesId)
|
|
|
|
end
|
2020-09-24 17:26:27 +08:00
|
|
|
if state==0 and d[1] == 16 and not isFree then
|
|
|
|
UIManager.OpenPanel(UIName.GeneralPopup,GENERAL_POPUP_TYPE.RecruitConfirm,singleRecruit.Id,recruitOne)
|
2020-07-28 15:24:11 +08:00
|
|
|
else
|
|
|
|
recruitOne()
|
|
|
|
end
|
|
|
|
|
2020-06-28 17:48:49 +08:00
|
|
|
elseif n==bType.Btn10 then
|
|
|
|
if PrivilegeManager.GetPrivilegeUsedTimes(maxtimesId)+10>privilegeConfig[maxtimesId].Condition[1][2] then
|
2021-04-09 12:26:35 +08:00
|
|
|
PopupTipPanel.ShowTip(Language[10485])
|
2020-06-28 17:48:49 +08:00
|
|
|
return
|
|
|
|
end
|
2020-07-28 15:24:11 +08:00
|
|
|
local recruitTen = function()
|
2020-12-29 14:24:45 +08:00
|
|
|
RecruitManager.RecruitRequest(tenRecruit.Id, function(msg)
|
|
|
|
PrivilegeManager.RefreshPrivilegeUsedTimes(maxtimesId,10)--记录抽卡次数
|
|
|
|
UIManager.OpenPanel(UIName.SingleRecruitPanel, msg.drop.Hero, tenRecruit.Id,bType.Btn10,{RecruitType.TimeLimitTen,RecruitType.TimeLimitTen})
|
2020-07-28 15:24:11 +08:00
|
|
|
CheckRedPointStatus(RedPointType.TimeLimited)
|
|
|
|
end,freeTimesId)
|
|
|
|
end
|
2020-07-28 17:25:50 +08:00
|
|
|
if state==0 and d[1] ==16 and not isFree then
|
2020-09-24 17:26:27 +08:00
|
|
|
UIManager.OpenPanel(UIName.GeneralPopup,GENERAL_POPUP_TYPE.RecruitConfirm,tenRecruit.Id,recruitTen)
|
2020-07-28 15:24:11 +08:00
|
|
|
else
|
|
|
|
recruitTen()
|
|
|
|
end
|
2020-06-28 17:48:49 +08:00
|
|
|
end
|
|
|
|
end)
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
--刷新时间
|
|
|
|
function TimeLimitedCall:TimeCountDown()
|
|
|
|
if self.timer then
|
|
|
|
self.timer:Stop()
|
|
|
|
self.timer = nil
|
|
|
|
end
|
2021-01-04 14:27:18 +08:00
|
|
|
local timeDown=CalculateSecondsNowTo_N_OClock(0)--ActivityGiftManager.GetTaskRemainTime(ActivityTypeDef.FindFairy)
|
2021-04-09 12:26:35 +08:00
|
|
|
self.timeupdate.text = TimeToHMS(timeDown)..Language[10488]
|
2020-06-28 17:48:49 +08:00
|
|
|
self.timer = Timer.New(function()
|
|
|
|
if timeDown < 1 then
|
|
|
|
self.timer:Stop()
|
|
|
|
self.timer = nil
|
2020-09-24 17:26:27 +08:00
|
|
|
parent:ClosePanel()
|
2020-06-28 17:48:49 +08:00
|
|
|
return
|
|
|
|
end
|
|
|
|
timeDown = timeDown - 1
|
2021-04-09 12:26:35 +08:00
|
|
|
self.timeupdate.text = TimeToHMS(timeDown)..Language[10488]
|
2020-06-28 17:48:49 +08:00
|
|
|
end, 1, -1, true)
|
|
|
|
self.timer:Start()
|
|
|
|
end
|
|
|
|
|
|
|
|
function TimeLimitedCall:OnHide()
|
|
|
|
self.gameObject:SetActive(false)
|
2020-07-08 16:23:04 +08:00
|
|
|
self.detail.gameObject:SetActive(false)
|
|
|
|
self.reward.gameObject:SetActive(false)
|
2020-06-28 17:48:49 +08:00
|
|
|
if self.timer then
|
|
|
|
self.timer:Stop()
|
|
|
|
self.timer = nil
|
|
|
|
end
|
2020-12-28 11:53:07 +08:00
|
|
|
if self.recruitTime then
|
|
|
|
self.recruitTime:Stop()
|
|
|
|
self.recruitTime = nil
|
|
|
|
end
|
2020-06-28 17:48:49 +08:00
|
|
|
end
|
|
|
|
|
|
|
|
function TimeLimitedCall:OnDestroy()
|
|
|
|
ActivityDetail.OnDestroy()
|
|
|
|
RewardPreview.OnDestroy()
|
2020-08-25 19:48:14 +08:00
|
|
|
if itemView then
|
|
|
|
SubUIManager.Close(itemView)
|
|
|
|
itemView=nil
|
|
|
|
end
|
2020-06-28 17:48:49 +08:00
|
|
|
end
|
|
|
|
|
2020-09-24 17:26:27 +08:00
|
|
|
--添加事件监听(用于子类重写)
|
|
|
|
function TimeLimitedCall:AddListener()
|
|
|
|
|
|
|
|
end
|
|
|
|
|
|
|
|
--移除事件监听(用于子类重写)
|
|
|
|
function TimeLimitedCall:RemoveListener()
|
|
|
|
|
|
|
|
end
|
|
|
|
|
2020-06-28 17:48:49 +08:00
|
|
|
return TimeLimitedCall
|