From 0f3e626fd32560e7d18c95d6ae6343416bb39f66 Mon Sep 17 00:00:00 2001
From: hxp <ale99527@vip.qq.com>
Date: 星期五, 31 八月 2018 15:06:43 +0800
Subject: [PATCH] Fix: 3136 【后端】坐骑、灵宠碎片合成的信息提示优化;
---
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/IpyGameDataPY.py | 7 +++++--
PySysDB/PySysDBPY.h | 1 +
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Event/EventSrc/Operate_ItemCompound.py | 33 ++++++++++++++++-----------------
3 files changed, 22 insertions(+), 19 deletions(-)
diff --git a/PySysDB/PySysDBPY.h b/PySysDB/PySysDBPY.h
index 9cdb9c2..4655e84 100644
--- a/PySysDB/PySysDBPY.h
+++ b/PySysDB/PySysDBPY.h
@@ -79,6 +79,7 @@
WORD SuccessRateMax; // 最大成功率万分率
BYTE AddonsCountMax; //最大可附加材料数, 增加概率用, 非必须, 0代表不可附加材料
char SysMark; //提示mark
+ BYTE SysMarkParamType; //系统提示参数组合类型
};
diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Event/EventSrc/Operate_ItemCompound.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Event/EventSrc/Operate_ItemCompound.py
index 9c3d2dd..03abf41 100644
--- a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Event/EventSrc/Operate_ItemCompound.py
+++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Event/EventSrc/Operate_ItemCompound.py
@@ -90,7 +90,6 @@
successRate = ipyData.GetSuccessRate()
successRateMax = ipyData.GetSuccessRateMax()
addonsCountMax = ipyData.GetAddonsCountMax() # 可叠加的算叠加数量
- msgMark = ipyData.GetSysMark()
# 可使用非固定道具 或 附加道具的 单次合成数默认为1
if unfixedItemIDList or addonsCountMax > 0:
compoundCnt = 1
@@ -183,7 +182,18 @@
# 合成成功
if GameWorld.CanHappen(totalSuccRate, ShareDefine.Def_MaxRateValue):
GameWorld.DebugLog("合成成功: makeItemID=%s,compoundCnt=%s,compoundBindCnt=%s" % (makeItemID, compoundCnt, compoundBindCnt), playerID)
- GiveNewCompoundItem(curPlayer, makeItemID, compoundCnt, compoundBindCnt, wingItemExpInfo, dogzEquipPlusExp, msgMark)
+ userData = GiveNewCompoundItem(curPlayer, makeItemID, compoundCnt, compoundBindCnt, wingItemExpInfo, dogzEquipPlusExp)
+
+ msgMark = ipyData.GetSysMark()
+ paramType = ipyData.GetSysMarkParamType()
+ if msgMark not in ['0', '', '-']:
+ if paramType == 2 and fixedItemIDList and fixedItemCountList:
+ PlayerControl.WorldNotify(0, msgMark, [curPlayer.GetName(), fixedItemCountList[0], fixedItemIDList[0], makeItemID, userData])
+ else:
+ PlayerControl.WorldNotify(0, msgMark, [curPlayer.GetName(), makeItemID, userData])
+
+ # 通知合成成功
+ ItemCommon.SyncMakeItemAnswer(curPlayer, ShareDefine.Def_mitItemCompound, ChConfig.Def_ComposeState_Sucess, makeItemID)
#成功合成1个物品成就
PlayerSuccess.DoAddSuccessProgress(curPlayer, ShareDefine.SuccType_CompoundItemEx, compoundCnt, [makeItemID])
#合成X阶X颜色X星级以上装备
@@ -446,7 +456,7 @@
# @param newItem: 新物品
# @param itemCount: 合成数量
# @return None
-def GiveNewCompoundItem(curPlayer, newItemID, itemCount, compoundBindCnt, wingItemExpInfo, dogzEquipPlusExp, msgMark):
+def GiveNewCompoundItem(curPlayer, newItemID, itemCount, compoundBindCnt, wingItemExpInfo, dogzEquipPlusExp):
compoundUnBindCnt = itemCount - compoundBindCnt
if compoundBindCnt > 0:
@@ -454,20 +464,9 @@
if compoundUnBindCnt > 0:
userData = __GivePlayerCompoundItem(curPlayer, newItemID, compoundUnBindCnt, False, wingItemExpInfo, dogzEquipPlusExp)
- if userData == None:
- return
-
- if msgMark not in ['0', '', '-']:
- PlayerControl.WorldNotify(0, msgMark, [curPlayer.GetName(), newItemID, userData])
-
- # 您获得了物品XX XX个
- #PlayerControl.NotifyCode(curPlayer, "ObtainRes01", [newItemID, itemCount])
- # 通知放入特效
- #curPlayer.Sync_GetItemView(newItemID, itemCount)
- # 通知合成成功
- ItemCommon.SyncMakeItemAnswer(curPlayer, ShareDefine.Def_mitItemCompound, ChConfig.Def_ComposeState_Sucess, newItemID)
- #curPlayer.Sync_MakeItemAnswer(ShareDefine.Def_mitItemCompound, ChConfig.Def_ComposeState_Sucess)
- return True
+ if not userData:
+ return ""
+ return userData
def __GivePlayerCompoundItem(curPlayer, newItemID, itemCount, isBind, wingItemExpInfo, dogzEquipPlusExp):
playerID = curPlayer.GetPlayerID()
diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/IpyGameDataPY.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/IpyGameDataPY.py
index 490a5ec..3c7a74b 100644
--- a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/IpyGameDataPY.py
+++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/IpyGameDataPY.py
@@ -94,6 +94,7 @@
("WORD", "SuccessRateMax", 0),
("BYTE", "AddonsCountMax", 0),
("char", "SysMark", 0),
+ ("BYTE", "SysMarkParamType", 0),
),
"ItemPlus":(
@@ -1085,7 +1086,8 @@
self.SuccessRate = 0
self.SuccessRateMax = 0
self.AddonsCountMax = 0
- self.SysMark = ""
+ self.SysMark = ""
+ self.SysMarkParamType = 0
return
def GetID(self): return self.ID # 合成配置编号ID
@@ -1098,7 +1100,8 @@
def GetSuccessRate(self): return self.SuccessRate # 成功率万分率
def GetSuccessRateMax(self): return self.SuccessRateMax # 最大成功率万分率
def GetAddonsCountMax(self): return self.AddonsCountMax # 最大可附加材料数, 增加概率用, 非必须, 0代表不可附加材料
- def GetSysMark(self): return self.SysMark # 提示mark
+ def GetSysMark(self): return self.SysMark # 提示mark
+ def GetSysMarkParamType(self): return self.SysMarkParamType # 系统提示参数组合类型
# 物品强化效果表
class IPY_ItemPlus():
--
Gitblit v1.8.0