From 2be15cca071335ed92680027b3722d2a8d1ce57b Mon Sep 17 00:00:00 2001 From: hxp <ale99527@vip.qq.com> Date: 星期五, 23 二月 2024 16:22:03 +0800 Subject: [PATCH] 9802 9762 【BT9】【后端】藏宝阁修改(背包计算转化物品占用格子数逻辑优化;开宝箱计算获得物品占用格子数逻辑优化;) --- ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Item/UseItem/Item_Chests.py | 2 +- ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GM/Commands/MakeItemCount.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GM/Commands/MakeItemCount.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GM/Commands/MakeItemCount.py index 319702e..913dd60 100644 --- a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GM/Commands/MakeItemCount.py +++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GM/Commands/MakeItemCount.py @@ -51,7 +51,7 @@ if not itemData: GameWorld.DebugAnswer(curPlayer, '该物品不存在 = %s' % (itemID)) return - if itemID in ChConfig.Def_TransformItemIDList or itemData.GetType() == ChConfig.Def_ItemType_AutoUseMoney: + if ItemControler.IsPutinAutoTransformItem(itemData): curItem = ItemControler.GetOutPutItemObj(itemID, itemCount, curPlayer=curPlayer) PlayerItemControler = ItemControler.PlayerItemControler(curPlayer) if not PlayerItemControler.PutInItem(IPY_GameWorld.rptItem, curItem, event=event): diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Item/UseItem/Item_Chests.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Item/UseItem/Item_Chests.py index c8b0ebe..39f8371 100644 --- a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Item/UseItem/Item_Chests.py +++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Item/UseItem/Item_Chests.py @@ -229,7 +229,7 @@ GameWorld.ErrLog("宝箱奖励物品不存在! chestsItemID=%s,itemID=%s,jobItemID=%s" % (chestsItemID, itemID, jobItemID)) return packType = ChConfig.GetItemPackType(itemData) - needSpace = int(math.ceil(itemCount / float(itemData.GetPackCount()))) + needSpace = ItemControler.GetItemNeedPackCount(packType, itemData, itemCount) needSpaceDict[packType] = needSpaceDict.get(packType, 0) + needSpace # 装备拆开给,需要同步每件装备的属性 -- Gitblit v1.8.0