public StartScreen() { BattleGUI.InitializeResources(); bIsRunning = true; r2d = new RenderTarget2D(Game1.graphics.GraphicsDevice, 1366, 768); bg.texFileLoc = @"Graphics\StartScreen\StartBG"; bg.animationFrames.Add(new Rectangle(0, 0, 1366, 768)); bg.ReloadTexture(); sf = Game1.contentManager.Load <SpriteFont>(@"Fonts\Design\BGUI\test48"); //testSF = Game1.contentManager.Load<SpriteFont>(@"Fonts\Design\BGUI\test"); //testSF20 = Game1.contentManager.Load<SpriteFont>(@"Fonts\Design\BGUI\test20"); //testSF25 = Game1.contentManager.Load<SpriteFont>(@"Fonts\Design\BGUI\test25"); //testSF32 = Game1.contentManager.Load<SpriteFont>(@"Fonts\Design\BGUI\test32"); //testSF48 = Game1.contentManager.Load<SpriteFont>(@"Fonts\Design\BGUI\test48"); int width = 800; int deltaH = 28; int height = (400 - deltaH * 5) / 4; Rectangle b = new Rectangle((1366 - width) / 2, 400, 800, height); mButtons.Add(new SCButton(b, sf, "New Game")); b.Y += height + deltaH; mButtons.Add(new SCButton(b, sf, "Load Game")); b.Y += height + deltaH; mButtons.Add(new SCButton(b, sf, "Settings")); b.Y += height + deltaH; mButtons.Add(new SCButton(b, sf, "Exit Game")); sc = this; Utilities.Control.Player.PlayerController.InitializeStartScreenControls(this); }
static public void Initialize() { if (!bInitialized) { BattleGUI.InitializeResources(); bInitialized = true; sf32 = BattleGUI.testSF32; sf48 = BattleGUI.testSF48; } }