1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
  | #!/usr/bin/python  
 |  # -*- coding: GBK -*-  
 |  #-------------------------------------------------------------------------------  
 |  #  
 |  ##@package UseItem.Item_GubaoPiece  
 |  #  
 |  # @todo:¹Å±¦ËéÆ¬Ð§¹ûID  
 |  # @author hxp  
 |  # @date 2023-03-31  
 |  # @version 1.0  
 |  #  
 |  # ÏêϸÃèÊö: ¹Å±¦ËéÆ¬Ð§¹ûID£¬ AÖµ-¹Å±¦ID  
 |  #  
 |  #-------------------------------------------------------------------------------  
 |  #"""Version = 2023-03-31 15:30"""  
 |  #-------------------------------------------------------------------------------  
 |    
 |  import ItemCommon  
 |  import PlayerGubao  
 |  import ChConfig  
 |    
 |  def BatchUseItem(curPlayer, curRoleItem, tick, useCnt, exData):  
 |      ##ÅúÁ¿Ê¹ÓÃÎïÆ·  
 |      curEff = curRoleItem.GetEffectByIndex(0)  
 |      gubaoID = curEff.GetEffectValue(0)  
 |      curCount, updCount = PlayerGubao.AddGubaoPiece(curPlayer, gubaoID, useCnt, curRoleItem.GetItemTypeID())  
 |      succCnt = useCnt  
 |      saveDataDict = {"gubaoID":gubaoID, "curCount":curCount, "updCount":updCount}  
 |      ItemCommon.DelItem(curPlayer, curRoleItem, succCnt, True, ChConfig.ItemDel_Unknown, saveDataDict, True)  
 |      return True, succCnt  
 |    
 |    
 |  
  |