Esempio n. 1
0
        public DemoGame(Options options, IGamePlatformFactory gamePlatformFactory, IGraphicsFactory graphicsFactory, IInputFactory inputFactory)
            : base(options, gamePlatformFactory, graphicsFactory, inputFactory)
        {
            _options        = options;
            _textureFactory = graphicsFactory.CreateTextureFactory();

            _camera = new Camera(new Vector3(0, 0, 5), _options.Graphics.Resolution.Width / (float)_options.Graphics.Resolution.Height);
        }
Esempio n. 2
0
        protected GameBase(Options options, IGamePlatformFactory gamePlatformFactory, IGraphicsFactory graphicsFactory, IInputFactory inputFactory)
        {
            _options             = options;
            _gamePlatformFactory = gamePlatformFactory;
            GraphicsFactory      = graphicsFactory;
            _inputFactory        = inputFactory;
            _inputMapper         = new InputMapper(_inputFactory);

            _gameLoop = _gamePlatformFactory.CreateGameLoop();
        }