Exemplo n.º 1
0
 /// <summary>
 /// The main entry point for the application.
 /// </summary>
 static void Main(string[] args)
 {
     using (Game1 game = new Game1())
     {
         game.Run();
     }
 }
Exemplo n.º 2
0
Arquivo: Menu.cs Projeto: ttocs7/menus
        public Menu(Game1 game, List<string> items)
        {
            fadetime = TimeSpan.FromSeconds(0.2);

            this.game = game;

            spriteBatch = new SpriteBatch(game.GraphicsDevice);
            blanksprite = game.Content.Load<Texture2D>("blanksprite");
            menusprite = game.Content.Load<Texture2D>("menusprite");
            font = game.Content.Load<SpriteFont>("SpriteFont1");

            input = new Input();

            this.items = new List<string>();
            this.items.AddRange(items);
            listCount = items.Count() - 1;
        }
Exemplo n.º 3
0
Arquivo: Menu.cs Projeto: ttocs7/menus
        public Menu(Game1 game)
        {
            fadetime = TimeSpan.FromSeconds(0.2);

            this.game = game;

            spriteBatch = new SpriteBatch(game.GraphicsDevice);
            blanksprite = game.Content.Load<Texture2D>("blanksprite");
            menusprite = game.Content.Load<Texture2D>("menusprite");
            font = game.Content.Load<SpriteFont>("SpriteFont1");

            input = new Input();

            items = new List<string>();
            this.items.Add("PAUSED");
            this.items.Add("Continue Game");
            this.items.Add("Exit Game");

            listCount = 2;
        }