tcx_xiyou_yueNan
parent
99c4362cc0
commit
91bee0a9e0
|
|
@ -114,6 +114,7 @@ end
|
||||||
|
|
||||||
--界面打开时调用(用于子类重写)
|
--界面打开时调用(用于子类重写)
|
||||||
function ActivityMainPanel:OnOpen(_activityType, _index, change)
|
function ActivityMainPanel:OnOpen(_activityType, _index, change)
|
||||||
|
LogError("huodong:".._activityType)
|
||||||
SoundManager.PlaySound(SoundConfig.UI_Hddakai)
|
SoundManager.PlaySound(SoundConfig.UI_Hddakai)
|
||||||
this.activityType = _activityType
|
this.activityType = _activityType
|
||||||
DynamicActivityManager.curActivityType = this.activityType
|
DynamicActivityManager.curActivityType = this.activityType
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
GuideManager = {}
|
GuideManager = {}
|
||||||
local this = GuideManager
|
local this = GuideManager
|
||||||
local GuideConfig = ConfigManager.GetConfig(ConfigName.GuideConfig)
|
local GuideConfig = ConfigManager.GetConfig(ConfigName.GuideConfig)
|
||||||
local GlobalSystemConfig = ConfigManager.GetConfig(ConfigName.GlobalSystemConfig)
|
local GlobalSystemConfig = ConfigManager.GetConfig(ConfigName.GlobalSystemConfig)
|
||||||
|
|
|
||||||
|
|
@ -208,6 +208,7 @@ function this.TrackCreateAccount()
|
||||||
-- packId = PackageManager.GetPackageID() or "",
|
-- packId = PackageManager.GetPackageID() or "",
|
||||||
-- })
|
-- })
|
||||||
-- ThinkingAnalyticsManager.Track("create_account")
|
-- ThinkingAnalyticsManager.Track("create_account")
|
||||||
|
SubmitExtraData({ type = SDKSubMitType.TYPE_CUSTOM, roleLevelUpTime = "NRU_unique" })
|
||||||
end
|
end
|
||||||
|
|
||||||
function this.SaveLoginInfo(user, pw)
|
function this.SaveLoginInfo(user, pw)
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
require("Base/BasePanel")
|
require("Base/BasePanel")
|
||||||
require("Modules/Main/View/MainPlayerView")
|
require("Modules/Main/View/MainPlayerView")
|
||||||
local floor = math.floor
|
local floor = math.floor
|
||||||
MainPanel = Inherit(BasePanel)
|
MainPanel = Inherit(BasePanel)
|
||||||
|
|
@ -35,6 +35,8 @@ local isUpperMonthCardTimeShow = true
|
||||||
local activitys = {}
|
local activitys = {}
|
||||||
local activityTabs = {}
|
local activityTabs = {}
|
||||||
local activeSelfTabs = {}
|
local activeSelfTabs = {}
|
||||||
|
local tenmini = false
|
||||||
|
local initTime = 0
|
||||||
local moveSceneList = {
|
local moveSceneList = {
|
||||||
[1] = 0,
|
[1] = 0,
|
||||||
[2] = 0.02,
|
[2] = 0.02,
|
||||||
|
|
@ -65,6 +67,7 @@ local curNPCList = {}
|
||||||
local addUpDateNum = 0 --UpDate计数器
|
local addUpDateNum = 0 --UpDate计数器
|
||||||
--初始化组件(用于子类重写)
|
--初始化组件(用于子类重写)
|
||||||
function this:InitComponent()
|
function this:InitComponent()
|
||||||
|
this.initTime = PlayerManager.serverTime
|
||||||
this.spLoader = SpriteLoader.New()
|
this.spLoader = SpriteLoader.New()
|
||||||
orginLayer = 0
|
orginLayer = 0
|
||||||
self.bg = Util.GetGameObject(self.gameObject, "bg")
|
self.bg = Util.GetGameObject(self.gameObject, "bg")
|
||||||
|
|
@ -139,6 +142,7 @@ function this:InitComponent()
|
||||||
|
|
||||||
--鸿蒙
|
--鸿蒙
|
||||||
this.btnHongMeng = Util.GetGameObject(self.gameObject, "RightDown/btnHongMeng")
|
this.btnHongMeng = Util.GetGameObject(self.gameObject, "RightDown/btnHongMeng")
|
||||||
|
this.btnDiaoyan = Util.GetGameObject(self.gameObject, "RightDown/btnDiaoyan")
|
||||||
--this.btnHongMeng:SetActive(false)
|
--this.btnHongMeng:SetActive(false)
|
||||||
this.HongMengRedPoint = Util.GetGameObject(this.btnHongMeng, "redPoint")
|
this.HongMengRedPoint = Util.GetGameObject(this.btnHongMeng, "redPoint")
|
||||||
|
|
||||||
|
|
@ -343,6 +347,35 @@ function this:InitComponent()
|
||||||
-- if SERVER_VERSION == 1 or LoginRoot_Channel == "XP" or LoginRoot_Channel == "DY" then
|
-- if SERVER_VERSION == 1 or LoginRoot_Channel == "XP" or LoginRoot_Channel == "DY" then
|
||||||
-- this.taiChuMiJuanBtn:SetActive(false)
|
-- this.taiChuMiJuanBtn:SetActive(false)
|
||||||
-- end
|
-- end
|
||||||
|
if PlayerPrefs.HasKey("day0") then
|
||||||
|
local day0 = PlayerPrefs.GetInt("day0")
|
||||||
|
local day = math.floor(PlayerManager.serverTime / (24 * 3600))
|
||||||
|
if day - day0 == 1 and PlayerPrefs.HasKey("day1") ~= true then
|
||||||
|
PlayerPrefs.SetInt("day1", day)
|
||||||
|
SubmitExtraData({
|
||||||
|
type = SDKSubMitType.TYPE_CUSTOM,
|
||||||
|
roleLevelUpTime =
|
||||||
|
"rr1"
|
||||||
|
})
|
||||||
|
elseif day - day0 == 3 and PlayerPrefs.HasKey("day3") ~= true then
|
||||||
|
PlayerPrefs.SetInt("day3", day)
|
||||||
|
SubmitExtraData({
|
||||||
|
type = SDKSubMitType.TYPE_CUSTOM,
|
||||||
|
roleLevelUpTime =
|
||||||
|
"rr3"
|
||||||
|
})
|
||||||
|
elseif day - day0 == 7 and PlayerPrefs.HasKey("day7") ~= true then
|
||||||
|
PlayerPrefs.SetInt("day7", day)
|
||||||
|
SubmitExtraData({
|
||||||
|
type = SDKSubMitType.TYPE_CUSTOM,
|
||||||
|
roleLevelUpTime =
|
||||||
|
"rr7"
|
||||||
|
})
|
||||||
|
end
|
||||||
|
else
|
||||||
|
local day = math.floor(PlayerManager.serverTime / (24 * 3600))
|
||||||
|
PlayerPrefs.SetInt("day0", day)
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
function this:SetPosFunc(v2)
|
function this:SetPosFunc(v2)
|
||||||
|
|
@ -502,6 +535,10 @@ function this:BindEvent()
|
||||||
Util.AddClick(this.FestevaBtn, function()
|
Util.AddClick(this.FestevaBtn, function()
|
||||||
UIManager.OpenPanel(UIName.FestevalPanel)
|
UIManager.OpenPanel(UIName.FestevalPanel)
|
||||||
end)
|
end)
|
||||||
|
--调研
|
||||||
|
Util.AddClick(this.btnDiaoyan, function()
|
||||||
|
OpenWeb("http://wwww.baidu.com")
|
||||||
|
end)
|
||||||
--十五日登录奖励
|
--十五日登录奖励
|
||||||
Util.AddClick(this.fgBtn, function()
|
Util.AddClick(this.fgBtn, function()
|
||||||
UIManager.OpenPanel(UIName.FifteenDayGiftPanel)
|
UIManager.OpenPanel(UIName.FifteenDayGiftPanel)
|
||||||
|
|
@ -1478,6 +1515,10 @@ function this.OnUpdate()
|
||||||
--主城人物层级处理
|
--主城人物层级处理
|
||||||
this.OnMainPlayerNPCRefresh()
|
this.OnMainPlayerNPCRefresh()
|
||||||
this.CheckScreenRightRedPoint()
|
this.CheckScreenRightRedPoint()
|
||||||
|
if tenmini == false and ((PlayerManager.serverTime - initTime)>600) then
|
||||||
|
tenmini = true
|
||||||
|
SubmitExtraData({ type = SDKSubMitType.TYPE_CUSTOM, roleLevelUpTime = "ten_minutes" })
|
||||||
|
end
|
||||||
local date = os.date("!*t", GetTimeStamp() + 25200)
|
local date = os.date("!*t", GetTimeStamp() + 25200)
|
||||||
this.utcTimeText.text = string.format(" %02d:%02d", date.hour, date.min) .. "(UTC+7)"
|
this.utcTimeText.text = string.format(" %02d:%02d", date.hour, date.min) .. "(UTC+7)"
|
||||||
end
|
end
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
--[[
|
--[[
|
||||||
* @ClassName PayManager
|
* @ClassName PayManager
|
||||||
* @Description 支付管理系统
|
* @Description 支付管理系统
|
||||||
* @Date 2019/6/25 20:14
|
* @Date 2019/6/25 20:14
|
||||||
|
|
@ -48,8 +48,9 @@ function this.Pay(id, func)
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
LogRed("发起购买商品的请求,商品id = " .. id)
|
LogRed("发起购买商品的请求,商品id = " .. id)
|
||||||
if not func then
|
if PlayerPrefs.HasKey("rechargeuniuq") ~= true then
|
||||||
func = function() end
|
PlayerPrefs.SetInt("rechargeuniuq", 0)
|
||||||
|
SubmitExtraData({ type = SDKSubMitType.TYPE_CUSTOM, roleLevelUpTime = "click_recharge_package_unique" })
|
||||||
end
|
end
|
||||||
|
|
||||||
-- 请求游戏服务器的orderId
|
-- 请求游戏服务器的orderId
|
||||||
|
|
@ -78,6 +79,7 @@ function this.Pay(id, func)
|
||||||
roleCreateTime = "" .. id,
|
roleCreateTime = "" .. id,
|
||||||
roleLevelUpTime = rechargeConfig.RechargeId
|
roleLevelUpTime = rechargeConfig.RechargeId
|
||||||
})
|
})
|
||||||
|
VipManager.GetChargedNum()
|
||||||
end
|
end
|
||||||
--[[
|
--[[
|
||||||
local cancelFunc = function()
|
local cancelFunc = function()
|
||||||
|
|
@ -200,7 +202,18 @@ function this.RequestPay(context)
|
||||||
local result = tonumber(str[1])
|
local result = tonumber(str[1])
|
||||||
-- local orderId = str[2]
|
-- local orderId = str[2]
|
||||||
if result == SDK_RESULT.SUCCESS then
|
if result == SDK_RESULT.SUCCESS then
|
||||||
|
if VipManager.GetChargedNum() == 0 then
|
||||||
|
SubmitExtraData({
|
||||||
|
type = SDKSubMitType.TYPE_RESOURCE_purchase_unique,
|
||||||
|
roleCreateTime = "" .. context.RechargeId,
|
||||||
|
roleLevelUpTime = price
|
||||||
|
})
|
||||||
|
end
|
||||||
|
SubmitExtraData({
|
||||||
|
type = SDKSubMitType.TYPE_RESOURCE_purchase_total,
|
||||||
|
roleCreateTime = "" .. context.RechargeId,
|
||||||
|
roleLevelUpTime = price
|
||||||
|
})
|
||||||
elseif result == SDK_RESULT.FAILED then
|
elseif result == SDK_RESULT.FAILED then
|
||||||
|
|
||||||
else
|
else
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue