| | |
| | | def OnExec(curPlayer, msgList):
|
| | | #输入命令格式错误
|
| | | if len(msgList) < 1:
|
| | | GameWorld.DebugAnswer(curPlayer, "MakeItem ItemID 可选(个数 归属类型 归属ID)")
|
| | | GameWorld.DebugAnswer(curPlayer, "MakeItem ID (个数 是否拍品 归属类型 归属ID)")
|
| | | GameWorld.DebugAnswer(curPlayer, "归属类型:1-玩家,2-队伍,5-阵营,6-指定多个玩家")
|
| | | return
|
| | |
|
| | | itemID = msgList[0]
|
| | | count = msgList[1] if len(msgList) > 1 else 1
|
| | | dropType = msgList[2] if len(msgList) > 2 else ChConfig.Def_NPCHurtTypeAll
|
| | | itemCount = msgList[1] if len(msgList) > 1 else 1
|
| | | isAuctionItem = msgList[2] if len(msgList) > 2 else 0
|
| | | dropType = msgList[3] if len(msgList) > 3 else ChConfig.Def_NPCHurtTypeAll
|
| | | ownerID = 0
|
| | | specOwnerIDList = []
|
| | |
|
| | | if dropType == ChConfig.Def_NPCHurtTypeSpecial:
|
| | | specOwnerIDList = msgList[3:] if len(msgList) > 3 else []
|
| | | specOwnerIDList = msgList[4:] if len(msgList) > 4 else []
|
| | | else:
|
| | | ownerID = msgList[3] if len(msgList) > 3 else 0
|
| | | |
| | | ownerID = msgList[4] if len(msgList) > 4 else 0
|
| | | |
| | | gameMap = GameWorld.GetMap()
|
| | | dropPosX, dropPosY = curPlayer.GetPosX(), curPlayer.GetPosY() # 以玩家为中心点开始掉落
|
| | | doCount = 0
|
| | |
| | | #玩家不可移动这个点
|
| | | continue
|
| | |
|
| | | if index > count - 1:
|
| | | if index > itemCount - 1:
|
| | | break
|
| | | index += 1
|
| | |
|
| | | curItem = ItemControler.GetOutPutItemObj(itemID)
|
| | | curItem = ItemControler.GetOutPutItemObj(itemID, 1, isAuctionItem, curPlayer=curPlayer)
|
| | | if curItem == None:
|
| | | GameWorld.DebugAnswer(curPlayer, '无法查找物品 = %s' % (itemID))
|
| | | continue
|