示例#1
0
文件: Game1.cs 项目: bagnalla/RTS
        protected override void Initialize()
        {
            Graphics.PreferredBackBufferWidth  = 1024;
            Graphics.PreferredBackBufferHeight = 740;
            Graphics.ApplyChanges();

            Direction.Init();
            CommandCard.Init();

            fpsCounter = new FpsCounter(Game);
            Components.Add(fpsCounter);
            fpsCounter.DrawOrder = 0;
            //fpsCounter.Enabled = true;

            SoundEffectManager = new SoundEffectManager(Game);
            Components.Add(SoundEffectManager);
            SoundEffectManager.DrawOrder = 1;
            //soundEffectManager.DrawDebugInfo = true;

            DebugMonitor = new DebugMonitor(Game);
            Components.Add(DebugMonitor);
            DebugMonitor.Enabled  = true;
            DebugMonitor.DrawBox  = true;
            DebugMonitor.Position = Direction.SouthEast;

            ColorTexture.Initialize(GraphicsDevice);

            currentGameState = new Rts(RtsEventHandler);

            base.Initialize();
        }
示例#2
0
文件: Game1.cs 项目: nubington/rts
        protected override void Initialize()
        {
            Graphics.PreferredBackBufferWidth = 1024;
            Graphics.PreferredBackBufferHeight = 740;
            Graphics.ApplyChanges();

            Direction.Init();
            CommandCard.Init();

            fpsCounter = new FpsCounter(Game);
            Components.Add(fpsCounter);
            fpsCounter.DrawOrder = 0;
            //fpsCounter.Enabled = true;

            SoundEffectManager = new SoundEffectManager(Game);
            Components.Add(SoundEffectManager);
            SoundEffectManager.DrawOrder = 1;
            //soundEffectManager.DrawDebugInfo = true;

            DebugMonitor = new DebugMonitor(Game);
            Components.Add(DebugMonitor);
            DebugMonitor.Enabled = true;
            DebugMonitor.DrawBox = true;
            DebugMonitor.Position = Direction.SouthEast;

            ColorTexture.Initialize(GraphicsDevice);

            currentGameState = new Rts(RtsEventHandler);

            base.Initialize();
        }
示例#3
0
        protected override void Initialize()
        {
            //Graphics.PreferredBackBufferWidth = 1024;
            //Graphics.PreferredBackBufferHeight = 740;
            //Graphics.PreferredBackBufferWidth = 1280;
            //Graphics.PreferredBackBufferHeight = 720;

            Graphics.PreferredBackBufferWidth  = 1024;
            Graphics.PreferredBackBufferHeight = 576;
            //Graphics.IsFullScreen = true;
            Graphics.ApplyChanges();

            Window.Title = "";

            IsMouseVisible = true;

            Direction.Init();
            CommandCard.Init();
            UnitType.Init();
            StructureType.Init();

            fpsCounter = new FpsCounter(Game);
            Components.Add(fpsCounter);
            fpsCounter.DrawOrder = 0;
            //fpsCounter.Enabled = true;

            SoundEffectManager = new SoundEffectManager(Game);
            Components.Add(SoundEffectManager);
            SoundEffectManager.DrawOrder = 1;
            //soundEffectManager.DrawDebugInfo = true;

            DebugMonitor = new DebugMonitor(Game);
            Components.Add(DebugMonitor);
            DebugMonitor.Enabled  = true;
            DebugMonitor.DrawBox  = true;
            DebugMonitor.Position = Direction.SouthEast;

            ColorTexture.Initialize(GraphicsDevice);

            spriteBatch = new SpriteBatch(GraphicsDevice);

            //CurrentGameState = new Rts(RtsEventHandler);
            CurrentGameState = new StartMenu(StartMenuEventHandler);

            base.Initialize();
        }
示例#4
0
文件: Game1.cs 项目: nubington/rts
        protected override void Initialize()
        {
            //Graphics.PreferredBackBufferWidth = 1024;
            //Graphics.PreferredBackBufferHeight = 740;
            //Graphics.PreferredBackBufferWidth = 1280;
            //Graphics.PreferredBackBufferHeight = 720;
            Graphics.PreferredBackBufferWidth = 1024;
            Graphics.PreferredBackBufferHeight = 576;
            Graphics.ApplyChanges();

            Window.Title = "";

            IsMouseVisible = true;

            Direction.Init();
            CommandCard.Init();
            UnitType.Init();
            StructureType.Init();

            fpsCounter = new FpsCounter(Game);
            Components.Add(fpsCounter);
            fpsCounter.DrawOrder = 0;
            //fpsCounter.Enabled = true;

            SoundEffectManager = new SoundEffectManager(Game);
            Components.Add(SoundEffectManager);
            SoundEffectManager.DrawOrder = 1;
            //soundEffectManager.DrawDebugInfo = true;

            DebugMonitor = new DebugMonitor(Game);
            Components.Add(DebugMonitor);
            //DebugMonitor.Enabled = true;
            DebugMonitor.DrawBox = true;
            DebugMonitor.Position = Direction.SouthEast;

            ColorTexture.Initialize(GraphicsDevice);

            spriteBatch = new SpriteBatch(GraphicsDevice);

            //CurrentGameState = new Rts(RtsEventHandler);
            CurrentGameState = new StartMenu(StartMenuEventHandler);

            base.Initialize();
        }