Example #1
0
        public Aides()
        {
            continuRetour = new Texte(TurkeySmashGame.manager.PreferredBackBufferWidth * 0.2f, TurkeySmashGame.manager.PreferredBackBufferHeight * 0.85f);
            continuRetour.Texte = Langue.French ?"Continuer" : "Next";
            texteBoutons.Add(continuRetour);
            aidesImages = new Sprite();

            continuRetour.NameFont = "MenuFont";
        }
Example #2
0
        public void Load(Character[] players)
        {
            timerFont = new Font(TurkeySmashGame.WindowSize.X / 2, TurkeySmashGame.WindowSize.Y / 10);
            timerFont.NameFont = "Pourcent";
            timerFont.Load(TurkeySmashGame.content);
            timerFont.SizeText = 1.0f;
            if (SelectionNiveau.niveauSelect == "level1")
                timerFont.Color = Color.Black;
            else
             timerFont.Color = Color.White;

            if (OptionsCombat.TypePartieSelect == "temps")
                timer = OptionsCombat.TempsPartie * 60000 ; //60*1000 = 1 min en millisecond
            else
                timer = 0;

            for (int i = 0; i < players.Length; i++)
            {
                if (players[i] != null)
                {
                    pourcentages[i] = new Font((i + 1) * (TurkeySmashGame.manager.PreferredBackBufferWidth / 5),
                                            (7 * TurkeySmashGame.manager.PreferredBackBufferHeight / 8));
                    pourcentages[i].NameFont = "Pourcent";
                    pourcentages[i].Load(TurkeySmashGame.content);
                    pourcentages[i].SizeText = 1.3f;

                    icone[i] = new Sprite((i + 1) * (TurkeySmashGame.manager.PreferredBackBufferWidth / 5) - 250,
                                        (7 * TurkeySmashGame.manager.PreferredBackBufferHeight / 8 - 120));
                    if (OptionsCombat.TypePartieSelect == "vie")
                    {
                        xlife[i] = new Font((i + 1) * (TurkeySmashGame.manager.PreferredBackBufferWidth / 5),
                            4 * TurkeySmashGame.manager.PreferredBackBufferHeight / 5);

                        iconeLife[i] = new Sprite((i + 1) * (TurkeySmashGame.manager.PreferredBackBufferWidth / 5) - 50
                            ,TurkeySmashGame.manager.PreferredBackBufferHeight * 0.78f);

                        xlife[i].NameFont = "Pourcent";
                        xlife[i].Load(TurkeySmashGame.content);
                        xlife[i].SizeText = 0.5f;
                    }
                    if (OptionsCombat.TypePartieSelect == "temps")
                    {
                        scores[i] = new Font((i + 1) * (TurkeySmashGame.manager.PreferredBackBufferWidth / 5),
                            4 * TurkeySmashGame.manager.PreferredBackBufferHeight / 5);
                        scores[i].NameFont = "Pourcent";
                        scores[i].Load(TurkeySmashGame.content);
                        scores[i].SizeText = 0.6f;
                    }

                    if (players[i].definition.AssetName == "Jeu\\naruto")
                    {
                        icone[i].Load(TurkeySmashGame.content, "HUD\\HUDnaruto");
                        if (OptionsCombat.TypePartieSelect == "vie")
                            iconeLife[i].Load(TurkeySmashGame.content, "HUD\\HUDnarutoLifeIcone");
                    }

                    if (players[i].definition.AssetName == "Jeu\\sakura")
                    {
                        icone[i].Load(TurkeySmashGame.content, "HUD\\HUDSakura");
                        if (OptionsCombat.TypePartieSelect == "vie")
                            iconeLife[i].Load(TurkeySmashGame.content, "HUD\\HUDsakuraLifeIcone");
                    }

                    if (players[i].definition.AssetName == "Jeu\\sai")
                    {
                        icone[i].Load(TurkeySmashGame.content, "HUD\\HUDsai");
                        if (OptionsCombat.TypePartieSelect == "vie")
                            iconeLife[i].Load(TurkeySmashGame.content, "HUD\\HUDsaiLifeIcone");
                    }

                    if (players[i].definition.AssetName == "Jeu\\suigetsu")
                    {
                        icone[i].Load(TurkeySmashGame.content, "HUD\\HUDsuigetsu");
                        if (OptionsCombat.TypePartieSelect == "vie")
                            iconeLife[i].Load(TurkeySmashGame.content, "HUD\\HUDsuigetsuLifeIcone");
                    }
                    if (players[i].definition.AssetName == "Jeu\\turkey")
                    {
                        icone[i].Load(TurkeySmashGame.content, "HUD\\HUDTurkey");
                        if (OptionsCombat.TypePartieSelect == "vie")
                            iconeLife[i].Load(TurkeySmashGame.content, "HUD\\HUDTurkeyLifeIcone");
                    }
                }
            }
        }