コード例 #1
0
        public override void LateUpdateState()
        {
            base.LateUpdateState();

            if (!this.IsActiveState)
            {
                return;
            }

            // check if anim is finished

            if (null == m_animState || !m_animState.enabled)
            {
                // anim finished
                // switch to other state

                // try to switch to crouch aim state
                CrouchState.SwitchToAimState(m_ped);
                if (!this.IsActiveState)
                {
                    return;
                }

                // switch to crouch state
                m_ped.SwitchState <CrouchState>();
            }
        }
コード例 #2
0
        protected override void UpdateAnims()
        {
            base.UpdateAnims();

            //	if( !this.IsActiveState )
            //		return;

            CrouchState.AdjustRootFramePosition(m_ped);
        }
コード例 #3
0
        protected override void UpdateAnims()
        {
            base.UpdateAnims();

            //	if( !this.IsActiveState )
            //		return;

            // anim does not set correct velocity
            // set it to zero to make the ped stand in place
            // this should be done even if parent method changed active state
            if (m_model.RootFrame != null)
            {
                m_model.RootFrame.LocalVelocity = Vector3.zero;
            }

            //	if( !this.IsActiveState )
            //		return;

            CrouchState.AdjustRootFramePosition(m_ped);
        }
コード例 #4
0
 protected override void SwitchToAimState()
 {
     CrouchState.SwitchToAimState(m_ped);
 }
コード例 #5
0
 protected override void SwitchToAimState()
 {
     // can only switch to CrouchAim state
     CrouchState.SwitchToAimState(m_ped);
 }