From 718f530accc19969f39d1a8ce199fe947508e29a Mon Sep 17 00:00:00 2001
From: hxp <ale99527@vip.qq.com>
Date: 星期四, 16 十月 2025 19:19:09 +0800
Subject: [PATCH] 237 【福利内容】每日任务/每周任务/章节奖励-服务端(每日任务、每周奖励;)
---
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/PlayerViewCache.py | 20 ++++++++++++++------
1 files changed, 14 insertions(+), 6 deletions(-)
diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/PlayerViewCache.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/PlayerViewCache.py
index 1201f24..a6c0330 100644
--- a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/PlayerViewCache.py
+++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/PlayerViewCache.py
@@ -194,6 +194,9 @@
if not curCache:
return
+ familyID = curPlayer.GetFamilyID()
+ family = DBDataMgr.GetFamilyMgr().FindFamily(familyID) if familyID else None
+
tick = GameWorld.GetGameWorld().GetTick()
curPlayer.SetDict(Key_UpdViewCacheTick, tick)
#GameWorld.DebugLog("更新玩家查看缓存数据! isOffline=%s" % isOffline, playerID)
@@ -205,10 +208,11 @@
curCache.SetFace(curPlayer.GetFace())
curCache.SetFacePic(curPlayer.GetFacePic())
curCache.SetModelMark(curPlayer.GetModelMark())
- curCache.SetFamilyID(curPlayer.GetFamilyID())
- curCache.SetFamilyName(curPlayer.GetFamilyName())
- curCache.SetFamilyEmblemID(PlayerControl.GetFamilyEmblemID(curPlayer))
curCache.SetTitleID(PlayerControl.GetTitleID(curPlayer))
+ curCache.SetFamilyID(familyID)
+ curCache.SetFamilyName(family.GetName() if family else "")
+ curCache.SetFamilyEmblemID(family.GetEmblemID() if family else 0)
+ curCache.SetFamilyEmblemWord(family.GetEmblemWord() if family else "")
curCache.SetFightPowerTotal(PlayerControl.GetFightPower(curPlayer))
curCache.SetServerID(GameWorld.GetPlayerServerID(curPlayer))
if isOffline:
@@ -236,7 +240,7 @@
# 其他
- plusDict= {"Equip":equipDict, "Lineup":lineupDict}
+ plusDict = {"Equip":equipDict, "Lineup":lineupDict}
curCache.SetPlusDict(plusDict)
return curCache
@@ -263,11 +267,12 @@
curCache.SetFace(dbPlayer.Face)
curCache.SetFacePic(dbPlayer.FacePic)
curCache.SetModelMark(dbPlayer.ModelMark)
+ curCache.SetTitleID(dbPlayer.ExAttr3)
curCache.SetFamilyID(familyID)
- family = DBDataMgr.GetFamilyMgr().FindFamily(familyID)
+ family = DBDataMgr.GetFamilyMgr().FindFamily(familyID) if familyID else None
curCache.SetFamilyName(family.GetName() if family else "")
curCache.SetFamilyEmblemID(family.GetEmblemID() if family else 0)
- #curCache.SetTitleID(PlayerControl.GetTitleID(curPlayer))
+ curCache.SetFamilyEmblemWord(family.GetEmblemWord() if family else "")
curCache.SetFightPowerTotal(dbPlayer.FightPowerEx * ChConfig.Def_PerPointValue + dbPlayer.FightPower)
curCache.SetServerID(GameWorld.GetAccIDServerID(dbPlayer.AccID))
curCache.SetOffTime(GameWorld.ChangeTimeStrToNum(dbPlayer.LogoffTime) if dbPlayer.LogoffTime else 0)
@@ -284,6 +289,7 @@
"RealmLV" : curCache.GetRealmLV(),
"Face" : curCache.GetFace(),
"FacePic" : curCache.GetFacePic(),
+ "TitleID" : curCache.GetTitleID(),
"ModelMark" : curCache.GetModelMark(),
"FightPower" : curCache.GetFightPowerTotal(),
"PlusData" : curCache.GetPlusDict(),
@@ -312,6 +318,7 @@
curCache.SetRealmLV(robotInfo.get("RealmLV", 0))
curCache.SetFace(robotInfo.get("Face", 0))
curCache.SetFacePic(robotInfo.get("FacePic", 0))
+ curCache.SetTitleID(robotInfo.get("TitleID", 0))
curCache.SetModelMark(robotInfo.get("ModelMark", 0))
#机器人暂定没有仙盟、称号
#curCache.SetFamilyID(familyID)
@@ -371,6 +378,7 @@
clientPack.FamilyID = curCache.GetFamilyID()
clientPack.FamilyName = curCache.GetFamilyName()
clientPack.FamilyEmblemID = curCache.GetFamilyEmblemID()
+ clientPack.FamilyEmblemWord = curCache.GetFamilyEmblemWord()
clientPack.PlusData = curCache.GetPlusData()
clientPack.PlusDataSize = len(clientPack.PlusData)
return clientPack
--
Gitblit v1.8.0