Пример #1
0
 public override void LoadContent(ContentManager Content, GraphicsDevice graph, ref string level, ref string next, GraphicsDeviceManager graphics)
 {
     width = graphics.PreferredBackBufferWidth;
     height = graphics.PreferredBackBufferHeight;
           button = new Button(1, 3, width, height, 0.07f, 0.1f, 0);
     button.LoadContent(Content);
     button.activate(0, 0, 0.1f, 0.1f, "Last", LocalizedString.Replay );
     button.activate(0, 1, 0.1f, 0.2f, "", LocalizedString.Menu );
     button.activate(0, 2, 0.1f, 0.3f, "Exit", LocalizedString.Exit );
     background = Content.Load<Texture2D>("Menu//game_over");
 }
Пример #2
0
        public _Pause(Game1 game1, GraphicsDeviceManager graphics, ContentManager Content)
        {
            rectangle = new Rectangle(0, 0, graphics.PreferredBackBufferWidth, graphics.PreferredBackBufferHeight);
            game1.IsMouseVisible = true;
            MediaPlayer.Volume = vol;
            songMenu = Content.Load<Song>("Menu//songMenu");
            button = new Button(1, 4, graphics.PreferredBackBufferWidth, graphics.PreferredBackBufferHeight, 0.07f, 0.1f, 0);
            button.activate(0, 0, 0.1f, 0.1f, "Resume", LocalizedString.Resume );

            tab = 0;
        }
Пример #3
0
 public override void LoadContent(ContentManager Content, GraphicsDevice graph, ref string level, ref string next, GraphicsDeviceManager graphics)
 {
     width = graphics.PreferredBackBufferWidth;
     height = graphics.PreferredBackBufferHeight;
           titre_P = new Vector2(width * 0.8f, height * 0.1f);
     button = new Button(1, 3, width, height, 0.1f, 0.05f, 0);
     button.LoadContent(Content);
     button.activate(0, 0, 0.1f, 0.1f,"SEU", "1","SEU1");
     button.activate(0, 1, 0.1f, 0.2f,"Level2" , "2","level1");
     button.activate(0, 2, 0.1f, 0.3f, "", LocalizedString.Back );
     background = Content.Load<Texture2D>("Menu//background menu");
     titre = Content.Load<Texture2D>("Menu//pause//Menu");
 }
Пример #4
0
 public override void LoadContent(ContentManager Content, GraphicsDevice graph, ref string level, ref string next, GraphicsDeviceManager graphics)
 {
     width = graphics.PreferredBackBufferWidth;
     height = graphics.PreferredBackBufferHeight;
     titre_P = new Vector2(width * 0.8f, height * 0.1f);
     button = new Button(1, 4, width, height, 0.1f, 0.05f, 0);
     button.LoadContent(Content);
     button.activate(0, 0, 0.1f, 0.1f, "LevelSelect", LocalizedString.Play );
     button.activate(0, 1, 0.1f, 0.2f, "LevelSelect_P", LocalizedString.Map_Editor );
     button.activate(0, 2, 0.1f, 0.3f, "Option2", LocalizedString.Option );
     button.activate(0, 3, 0.1f, 0.4f, "Exit", LocalizedString.Exit );
     background = Content.Load<Texture2D>("Menu//background menu");
     titre = Content.Load<Texture2D>("Menu//pause//Menu");
 }
Пример #5
0
        public override void Initialize(GraphicsDeviceManager graphics)
        {
            list1 = new Listbox("SEU", 0.4f, 0.1f, 0.4f, 0.3f, width, height, 1);
            list2 = new Listbox("PLA", 0.4f, 0.5f, 0.4f, 0.3f, width, height, 2);
            tab = 0;
            MediaPlayer.Volume = vol;
            rectangle = new Rectangle(0, 0, graphics.PreferredBackBufferWidth, graphics.PreferredBackBufferHeight);
            butts = new Button(2, 3, width, height, 0.1f, 0.1f, 0);
            butts.activate(0, 0, 0.15f, 0.15f, "EditSEU", "Editeur de jeu1");
            butts.activate(0, 1, 0.15f, 0.5f, "EditPLA", "editeur de jeu2");

            butts.activate(0, 2, 0.15f, 0.85f, "", "retour");

            butts.activate(1, 0, 0.85f, 0.15f, "LevelEdit", "jouer");
            butts.activate(1, 1, 0.85f, 0.5f, "play", "jouer");
            butts.disable(1, 2);

            oldkey = Keyboard.GetState();
        }