Beispiel #1
0
        private static void Main(string[] args)
        {
            //Make exceptions be english (wtf microsoft???)
            System.Threading.Thread.CurrentThread.CurrentUICulture = CultureInfo.InvariantCulture;

            Window = new GameWindow(1280, 720, GraphicsMode.Default, "MinecraftClone3")
            {
                CursorVisible         = false,
                TargetUpdateFrequency = 120,
                VSync = VSyncMode.On
            };
            Window.Closed         += WindowOnClosed;
            Window.Resize         += WindowOnResize;
            Window.FocusedChanged += WindowOnFocusedChanged;
            Window.UpdateFrame    += WindowOnUpdateFrame;
            Window.RenderFrame    += WindowOnRenderFrame;

            StateEngine.AddState(new GuiResourceLoading(Window));

            Window.Run();

            /*
             * PlayerController.SetEntity(_playerEntity);
             *
             * _world = new WorldServer();
             * _world.PlayerEntities.Add(_playerEntity);
             *
             * _projection = Matrix4.CreatePerspectiveFieldOfView(MathHelper.DegreesToRadians(60), (float)Window.Width/Window.Height, 0.01f, 512);
             */
        }