示例#1
0
    /// <summary>
    /// Update
    /// </summary>
    private void Update()
    {
        if (this.lifeTime <= 0f)
        {
            //寿命が尽きたので終了
            Destroy(this.gameObject);
            return;
        }

        float deltaTime = BattleGlobal.GetDeltaTime(ref this.timeStamp);
        this.lifeTime -= deltaTime;
    }
示例#2
0
    /// <summary>
    /// Update
    /// </summary>
    private void Update()
    {
        float deltaTime = BattleGlobal.GetDeltaTime(ref timeStamp);
        int loopCount = (int)(deltaTime / SharkDefine.DELTATIME);

        for (int i = 0; i < loopCount + 1; i++)
        {
            float _deltaTime = Mathf.Min(deltaTime, SharkDefine.DELTATIME);
            deltaTime -= _deltaTime;

            this.controller?.Update(_deltaTime);
        }
    }
示例#3
0
    /// <summary>
    /// Update
    /// </summary>
    private void Update()
    {
        //Stayイベントは1フレームだけしか聞かない
        this.bulletBase.bulletCollider.stayEventReceiver = null;

        float deltaTime = BattleGlobal.GetDeltaTime(ref timeStamp);
        int loopCount = (int)(deltaTime / SharkDefine.DELTATIME);

        for (int i = 0; i < loopCount + 1; i++)
        {
            float _deltaTime = Mathf.Min(deltaTime, SharkDefine.DELTATIME);
            deltaTime -= _deltaTime;

            this.controller?.Update(_deltaTime);
        }
    }