屏蔽数数日志上报

tcx_xiyou_dev
wangzhenxing 2024-05-30 10:58:33 +08:00
parent 2513b4b9fd
commit bb2674c0a5
8 changed files with 79 additions and 79 deletions

View File

@ -86,10 +86,10 @@ function this.UpdateBagData(_itemData, isNoSendNewItemEvent)
-- 货币数据
if itemdata.itemId == 14 or itemdata.itemId == 16 then
ThinkingAnalyticsManager.SetSuperProperties({
coins_amount = BagManager.GetItemCountById(14),
diamond_amount = BagManager.GetItemCountById(16),
})
-- ThinkingAnalyticsManager.SetSuperProperties({
-- coins_amount = BagManager.GetItemCountById(14),
-- diamond_amount = BagManager.GetItemCountById(16),
-- })
end
end

View File

@ -36,11 +36,11 @@ function this.Initialize()
if AppConst.isSDK then
-- 监听赛季结束事件
Game.GlobalEvent:AddEvent(GameEvent.Network.OnReceiveHeartBeat, function(network, time)
if network.type == SocketType.LOGIN then
this.CalibrateTime(time)
end
end)
-- Game.GlobalEvent:AddEvent(GameEvent.Network.OnReceiveHeartBeat, function(network, time)
-- if network.type == SocketType.LOGIN then
-- this.CalibrateTime(time)
-- end
-- end)
-- 尝试触发 安装事件怀疑安装事件是在第一次触发track时触发的
-- App.TAMgr:Init()
end
@ -49,7 +49,7 @@ end
-- 校对时间
function this.CalibrateTime(time)
if AppConst.isSDK then
App.TAMgr:CalibrateTime(time*1000)
App.TAMgr:CalibrateTime(time*1000)
end
end
@ -99,30 +99,30 @@ end
local _SuperPropertise = {}
function this.SetSuperProperties(data)
if AppConst.isSDK then
for key, value in pairs(data) do
_SuperPropertise[key] = value
end
-- for key, value in pairs(data) do
-- _SuperPropertise[key] = value
-- end
local sData = _DicToStr(_SuperPropertise)
Log("打点静态数据:"..sData)
App.TAMgr:SetSuperProperties(sData)
-- local sData = _DicToStr(_SuperPropertise)
-- Log("打点静态数据:"..sData)
-- App.TAMgr:SetSuperProperties(sData)
end
end
-- 清除静态数据
function this.ClearSuperProperties()
if AppConst.isSDK then
_SuperPropertise = {}
App.TAMgr:ClearSuperProperties()
-- App.TAMgr:ClearSuperProperties()
end
end
-- 打点事件
function this.Track(event, data)
if AppConst.isSDK then
Log("打点事件:"..event)
local dStr = data and _DicToStr(data) or ""
Log("打点数据:"..dStr)
App.TAMgr:Track(event, dStr)
-- Log("打点事件:"..event)
-- local dStr = data and _DicToStr(data) or ""
-- Log("打点数据:"..dStr)
-- App.TAMgr:Track(event, dStr)
end
end

View File

@ -327,9 +327,9 @@ function this.GetFormationPower(formationId)
-- LogGreen("新方式战斗力:"..power2)
-- 主线编队战斗力
ThinkingAnalyticsManager.SetSuperProperties({
fighting_capacity = power2,
})
-- ThinkingAnalyticsManager.SetSuperProperties({
-- fighting_capacity = power2,
-- })
-- 刷新后端战斗力
if power2 > PlayerManager.maxForce then

View File

@ -308,10 +308,10 @@ end
function this.ShowGuide(id, ...)
-- 引导数据打点
DataCenterManager.CommitClickStatus(Language[10832], tostring(id))
ThinkingAnalyticsManager.Track("guild", {
step_id = id,
guild_start_time = math.floor(GetTimeStamp()),
})
-- ThinkingAnalyticsManager.Track("guild", {
-- step_id = id,
-- guild_start_time = math.floor(GetTimeStamp()),
-- })
if AppConst.isSDKLogin then
-- SDKMgr:NewRoleTutorial(tostring(id) ,tostring(math.floor(GetTimeStamp())) ,tostring(math.floor(GetTimeStamp())),
-- PlayerManager.serverInfo.server_id,PlayerManager.serverInfo.name,PlayerManager.nickName,tostring(PlayerManager.uid))

View File

@ -83,7 +83,7 @@ function this.Initialize()
Log("onSwitchAccountCallback::"..resp)
local result = string.split(resp, "#")
if tonumber(result[1]) == SDK_RESULT.SUCCESS then
ThinkingAnalyticsManager.Track("change_account")
--ThinkingAnalyticsManager.Track("change_account")
Game.Restart()
end
end
@ -92,7 +92,7 @@ function this.Initialize()
Log("onLogoutCallback::"..resp)
local result = string.split(resp, "#")
if LoginManager.IsLogin and tonumber(result[1]) == SDK_RESULT.SUCCESS then
ThinkingAnalyticsManager.Track("quit_account")
--AnalyticsManager.Track("quit_account")
Game.Restart()
end
-- 发送登出事件
@ -177,17 +177,17 @@ end
function this.TrackCreateAccount()
-- 登出之前的账号
ThinkingAnalyticsManager.Logout()
ThinkingAnalyticsManager.ClearSuperProperties()
-- 开始
ThinkingAnalyticsManager.SetSuperProperties({
account = AppConst.isSDK and tostring(AppConst.OpenId) or "",
Bundle_id = AppConst.isSDK and AppConst.SdkPackageName or "",
xx_id = AppConst.isSDK and AppConst.SdkChannel or "",
device_id = AppConst.isSDK and ThinkingAnalyticsManager.GetDeviceId() or "",
packId = PackageManager.GetPackageID() or "",
})
ThinkingAnalyticsManager.Track("create_account")
-- ThinkingAnalyticsManager.Logout()
-- ThinkingAnalyticsManager.ClearSuperProperties()
-- -- 开始
-- ThinkingAnalyticsManager.SetSuperProperties({
-- account = AppConst.isSDK and tostring(AppConst.OpenId) or "",
-- Bundle_id = AppConst.isSDK and AppConst.SdkPackageName or "",
-- xx_id = AppConst.isSDK and AppConst.SdkChannel or "",
-- device_id = AppConst.isSDK and ThinkingAnalyticsManager.GetDeviceId() or "",
-- packId = PackageManager.GetPackageID() or "",
-- })
-- ThinkingAnalyticsManager.Track("create_account")
end
function this.SaveLoginInfo(user, pw)

View File

@ -43,7 +43,7 @@ function this.LoginRequest(openId, func)
data.operator_s = AppConst.isSDK and AndroidDeviceInfo.Instance:GetOperatorName() or ""
data.network_s = AppConst.isSDK and AndroidDeviceInfo.Instance:GetNetworkType() or ""
data.ip_s = AppConst.isSDK and AndroidDeviceInfo.Instance:GetLocalIpAddress() or ""
data.distinct_id = AppConst.isSDK and ThinkingAnalyticsManager.GetDistinctId() or ""
data.distinct_id = ""--AppConst.isSDK and ThinkingAnalyticsManager.GetDistinctId() or ""
data.openId = openId
data.cc_id = PackageManager.GetCCCode()
data.serverId = LoginManager.ServerId
@ -67,14 +67,14 @@ function this.LoginRequest(openId, func)
AppConst.Token = msg.newToken
-- 打点
-- ThinkingAnalyticsManager.SetDistinctId(AppConst.OpenId)
ThinkingAnalyticsManager.SetSuperProperties({
server_id = LoginManager.ServerId,
account = AppConst.isSDK and tostring(AppConst.OpenId) or "",
Bundle_id = AppConst.isSDK and AppConst.SdkPackageName or "",
xx_id = AppConst.isSDK and AppConst.SdkChannel or "",
packId = PackageManager.GetPackageID() or "",
-- test_list = "1,2,3#2", -- 数组
})
-- ThinkingAnalyticsManager.SetSuperProperties({
-- server_id = LoginManager.ServerId,
-- account = AppConst.isSDK and tostring(AppConst.OpenId) or "",
-- Bundle_id = AppConst.isSDK and AppConst.SdkPackageName or "",
-- xx_id = AppConst.isSDK and AppConst.SdkChannel or "",
-- packId = PackageManager.GetPackageID() or "",
-- -- test_list = "1,2,3#2", -- 数组
-- })
TapDBManager.SetServer(LoginManager.ServerId)
end)
end
@ -132,17 +132,17 @@ function this.PlayerInfoRequest(func)
end
LogError("22222222222222222222222222222222222")
-- 数据打点
ThinkingAnalyticsManager.CalibrateTime(msg.player.serverTime)
ThinkingAnalyticsManager.Login(PlayerManager.uid)
ThinkingAnalyticsManager.SetSuperProperties({
role_id = PlayerManager.uid,
role_name = PlayerManager.nickName,
vip_level = msg.player.vipLevel,
-- test_date = math.floor(msg.player.serverTime) .. "#3", -- 日期
})
TapDBManager.SetUser(AppConst.OpenId)
TapDBManager.SetLevel(PlayerManager.level)
TapDBManager.SetServer(LoginManager.ServerId)
-- ThinkingAnalyticsManager.CalibrateTime(msg.player.serverTime)
-- ThinkingAnalyticsManager.Login(PlayerManager.uid)
-- ThinkingAnalyticsManager.SetSuperProperties({
-- role_id = PlayerManager.uid,
-- role_name = PlayerManager.nickName,
-- vip_level = msg.player.vipLevel,
-- -- test_date = math.floor(msg.player.serverTime) .. "#3", -- 日期
-- })
-- TapDBManager.SetUser(AppConst.OpenId)
-- TapDBManager.SetLevel(PlayerManager.level)
-- TapDBManager.SetServer(LoginManager.ServerId)
--
PlayerManager.missingRefreshCount = msg.missingRefreshCount--迷宫寻宝妖精刷新次数
@ -514,10 +514,10 @@ function this.ItemInfoRequest(_index, func)
func(msg)
end
-- 货币数据
ThinkingAnalyticsManager.SetSuperProperties({
coins_amount = BagManager.GetItemCountById(14),
diamond_amount = BagManager.GetItemCountById(16),
})
-- ThinkingAnalyticsManager.SetSuperProperties({
-- coins_amount = BagManager.GetItemCountById(14),
-- diamond_amount = BagManager.GetItemCountById(16),
-- })
else
_index = _index + #msg.itemlist
this.ItemInfoRequest(_index, func)
@ -2597,11 +2597,11 @@ function this.RequestMyGuildInfo(func)
end
-- 工会数据
ThinkingAnalyticsManager.SetSuperProperties({
guild_id = msg.familyBaseInfo.id,
guild_name = msg.familyBaseInfo.name,
guild_level = msg.familyBaseInfo.levle,
})
-- ThinkingAnalyticsManager.SetSuperProperties({
-- guild_id = msg.familyBaseInfo.id,
-- guild_name = msg.familyBaseInfo.name,
-- guild_level = msg.familyBaseInfo.levle,
-- })
end)
end

View File

@ -189,12 +189,12 @@ function this.RequestPay(context)
SDKMgr:Pay(params)
--
ThinkingAnalyticsManager.Track("create_order", {
goods_id = context.Id,
goods_name = context.Name,
order_money_amount = price,
Bundle_id = AppConst.SdkPackageName,
})
-- ThinkingAnalyticsManager.Track("create_order", {
-- goods_id = context.Id,
-- goods_name = context.Name,
-- order_money_amount = price,
-- Bundle_id = AppConst.SdkPackageName,
-- })
end
return this

View File

@ -79,9 +79,9 @@ function this.ChangeUserName(type, name, teamPosId, sex, callBack)
PlayerManager.nickName = name
-- 打点静态数据修改
ThinkingAnalyticsManager.SetSuperProperties({
role_name = PlayerManager.nickName,
})
-- ThinkingAnalyticsManager.SetSuperProperties({
-- role_name = PlayerManager.nickName,
-- })
-- 上报改名事件
SubmitExtraData({ type = SDKSubMitType.TYPE_CHANGE_NAME, oldName = oldName })