From e4c59d1e26897c665df2552b4576ffcee7475313 Mon Sep 17 00:00:00 2001
From: xdh <xiefantasy@qq.com>
Date: 星期二, 04 十二月 2018 16:07:05 +0800
Subject: [PATCH] 4860 【后端】【1.3.100】退出仙盟时间存储问题

---
 ServerPython/CoreServerGroup/GameServer/Script/Player/PlayerControl.py                                                |    7 ++++++-
 ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/RemoteQuery/GY_Query_SetLeaveFamilyTime.py |   47 +++++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 53 insertions(+), 1 deletions(-)

diff --git a/ServerPython/CoreServerGroup/GameServer/Script/Player/PlayerControl.py b/ServerPython/CoreServerGroup/GameServer/Script/Player/PlayerControl.py
index 9486609..ee31aa5 100644
--- a/ServerPython/CoreServerGroup/GameServer/Script/Player/PlayerControl.py
+++ b/ServerPython/CoreServerGroup/GameServer/Script/Player/PlayerControl.py
@@ -220,7 +220,12 @@
 def SetTodayXianyuanCoin(curPlayer, value): return curPlayer.SetExAttr11(value)
 
 ##玩家主动退出仙盟时间(<100代表退出次数)
-def SetLeaveFamilyTime(curPlayer, value): return curPlayer.SetExAttr12(value)
+def SetLeaveFamilyTime(curPlayer, value, isSyncMap=True):
+    curPlayer.SetExAttr12(value)
+    if isSyncMap:
+        sysMsg = '%s'%value
+        curPlayer.MapServer_QueryPlayerResult(0, 0, "SetLeaveFamilyTime", sysMsg, len(sysMsg))
+    return 
 def GetLeaveFamilyTime(curPlayer):return curPlayer.GetExAttr12()
 
 ## 是否脱机挂机状态
diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/RemoteQuery/GY_Query_SetLeaveFamilyTime.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/RemoteQuery/GY_Query_SetLeaveFamilyTime.py
new file mode 100644
index 0000000..1463978
--- /dev/null
+++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/RemoteQuery/GY_Query_SetLeaveFamilyTime.py
@@ -0,0 +1,47 @@
+#!/usr/bin/python
+# -*- coding: GBK -*-
+#---------------------------------------------------------------------
+#
+#---------------------------------------------------------------------
+##@package GY_Query_SetLeaveFamilyTime
+# @todo: 设置玩家主动退出仙盟时间(<100代表退出次数)
+#
+# @author: xdh
+# @date 2018-12-04
+# @version 1.0
+#
+# @note: 
+#---------------------------------------------------------------------
+"""Version = 2018-12-04 15:30"""
+#---------------------------------------------------------------------
+import GameWorld
+#---------------------------------------------------------------------
+#全局变量
+#---------------------------------------------------------------------
+
+#---------------------------------------------------------------------
+#逻辑实现
+## 请求逻辑
+#  @param query_Type 请求类型
+#  @param query_ID 请求的玩家ID
+#  @param packCMDList 发包命令 [GM账户]
+#  @param tick 当前时间
+#  @return '' or None
+#  @remarks 函数详细说明.
+def DoLogic(query_Type, query_ID, packCMDList, tick):
+    return
+#---------------------------------------------------------------------
+#执行结果
+## 执行结果
+#  @param curPlayer 发出请求的玩家
+#  @param callFunName 功能名称
+#  @param funResult 查询的结果
+#  @param tick 当前时间
+#  @return None
+#  @remarks 函数详细说明.
+def DoResult(curPlayer, callFunName, funResult, tick):
+    value = GameWorld.ToIntDef(funResult, None)
+    if value == None:
+        return
+    curPlayer.SetExAttr12(value)
+    return

--
Gitblit v1.8.0