From de55e89b8004896e736da4f8d63a8f974d9fc298 Mon Sep 17 00:00:00 2001
From: hch <305670599@qq.com>
Date: 星期一, 20 八月 2018 20:12:31 +0800
Subject: [PATCH] fix:挂机表

---
 ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/EventReport.py |    9 +++++----
 1 files changed, 5 insertions(+), 4 deletions(-)

diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/EventReport.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/EventReport.py
index 155d427..79b326c 100644
--- a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/EventReport.py
+++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/EventReport.py
@@ -105,12 +105,11 @@
 #  @param eventParam 事件参数
 #  @param curPlayer 
 #  @return None
-def EventReport(eventActionID, eventParam, curPlayer=None):
+def EventReport(eventActionID, eventParam, curPlayer=None, OperatorID=""):
     # 组成例子 eventParam 的格式必须是 xx=yy&zz=cc
     #  "http://192.168.0.249:12000/event_receiver?EventID=3099&OperatorID=test&PlayerCount=102&Time=2018-02-08 18:30:30&ProductID=snxxz&RegionName=s1"
     
-    OperatorID = GameWorld.GetPlatform()
-    if not OperatorID:
+    if not curPlayer and not OperatorID:
         return
 
     ProductID = ReadChConfig.GetPyMongoConfig("EventReport", "ProductID")
@@ -124,6 +123,8 @@
                           "AccountID": GameWorld.GetPlatformAccID(curPlayer.GetAccID()),
                           "IP": curPlayer.GetIP(),
                           "Level": curPlayer.GetLV()}) 
+        
+        OperatorID = GameWorld.GetPlayerPlatform(curPlayer.GetAccID())
 
     if eventParam:
         eventParam = "&%s"%eventParam
@@ -572,7 +573,7 @@
 def WriteEvent_session(curPlayer):
     seconds = 0
     if PlayerTJG.GetIsTJG(curPlayer):
-        seconds = 0
+        return
     else:
         logoffTimeStr = curPlayer.GetLogoffTime().strip()
         loginTimeStr = curPlayer.GetLoginTime().strip()

--
Gitblit v1.8.0