From b4488bc3020cf5da3bf9fe4a0b27ba59b2d9f8cc Mon Sep 17 00:00:00 2001
From: hxp <ale99527@vip.qq.com>
Date: 星期五, 12 十二月 2025 20:18:02 +0800
Subject: [PATCH] 389 流向记录(每日累计在线时长流向 OnlineTimeToday)

---
 ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GameWorld.py |   21 ++++++++++++++++++++-
 1 files changed, 20 insertions(+), 1 deletions(-)

diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GameWorld.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GameWorld.py
index c2bb1c8..3a7ede6 100644
--- a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GameWorld.py
+++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GameWorld.py
@@ -1293,6 +1293,22 @@
     LogUI.Msg('%s\t%s\tPyDebug:%s'%(par, playerID, msg))
     return
 
+def DebugLogEx(logFormat, *args):
+    ## DEBUG调试输出信息,只传入日志格式跟参数,非debug下不进行日志内容格式化
+    # @param logFormat: 日志内容格式,也可以直接传入完整的日志内容
+    # @param args: 日志参数,最后一个参数可以多传一个参数作为playerID用
+    if not __GameWorld.GetDebugLevel():
+        return
+    par = 0
+    playerID = 0
+    try:
+        msg = logFormat % args
+    except:
+        msg = logFormat % args[:-1]
+        playerID = args[-1]
+    LogUI.Msg('%s\t%s\tPyDebug:%s'%(par, playerID, msg))
+    return
+
 #---------------------------------------------------------------------
 ##获得当前服务器跨服ID
 # @param 无
@@ -1441,7 +1457,10 @@
 
 ##获取玩家所属平台
 def GetPlayerPlatform(curPlayer):
-    return curPlayer.GetAccountData().GetOperator()
+    appID = curPlayer.GetAccountData().GetOperator()
+    if not appID:
+        appID = GetAppIDByAccID(curPlayer.GetAccID())
+    return appID
 
 ##获取平台账号
 def GetPlatformAccID(gameAccID):

--
Gitblit v1.8.0