Example #1
0
        public static void Init()
        {
            GameMgr.CurrentPlatform        = Platform.Windows;
            GameMgr.CurrentGraphicsBackend = GraphicsBackend.DirectX;

            StuffResolver.AddStuffAs <IAlphaBlendEffectLoader>(new AlphaBlendEffectLoaderWindowsDX());
            StuffResolver.AddStuffAs <ITextInputBinder>(new TextInputBinderWindowsDX());
        }
Example #2
0
        public static void Init()
        {
            if (Environment.OSVersion.Platform == PlatformID.Win32NT)
            {
                GameMgr.CurrentPlatform = Platform.Windows;
            }
            else if (Environment.OSVersion.Platform == PlatformID.Unix)
            {
                GameMgr.CurrentPlatform = Platform.Linux;
            }
            else if (Environment.OSVersion.Platform == PlatformID.MacOSX)
            {
                GameMgr.CurrentPlatform = Platform.MacOS;
            }
            else
            {
                GameMgr.CurrentPlatform = Platform.Other;
            }

            GameMgr.CurrentGraphicsBackend = GraphicsBackend.OpenGL;

            StuffResolver.AddStuffAs <IAlphaBlendEffectLoader>(new AlphaBlendEffectLoaderDesktopGl());
            StuffResolver.AddStuffAs <ITextInputBinder>(new TextInputBinderDesktopGL());
        }