Ejemplo n.º 1
0
        public override void Intro( params object [] args )
        {
            Core.GraphicsDevice.ImmediateContext.BlendState = BlendState.AlphaBlend;

            Add ( InputHelper.Instance );
            Add ( calc = new FpsCalculator () );

            contentManager = new ResourceTable ( FileSystemManager.GetFileSystem ( "ManifestFileSystem" ) );
            Texture2DContentLoader.AddDefaultDecoders ();

            textures = new ITexture2D [ 6 ];
            textures [ 0 ] = contentManager.Load<ITexture2D> ( "Resources/PerformanceTest/0096x0096.tga" );
            textures [ 1 ] = contentManager.Load<ITexture2D> ( "Resources/PerformanceTest/0128x0128.png" );
            textures [ 2 ] = contentManager.Load<ITexture2D> ( "Resources/PerformanceTest/0256x0256.png" );
            textures [ 3 ] = contentManager.Load<ITexture2D> ( "Resources/PerformanceTest/0512x0512.png" );
            textures [ 4 ] = contentManager.Load<ITexture2D> ( "Resources/PerformanceTest/1024x1024.png" );
            textures [ 5 ] = contentManager.Load<ITexture2D> ( "Resources/PerformanceTest/2048x2048.png" );

            nodes = new Node [ 6 ];
            for ( int i = 0; i < 6; ++i )
            {
                nodes [ i ] = Add ( new Node () );
            }

            base.Intro ( args );
        }
Ejemplo n.º 2
0
        public override void Intro( params object [] args )
        {
            Core.Window.Title = "Simple Dodge";
            Core.GraphicsDevice.ImmediateContext.BlendState = BlendState.AlphaBlend;

            Add ( InputHelper.Instance );
            InputHelper.IsKeyboardEnabled = true;
            Add ( SceneContainer = new SceneContainer ( new MenuScene () ) );
            SceneContainer.SceneTransitor = new FadeTransitor ();

            contentManager = new ResourceTable ( FileSystemManager.GetFileSystem ( "ManifestFileSystem" ) );
            fpsFont = contentManager.Load<TrueTypeFont> ( "Resources/test.ttf", 20 );

            Add ( calc = new FpsCalculator () );

            base.Intro ( args );
        }