Exemplo n.º 1
0
 public void UpdateLogic(int delta)
 {
     if (this.bActive)
     {
         if ((this._bInitVisibleDelay > 0) && ((this._bInitVisibleDelay = (byte)(this._bInitVisibleDelay - 1)) == 0))
         {
             this.Visible = true;
         }
         if (this.ActorControl != null)
         {
             this.ActorControl.UpdateLogic(delta);
         }
         if (this.ValueComponent != null)
         {
             this.ValueComponent.UpdateLogic(delta);
         }
         if (this.EquipComponent != null)
         {
             this.EquipComponent.UpdateLogic(delta);
         }
         if (this.HurtControl != null)
         {
             this.HurtControl.UpdateLogic(delta);
         }
         if (this.MovementComponent != null)
         {
             this.MovementComponent.UpdateLogic(delta);
         }
         if (this.SkillControl != null)
         {
             this.SkillControl.UpdateLogic(delta);
         }
         if (this.AnimControl != null)
         {
             this.AnimControl.UpdateLogic(delta);
         }
         if (this.BuffHolderComp != null)
         {
             this.BuffHolderComp.UpdateLogic(delta);
         }
         if (this.EffectControl != null)
         {
             this.EffectControl.UpdateLogic(delta);
         }
         if (this.HorizonMarker != null)
         {
             this.HorizonMarker.UpdateLogic(delta);
         }
         if (this.ActorControl != null)
         {
             BaseAttackMode currentAttackMode = this.ActorControl.GetCurrentAttackMode();
             if (currentAttackMode != null)
             {
                 currentAttackMode.UpdateLogic(delta);
             }
         }
     }
 }
Exemplo n.º 2
0
        protected override void OnDead()
        {
            base.OnDead();
            this.contiKillNum = 0;
            this.contiDeadNum++;
            base.actor.SkillControl.SkillUseCache.Clear();
            BaseAttackMode currentAttackMode = base.GetCurrentAttackMode();

            if (currentAttackMode != null)
            {
                currentAttackMode.OnDead();
            }
        }
Exemplo n.º 3
0
        private bool SendRequestUseSkillDir(Skill readySkillObj)
        {
            VInt3          one = VInt3.one;
            BaseAttackMode currentAttackMode = this.Actor.handle.ActorControl.GetCurrentAttackMode();
            FrameCommand <UseDirectionalSkillCommand> command = FrameCommandFactory.CreateCSSyncFrameCommand <UseDirectionalSkillCommand>();

            if (currentAttackMode != null)
            {
                one = currentAttackMode.SelectSkillDirection(this);
            }
            command.cmdData.SlotType  = this.SlotType;
            command.cmdData.Direction = one;
            command.cmdData.iSkillID  = readySkillObj.SkillID;
            command.Send(true);
            return(true);
        }
Exemplo n.º 4
0
        protected override void OnDead()
        {
            base.OnDead();
            PoolObjHandle <ActorRoot> poolObjHandle = (!this.myLastAtker) ? this.myLastAtker : this.myLastAtker.get_handle().ActorControl.GetOrignalActor();

            if ((poolObjHandle && poolObjHandle.get_handle().TheActorMeta.ActorType == ActorTypeDef.Actor_Type_Hero) || base.IsKilledByHero())
            {
                this.contiKillNum = 0;
            }
            this.contiDeadNum++;
            this.actor.SkillControl.SkillUseCache.Clear();
            BaseAttackMode currentAttackMode = this.GetCurrentAttackMode();

            if (currentAttackMode != null)
            {
                currentAttackMode.OnDead();
            }
        }
Exemplo n.º 5
0
        private bool SendRequestUseSkillTarget(Skill readySkillObj)
        {
            uint           num = 0u;
            BaseAttackMode currentAttackMode = this.Actor.handle.ActorControl.GetCurrentAttackMode();
            FrameCommand <UseObjectiveSkillCommand> frameCommand = FrameCommandFactory.CreateCSSyncFrameCommand <UseObjectiveSkillCommand>();

            if (currentAttackMode != null)
            {
                num = currentAttackMode.SelectSkillTarget(this);
            }
            if (num == 0u)
            {
                return(false);
            }
            frameCommand.cmdData.ObjectID = num;
            frameCommand.cmdData.SlotType = this.SlotType;
            frameCommand.Send();
            return(true);
        }
Exemplo n.º 6
0
        private bool SendRequestUseSkillPos(Skill readySkillObj)
        {
            bool           flag = false;
            VInt3          zero = VInt3.zero;
            BaseAttackMode currentAttackMode = this.Actor.handle.ActorControl.GetCurrentAttackMode();
            FrameCommand <UsePositionSkillCommand> frameCommand = FrameCommandFactory.CreateCSSyncFrameCommand <UsePositionSkillCommand>();

            if (currentAttackMode != null)
            {
                flag = currentAttackMode.SelectSkillPos(this, out zero);
            }
            if (flag)
            {
                frameCommand.cmdData.Position = new VInt2(zero.x, zero.z);
                frameCommand.cmdData.SlotType = this.SlotType;
                frameCommand.Send();
                return(true);
            }
            return(false);
        }
        protected override void OnDead()
        {
            base.OnDead();
            if (!this.m_reviveContext.bEnable)
            {
                PoolObjHandle <ActorRoot> ptr = this.myLastAtker ? this.myLastAtker.handle.ActorControl.GetOrignalActor() : this.myLastAtker;
                if ((ptr && ptr.handle.TheActorMeta.ActorType == ActorTypeDef.Actor_Type_Hero) || base.IsKilledByHero())
                {
                    this.contiKillNum = 0;
                }
                this.contiDeadNum++;
            }
            this.actor.SkillControl.SkillUseCache.Clear();
            BaseAttackMode currentAttackMode = this.GetCurrentAttackMode();

            if (currentAttackMode != null)
            {
                currentAttackMode.OnDead();
            }
        }