public Font(Game game, SpriteBatch spriteBatch, FontDescription fontDescription) : base(game) { this.spriteBatch = spriteBatch; this.fontDescription = fontDescription; }
public StartScreen(Game game, SpriteBatch spriteBatch, Action<ScreenManager.GameScreen> navigateToScreen) : base(game, spriteBatch, navigateToScreen) { ScreenGameComponents.Add(new NonAnimatedSprite(game, "Images/Background/titleLetters", DrawablePosition.TopCentered, spriteBatch)); // Font for the start button FontDescription startFontDescription = new FontDescription( "Fonts/TitleFont", "Start!", Color.Red, Vector2.Zero); Button startButton = new Button(game, spriteBatch, new ButtonDescription(startFontDescription, DrawablePosition.BottomCentered, new Vector2(200, 100))); startButton.ButtonClicked = StartButtonWasClicked; ScreenGameComponents.Add(startButton); }
public ButtonDescription(FontDescription fontDescription, DrawablePosition fixedPosition, Vector2 size) { FontDescription = fontDescription; FixedPosition = fixedPosition; Size = size; }
public ButtonDescription(FontDescription fontDescription, Vector2 position, Vector2 size) { FontDescription = fontDescription; Position = position; Size = size; }