Castle.CastleGame.Initialize C# (CSharp) Method

Initialize() protected method

protected Initialize ( ) : void
return void
        protected override void Initialize()
        {
            // Let the XNA framework show the mouse.
            IsMouseVisible = true;
            IsFixedTimeStep = true;

            // Initialize the SadConsole engine and the first effects library (provided by the SadConsole.Effects.dll binary)
            SadConsole.Engine.Initialize(graphics, "Cheepicus12.font", 40, 25);

            // Tell SadConsole to track the mouse.
            SadConsole.Engine.UseMouse = true;

            // Create the default console, show the cursor, and let the console accept keyboard input.
            gameMenuConsole = new GameMenuConsole();
            gameMenuConsole.PlayGame += StartGame;

            // Add the default console to the list of consoles.
            SadConsole.Engine.ConsoleRenderStack = new ConsoleList() {
                                                                        gameMenuConsole
                                                                     };
            SadConsole.Engine.ConsoleRenderStack[0].IsVisible = true;

            // Set the first console in the console list as the "active" console. This allows the keyboard to be processed on the console.
            SadConsole.Engine.ActiveConsole = SadConsole.Engine.ConsoleRenderStack[0];

            // Call the default initialize of the base class.
            base.Initialize();
        }