예제 #1
0
        public void Update(float deltaTime)
        {
            UpdateProjSpecific(deltaTime);

            if (inWater)
            {
                body.ApplyWaterForces();
            }

            if (isSevered)
            {
                severedFadeOutTimer += deltaTime;
                if (severedFadeOutTimer >= SeveredFadeOutTime)
                {
                    body.Enabled = false;
                }
                else if (character.CurrentHull == null && Hull.FindHull(WorldPosition) != null)
                {
                    severedFadeOutTimer = SeveredFadeOutTime;
                }
            }

            if (attack != null)
            {
                attack.UpdateCoolDown(deltaTime);
            }
        }
예제 #2
0
        public void Update(float deltaTime)
        {
            UpdateProjSpecific(deltaTime);

            if (inWater)
            {
                body.ApplyWaterForces();
            }

            if (isSevered)
            {
                severedFadeOutTimer += deltaTime;
                if (severedFadeOutTimer > SeveredFadeOutTime)
                {
                    body.Enabled = false;
                }
            }

            if (attack != null)
            {
                attack.UpdateCoolDown(deltaTime);
            }
        }