/// <summary> /// Initializes input manager, rendering engine, game object and so on. /// </summary> private void Initialize() { GameScreen = new ConsoleGameScreen(); InputManager = new InputManager(); InputManager.AddInputDevice(new KeyboardInputDevice()); Snake = new Snake(Direction.Down, new []{new Coord(10,10), new Coord(10,11), new Coord(10,12)}); SnakeView = new SnakeView(Snake); Apple = Apple.Create(GenerateRandomCoordinate(Snake.Body)); AppleView = new AppleView(Apple); RenderingEngine = new RenderingEngine(); RenderingEngine.AddView(AppleView); RenderingEngine.AddView(SnakeView); GameTimer = new Stopwatch(); }