Esempio n. 1
0
        public override void Update(float delta)
        {
            if (!_player.UnlockCamera)
            {
                _camera.Approach(new Vector2(_player.RenderX, _player.RenderY), 0.25f);
            }

            _soundEffectManager.Update();
            _lightingManager.Update(delta);

            _mapRenderer.Update(delta);
            _effectsRenderer.Update(delta);

            _map.Update(delta);

            if (!_eventManager.HasEventsToProcess())
            {
                _turnResult = _turnManager.Process();
                _eventManager.AddEvents(_turnResult.Events);

                if (_turnResult.MadeProgress)
                {
                    _map.ClearFov();
                    _fov.RefreshVisibility(new Point2D(_player.X, _player.Y), 8);
                }
            }

            _eventManager.Update(delta);
            _interfaceRenderer.Update(delta);
        }