MapServer.PlayerObject.ProcessAction_Die C# (CSharp) Method

ProcessAction_Die() protected method

protected ProcessAction_Die ( GameStruct act ) : void
act GameStruct
return void
        protected override void ProcessAction_Die(GameStruct.Action act)
        {
            //变为幽灵
            //TransformGhost();

            //死亡标记
            BaseObject obj = act.GetObject(0) as BaseObject;
            NetMsg.MsgMonsterDieInfo die = new NetMsg.MsgMonsterDieInfo();
            die.monsterid = this.GetTypeId();
            die.roleid = obj.GetTypeId();
            die.role_x = this.GetCurrentX();
            die.role_y = this.GetCurrentY();
            die.tag = 14;
            this.BroadcastBuffer(die.GetBuffer(), true);

            m_bGhost = true;
            mnGhostTick = System.Environment.TickCount;
            //死亡之后自动攻击目标为Null
            this.GetFightSystem().SetAutoAttackTarget(null);

            this.GetPKSystem().Die(obj);
            //亡念巫灵原地复活//要在删除状态之前调用该代码
            if (this.GetTimerSystem().QueryStatus(GameStruct.RoleStatus.STATUS_WANGNIANWULING) != null)
            {
                this.Alive(true);
            }

            //移除一些死亡后的状态
            this.GetTimerSystem().Die_DeleteState();

            //死亡后幻兽也要召回
            this.GetEudemonSystem().Eudemon_ReCallAll();
            //死亡后骑乘幻兽中就下马
            if (this.GetMountID() > 0)
            {
                this.TakeOffMount(0);
            }
            this.GetTimerSystem().AddStatus(GameStruct.RoleStatus.STATUS_DIE);
        }