예제 #1
0
        // The program's start point, entered from the Launcher
        // RuntimeConfiguration is provided
        public static void Start(RuntimeConfiguration rtc)
        {
            Runtime = rtc;

            //Create the Ruby instance
            Ruby = new Ruby();

            Window = new GameWindow(Runtime.GetDefaultResolutionWidth(), Runtime.GetDefaultResolutionHeight());

            Window.Icon = Properties.Resources.OpenGame;

            Window.Resize += (sender, e) => { OnResize(sender, e); };

            Window.Closed += (sender, e) => { OnClose(sender, e); };

            Window.Visible = true;
            OnLoad();

            //Start the game
            Ruby.Start();

            //Clean up the Ruby instance
            Ruby.Dispose();
        }