From 72e0425552abdbcc2fffbb8e9575e21dbda469a2 Mon Sep 17 00:00:00 2001
From: hxp <ale99527@vip.qq.com>
Date: 星期一, 23 五月 2022 17:03:29 +0800
Subject: [PATCH] 9415 【BT】【后端】古神战场(修复周参与榜结算奖励某些名次多结算神玉奖励bug; 每天过天时增加记录跨服榜单数据流向)
---
ServerPython/CoreServerGroup/GameServer/Script/GM/Commands/Couple.py | 28 +++++++++++++++++++---------
1 files changed, 19 insertions(+), 9 deletions(-)
diff --git a/ServerPython/CoreServerGroup/GameServer/Script/GM/Commands/Couple.py b/ServerPython/CoreServerGroup/GameServer/Script/GM/Commands/Couple.py
index f5164e8..7d042ca 100644
--- a/ServerPython/CoreServerGroup/GameServer/Script/GM/Commands/Couple.py
+++ b/ServerPython/CoreServerGroup/GameServer/Script/GM/Commands/Couple.py
@@ -26,9 +26,10 @@
GameWorld.DebugAnswer(curPlayer, "---------- %s" % GameWorld.GetCurrentDataTimeStr())
GameWorld.DebugAnswer(curPlayer, "清除伴侣: Couple 0")
GameWorld.DebugAnswer(curPlayer, "重置聘礼: Couple 0 1")
- GameWorld.DebugAnswer(curPlayer, "设置伴侣: Couple 1 目标ID [可选聘礼ID]")
+ GameWorld.DebugAnswer(curPlayer, "设置成亲: Couple 1 伴侣ID [可选聘礼ID]")
GameWorld.DebugAnswer(curPlayer, "设亲密度: Couple 2 目标ID 亲密度")
GameWorld.DebugAnswer(curPlayer, "增加密度: Couple 3 目标ID 亲密度")
+ GameWorld.DebugAnswer(curPlayer, "添加喜宴: Couple 4 聘礼ID 宴会个数")
return
#逻辑实现
@@ -67,19 +68,21 @@
return
- # 设置伴侣
+ # 设置成亲
elif value1 == 1:
- if couple:
- GameWorld.DebugAnswer(curPlayer, "已有伴侣! coupleID=%s" % couple.GetCoupleID(playerID))
- return
tagPlayerID = gmList[1] if len(gmList) > 1 else 0
if not tagPlayerID or tagPlayerID == playerID:
GameWorld.DebugAnswer(curPlayer, "非法伴侣玩家ID:%s,playerID=%s" % (tagPlayerID, playerID))
return
+ if couple:
+ if couple.GetCoupleID(playerID) != tagPlayerID:
+ GameWorld.DebugAnswer(curPlayer, "已有伴侣! coupleID=%s" % couple.GetCoupleID(playerID))
+ return
tagCouple = coupleMgr.GetCouple(tagPlayerID)
if tagCouple:
- GameWorld.DebugAnswer(curPlayer, "对方已有伴侣! tagCoupleID=%s" % tagCouple.GetCoupleID(tagPlayerID))
- return
+ if tagCouple.GetCoupleID(tagPlayerID) != playerID:
+ GameWorld.DebugAnswer(curPlayer, "对方已有伴侣! tagCoupleID=%s" % tagCouple.GetCoupleID(tagPlayerID))
+ return
bridePriceID = gmList[2] if len(gmList) > 2 else 1
@@ -91,7 +94,7 @@
PyGameData.g_marryReqInfo[tagPlayerID] = reqData
reqPlayer = GameWorld.GetPlayerManager().FindPlayerByID(tagPlayerID)
- isOK = PlayerLove.__DoMarryResponse(curPlayer, reqPlayer, tagPlayerID, 1)
+ isOK = PlayerLove.__DoMarryResponse(curPlayer, playerID, reqPlayer, tagPlayerID, 1)
GameWorld.DebugAnswer(curPlayer, "设置伴侣【%s】 %s" % (tagPlayerID, isOK))
return
@@ -116,7 +119,14 @@
PyDataManager.GetIntimacyManager().AddIntimacyBoth(playerID, tagPlayerID, addValue)
intimacys = PyDataManager.GetIntimacyManager().GetIntimacys(playerID)
if intimacys:
- GameWorld.DebugAnswer(curPlayer, "更新目标【%s】亲密度: %s" % (tagPlayerID, intimacys.GetTagIntimacy(tagPlayerID)))
+ GameWorld.DebugAnswer(curPlayer, "更新目标【%s】亲密度: %s" % (tagPlayerID, intimacys.GetTagIntimacy(tagPlayerID)))
+
+ # 增加亲密度
+ elif value1 == 4:
+ bridePriceID = gmList[1] if len(gmList) > 1 else 1
+ addCount = gmList[2] if len(gmList) > 2 else 1
+ addCount = PlayerLove.GMAddCandy(curPlayer, bridePriceID, addCount)
+ GameWorld.DebugAnswer(curPlayer, "添加喜宴数:%s" % addCount)
else:
__Help(curPlayer)
return
--
Gitblit v1.8.0