示例#1
0
 protected void DoDownProgress(IRecordFile sender, int progress, DownState state)
 {
     if (OnDownProgress != null)
     {
         OnDownProgress(sender, progress, state);
     }
 }
示例#2
0
 private void DoRecordFileDownProgress(IRecordFile sender, int progress, DownState state)
 {
     if (OnRecordFileDownProgress != null)
     {
         OnRecordFileDownProgress(sender, progress, state);
     }
 }
示例#3
0
 /// <summary>
 /// 初期化処理
 /// </summary>
 void Start()
 {
     // コンポーネントを取得
     playerGlide  = GetComponent <PlayerGlide>();
     character    = GetComponent <Player>();
     aerialState  = GetComponent <AerialState>();
     runState     = GetComponent <RunState>();
     downState    = GetComponent <DownState>();
     playerCharge = GetComponent <PlayerCharge>();
     playerAttack = GetComponent <PlayerAttack>();
 }
示例#4
0
 private void SetState(DownState value)
 {
     if (_State != value)
     {
         _State = value;
         if (StateChange != null)
         {
             StateChange(this, value);
         }
     }
 }
示例#5
0
        private void DoDownProgress(IRecordFile sender, int progress, DownState state)
        {
            if (progress == 100 || state != DownState.Norme)
            {
                sender.OnDownProgress -= new RECORDFILE_DOWNPROGRESS(DoDownProgress);

                if (progress == 100)
                {
                    MessageBox.Show(string.Format("下载{0}结束", sender.LocalFileName));
                }
            }
        }
示例#6
0
        private void DoDownProgress(int progress, DownState state)
        {
            CLocalSystem.WriteInfoLog(string.Format("\"{0}\"下载进度:{1}% 状态:{2}", LocalFileName, progress, state));

            if (OnDownProgress != null)
            {
                OnDownProgress(this, mProgress, state);
            }
            else if (progress == 100)
            {
                MessageBox.Show(string.Format("文件({0})下载结束!", this.LocalFileName));
            }
        }
示例#7
0
文件: Player.cs 项目: SDCGT/Product02
    void Start()
    {
        //ani = GetComponent<Animation>();

        IdleState   idle   = new IdleState(1, this);
        LeftState   left   = new LeftState(2, this);
        RightState  right  = new RightState(3, this);
        UpState     up     = new UpState(4, this);
        DownState   down   = new DownState(5, this);
        AttackState attack = new AttackState(6, this);

        machine = new StateMachine(idle);
        machine.AddState(left);
        machine.AddState(right);
        machine.AddState(up);
        machine.AddState(down);
        machine.AddState(attack);
    }
示例#8
0
    /// <summary>
    /// 初期化処理
    /// </summary>
    void Awake()
    {
        // 子オブジェクトを取得
        feverEffect       = transform.Find("FeverEffect").GetComponent <ParticleSystem>();
        boostEffect       = transform.Find("BoostEffect").GetComponent <ParticleSystem>();
        chargeingEffect   = transform.Find("ChargeEffects/Charging").GetComponent <ParticleSystem>();
        chargeSignal      = transform.Find("ChargeEffects/ChargeSignal").GetComponent <ParticleSystem>();
        chargePauseEffect = transform.Find("ChargeEffects/ChargePause").GetComponent <ParticleSystem>();
        chargeMaxEffect   = transform.Find("ChargeEffects/ChargeMax").GetComponent <ParticleSystem>();

        // アタッチされているステートを取得
        aerialState     = GetComponent <AerialState>();
        afterSlideState = GetComponent <AfterSlideState>();
        boostState      = GetComponent <BoostState>();
        downState       = GetComponent <DownState>();
        glideState      = GetComponent <GlideState>();
        idleState       = GetComponent <IdleState>();
        runState        = GetComponent <RunState>();
        slideState      = GetComponent <SlideState>();
        afterGoalState  = GetComponent <AfterGoalState>();

        // ステートを管理するクラスを取得
        playerStateManager = new PlayerStateManager();
    }
 public DownTransition(Player _player)
 {
     player    = _player;
     nextState = new DownState(_player);
 }