| | |
| | |
|
| | | # 使用拍品
|
| | | if curItem.GetIsBind():
|
| | | DoLogic_PlayerUseAuctionItem(curPlayer, curItem)
|
| | | GameWorld.DebugLog("玩家使用拍品: itemID=%s" % (curItem.GetItemTypeID()), curPlayer.GetPlayerID())
|
| | | ItemControler.SetIsAuctionItem(curItem, False, curPlayer)
|
| | | return
|
| | |
|
| | | if useCnt <= 0:
|
| | |
| | |
|
| | | __DoLogic_PlayerUseItemSelf(curPlayer, itemIndex, tick, useCnt, exData)
|
| | |
|
| | | return
|
| | |
|
| | | def DoLogic_PlayerUseAuctionItem(curPlayer, curItem):
|
| | | ## 玩家使用拍品
|
| | | playerID = curPlayer.GetPlayerID()
|
| | | itemID = curItem.GetItemTypeID()
|
| | | |
| | | curItem.SetIsBind(0) # 设置为非拍品
|
| | | GameWorld.DebugLog("玩家使用拍品: itemID=%s" % (itemID), playerID)
|
| | | |
| | | if ItemCommon.GetIsEquip(curItem):
|
| | | # 生成传奇属性
|
| | | legendAttrInfo = ItemControler.GetAddEquipLegendAttr(curItem, curPlayer)
|
| | | if not legendAttrInfo:
|
| | | GameWorld.ErrLog("使用装备拍品没有传奇属性!itemID=%s" % (itemID), playerID)
|
| | | return
|
| | | attrIDList, attrValueList = legendAttrInfo
|
| | | updateDict = {ShareDefine.Def_IudetLegendAttrID:attrIDList, ShareDefine.Def_IudetLegendAttrValue:attrValueList}
|
| | | delKeyList = [ShareDefine.Def_IudetAuctionItemCreateTime]
|
| | | ItemCommon.UpdateItemUserData(curItem, updateDict, delKeyList, isUpdateGS=True)
|
| | | |
| | | return
|
| | |
|
| | | #---------------------------------------------------------------------
|
| | |
| | | # @return
|
| | | def EquipAddAdditionEx(curItem, equipData):
|
| | | # 绑定
|
| | | if equipData.isBind:
|
| | | ItemControler.SetItemIsBind(curItem, equipData.isBind)
|
| | | #if equipData.isBind:
|
| | | # ItemControler.SetItemIsBind(curItem, equipData.isBind)
|
| | |
|
| | | if not ItemCommon.CheckItemIsEquip(curItem):
|
| | | return
|