| | |
| | | PyGameData.EquipItemSkillIDList = []
|
| | | PyGameData.DailyUseCountLimitItemIDList = []
|
| | | PyGameData.AutoTransformCountItemIDList = []
|
| | | PyGameData.MoneyItemIDDict = {}
|
| | |
|
| | | gameData = GameWorld.GetGameData()
|
| | | for i in range(0, gameData.GetItemCount()):
|
| | |
| | | PyGameData.g_stoneLevelIDDict[(stoneEffType, stoneLevel)] = itemID
|
| | | elif curEffID == ChConfig.Def_Effect_ItemCount:
|
| | | PyGameData.AutoTransformCountItemIDList.append(itemID)
|
| | | elif curEffID == ChConfig.Def_Effect_ItemGiveMoney:
|
| | | moneyValue = itemEff.GetEffectValue(0)
|
| | | moneyType = itemEff.GetEffectValue(1)
|
| | | if moneyValue == 1 and moneyType:
|
| | | PyGameData.MoneyItemIDDict[moneyType] = itemID
|
| | |
|
| | | if GetIsEquip(findItemData):
|
| | | for skillIndex in xrange(findItemData.GetAddSkillCount()):
|
| | |
| | |
|
| | | if PyGameData.AutoTransformCountItemIDList:
|
| | | GameWorld.Log("自动转化为物品个数的物品ID列表: %s" % PyGameData.AutoTransformCountItemIDList)
|
| | | |
| | | GameWorld.Log("货币类型1个数量对应物品ID: %s" % PyGameData.MoneyItemIDDict)
|
| | | |
| | | PyGameData.InitPyItem = True
|
| | | return
|
| | |
|
| | | def GetMoneyItemID(moneyType):
|
| | | ## 获取货币类型对应的物品ID
|
| | | if moneyType not in PyGameData.MoneyItemIDDict:
|
| | | GameWorld.ErrLog("没有该货币类型对应的物品ID! moneyType=%s" % moneyType)
|
| | | return 0
|
| | | return PyGameData.MoneyItemIDDict[moneyType]
|
| | |
|
| | | ## 物品触发技能增加buff
|
| | | # @param curPlayer 当前玩家
|
| | |
| | | return
|
| | | curSingleItem.SetRemainHour(outTimeServerDay)
|
| | |
|
| | | if isAuctionItem:
|
| | | if IpyGameDataPY.GetIpyGameDataNotLog("AuctionItem", itemID):
|
| | | ItemControler.SetIsAuctionItem(curSingleItem, isAuctionItem)
|
| | | else:
|
| | | GameWorld.DebugLog("拍卖物品表不存在该ID!创建拍品失败,默认转为非拍品!itemID=%s" % itemID)
|
| | | #if isAuctionItem:
|
| | | # if IpyGameDataPY.GetIpyGameDataNotLog("AuctionItem", itemID):
|
| | | # ItemControler.SetIsAuctionItem(curSingleItem, isAuctionItem)
|
| | | # else:
|
| | | # GameWorld.DebugLog("拍卖物品表不存在该ID!创建拍品失败,默认转为非拍品!itemID=%s" % itemID)
|
| | |
|
| | | ItemControler.SetItemCount(curSingleItem, itemCount)
|
| | |
|
| | |
| | |
|
| | | # 记录玩家背包获得物品
|
| | | if packType in [IPY_GameWorld.rptItem, ShareDefine.rptTreasure] or packType in ShareDefine.Def_VPack_TypeList:
|
| | | EventReport.WriteEvent_item_record(curPlayer, 1, operateType, itemNoteDict, noteDict)
|
| | | pass
|
| | |
|
| | | return
|
| | |
|
| | |
| | |
|
| | | # 记录玩家背包物品删除
|
| | | if packType in [IPY_GameWorld.rptItem, ShareDefine.rptTreasure] or packType in ShareDefine.Def_VPack_TypeList:
|
| | | EventReport.WriteEvent_item_record(curPlayer, 0, operateType, itemNoteDict, noteDict)
|
| | | pass
|
| | |
|
| | | return
|
| | |
|
| | | def DR_EquipItemChange(curPlayer, curEquip, eventName, addDict={}):
|
| | | # 记录装备物品属性变更
|
| | | noteDict = GetItemNoteDict(curEquip, 1)
|
| | | noteDict.update(addDict)
|
| | | noteDict["packType"] = curEquip.GetItemPlaceType()
|
| | | DataRecordPack.DR_EquipMachining(curPlayer, eventName, noteDict)
|
| | | return
|
| | |
|
| | | #===============================================================================
|