Example #1
0
        public override void Update(GameTime gameTime)
        {
            if (_currentLavaHealthSprite != null)
            {
                _currentLavaHealthSprite.Update(gameTime);
            }

            if (_currentIceHealthSprite != null)
            {
                _currentIceHealthSprite.Update(gameTime);
            }
        }
        public override void Update(GameTime gameTime)
        {
            if (_currentTemperatureSprite == null)
            {
                return;
            }

            _timer -= (float)gameTime.ElapsedGameTime.TotalSeconds;

            if (_currentTemperaturePathSprite.Count > 0 && _timer <= 0.0f)
            {
                _currentTemperatureSprite = _currentTemperaturePathSprite[0];
                _currentTemperaturePathSprite.Remove(_currentTemperatureSprite);

                _timer = _duration;
            }

            _currentTemperatureSprite.Update(gameTime);
        }