New file |
| | |
| | | #!/usr/bin/python
|
| | | # -*- coding: GBK -*-
|
| | | #-------------------------------------------------------------------------------
|
| | | #
|
| | | #-------------------------------------------------------------------------------
|
| | | #
|
| | | ##@package GM.Commands.SetMWSoul
|
| | | #
|
| | | # @todo:设置法宝之魂激活状态
|
| | | # @author xdh
|
| | | # @date 2018-08-18
|
| | | # @version 1.0
|
| | | #
|
| | | # 详细描述: 设置法宝之魂激活状态
|
| | | #
|
| | | #---------------------------------------------------------------------
|
| | | """Version = 2018-08-18 16:30"""
|
| | | #---------------------------------------------------------------------
|
| | | import PlayerMagicWeapon
|
| | | import PlayerControl
|
| | | import ChConfig
|
| | | import GameWorld
|
| | |
|
| | | #逻辑实现
|
| | | ## GM命令执行入口
|
| | | # @param curPlayer 当前玩家
|
| | | # @param list 参数列表 [npcID]
|
| | | # @return None
|
| | | # @remarks 函数详细说明.
|
| | | def OnExec(curPlayer, paramList):
|
| | | if len(paramList) != 2:
|
| | | GameWorld.DebugAnswer(curPlayer, "SetMWSoul 魂ID 状态(1激活,0未激活)")
|
| | | return
|
| | | soulID = paramList[0]
|
| | | state = paramList[1]
|
| | | |
| | | GameWorld.SetDictValueByBit(curPlayer, ChConfig.Def_PDict_MWSoulActiveState, soulID, state, True)
|
| | | |
| | | PlayerMagicWeapon.CalcMagicWeaponSoulAttr(curPlayer)
|
| | | PlayerControl.PlayerControl(curPlayer).RefreshPlayerAttrState()
|
| | | |
| | | #֪ͨ
|
| | | PlayerMagicWeapon.Sycn_MWPrivilegeData(curPlayer, soulID)
|
| | | return
|
| | |
|