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