Esempio n. 1
0
        /// <summary>
        /// Fonction qui exécute l'attaque entre deux Pokémons.
        /// </summary>
        /// <param name="attaquant">Le Pokémon qui attaque</param>
        /// <param name="opposant">Le Pokémon qui se fait attaquer</param>
        /// <param name="attaqueChoisie">L'attaque qui a été choisie</param>
        void EffectuerAttaque(Pokemon attaquant, Pokemon opposant, Attaque attaqueChoisie)
        {
            int nombreAléatoire = Générateur.Next(0, 101);

            if (nombreAléatoire <= attaqueChoisie.Accuracy)//attaque!
            {
                //on va faire une attaque classique, ensuite on applique pardessus l'effet plus complexe peu importe l'attaque
                if (attaqueChoisie.EstUneAttaqueSpéciale() && attaqueChoisie.EstUneAttaqueAvecBasePowerValide())
                {
                    opposant.Défendre(CalculPointsDamageSpécial(attaquant, opposant, attaqueChoisie));
                }

                else if (attaqueChoisie.EstUneAttaquePhysique() && attaqueChoisie.EstUneAttaqueAvecBasePowerValide())
                {
                    opposant.Défendre(CalculPointsDamagePhysique(attaquant, opposant, attaqueChoisie));
                }

                Attaque.AppliquerEffetAttaque(attaquant, opposant, attaqueChoisie);
            }
            else
            {
                AfficheurTexte message = new AfficheurTexte(Game, PositionBox, Jeu.LargeurBoxMessage, Jeu.HauteurBoxMessage, "It missed!", IntervalMAJ);
                Game.Components.Add(message);
            }
        }
Esempio n. 2
0
        /// <summary>
        /// Fonction pour tenter d'attraper un Pokémon sauvage qui peut servir aussi hors combat.
        /// </summary>
        /// <param name="joueur">Le trainer qui tente d'attraper le Pokémon</param>
        /// <param name="opponent">Le Pokémon que l'on veut attraper</param>
        public void EssayerAttraperWildPokemon(Trainer joueur, Pokemon opponent)
        {
            bool valeurFormule = EffectuerFormuleGenI(opponent);

            if (valeurFormule)
            {
                AfficheurTexte message = new AfficheurTexte(Game, PositionBox, Jeu.LargeurBoxMessage, Jeu.HauteurBoxMessage, "Gotcha! " + opponent.Nom + " was caught!", IntervalMAJ);
                Game.Components.Add(message);

                joueur.AddPokemon(opponent);

                if (EnCombat)
                {
                    MainMenu.ItemPokeballEstUtilisé = false;
                    CombatState = CombatState.END;
                }
            }
            else
            {
                AfficheurTexte message = new AfficheurTexte(Game, PositionBox, Jeu.LargeurBoxMessage, Jeu.HauteurBoxMessage, "The wild " + opponent.Nom + " broke free!", IntervalMAJ);
                Game.Components.Add(message);

                if (EnCombat)
                {
                    MainMenu.ItemPokeballEstUtilisé = false;
                    TourUserComplété = true;
                    CombatState      = CombatState.TOUR_OPPONENT;
                }
            }
        }
Esempio n. 3
0
        /// <summary>
        /// Fonction qui affiche le message de l'attaque choisie par le joueur et l'effectue.
        /// </summary>
        /// <param name="attaqueSélectionnée">Numéro de l'attaque sélectionnée</param>
        void EffectuerTourUser(int attaqueSélectionnée)
        {
            string         messageTour = UserPokemon.Nom + " used " + UserPokemon[attaqueSélectionnée].ToString() + "!";
            AfficheurTexte message     = new AfficheurTexte(Game, PositionBox, Jeu.LargeurBoxMessage, Jeu.HauteurBoxMessage, messageTour, IntervalMAJ);

            Game.Components.Add(message);
            EffectuerAttaque(UserPokemon, OpponentPokemon, UserPokemon[attaqueSélectionnée]);
        }
Esempio n. 4
0
        /// <summary>
        /// Fonction de transition de défaite qui mène à la fin du combat.
        /// </summary>
        void GérerTransitionDEFEAT()
        {
            if (!EstOpponentSauvage)
            {
                AfficheurTexte messageA = new AfficheurTexte(Game, PositionBox, Jeu.LargeurBoxMessage, Jeu.HauteurBoxMessage, "Trainer " + OpponentTrainer.Nom + " won!", IntervalMAJ);
                Game.Components.Add(messageA);
            }
            AfficheurTexte messageB = new AfficheurTexte(Game, PositionBox, Jeu.LargeurBoxMessage, Jeu.HauteurBoxMessage, "You are out of pokemon. Please heal yourself to continue.", IntervalMAJ);

            Game.Components.Add(messageB);
            CombatState = CombatState.END;
        }
Esempio n. 5
0
 /// <summary>
 /// Fonction qui s'effectue quand le joueur sélectionne l'objet "Pokeball".
 /// </summary>
 void LancerUnePokeball()
 {
     if (EstOpponentSauvage)
     {
         EssayerAttraperWildPokemon(UserTrainer, OpponentPokemon);
     }
     else
     {
         AfficheurTexte message = new AfficheurTexte(Game, PositionBox, Jeu.LargeurBoxMessage, Jeu.HauteurBoxMessage, "You can't catch a trainer's pokemon!", IntervalMAJ);
         Game.Components.Add(message);
         CombatState = CombatState.TOUR_OPPONENT;
     }
 }
Esempio n. 6
0
        //public int AttaqueAléatoire()//Temp
        //{
        //    Attaque attaqueAléatoire;
        //    int index = 0;

        //    do
        //    {
        //        index = Générateur.Next(0, 4);
        //        attaqueAléatoire = AttaquesList[index];
        //    }
        //    while (AttaquesList[index] < 0);

        //    return attaqueAléatoire;
        //}
        public void GainExp(float valeur)
        {
            Exp = Exp + valeur;

            AfficheurTexte messageC = new AfficheurTexte(Game, Jeu.PositionBoxMessage, Jeu.LargeurBoxMessage, Jeu.HauteurBoxMessage, Nom + " gained " + ((int)valeur).ToString() + " exp.", Jeu.INTERVALLE_MAJ_STANDARD);

            Game.Components.Add(messageC);
            //si Exp dépasse un threshold, faire le level up : check if evolution, recalcul les stats, check if new move is learned
            if (Level < MAX_LEVEL && DoitLevelUp())
            {
                ExécuterSéquenceLevelUp();
            }
        }
Esempio n. 7
0
 /// <summary>
 /// Fonction de transition de victoire qui mène à la fin du combat.
 /// </summary>
 void GérerTransitionVICTORY()
 {
     if (!EstOpponentSauvage)
     {
         AfficheurTexte messageA = new AfficheurTexte(Game, PositionBox, Jeu.LargeurBoxMessage, Jeu.HauteurBoxMessage, "Trainer " + OpponentTrainer.Nom + " was defeated! ", IntervalMAJ);
         Game.Components.Add(messageA);
         //On peut ajouter un gain d'argent pour le joueur ici si l'on ajoute des magasins d'objets.
     }
     else
     {
         AfficheurTexte messageB = new AfficheurTexte(Game, PositionBox, Jeu.LargeurBoxMessage, Jeu.HauteurBoxMessage, "Wild " + OpponentPokemon.Nom + " fainted!", IntervalMAJ);
         Game.Components.Add(messageB);
     }
     DonnerExp();
     CombatState = CombatState.END;
 }
Esempio n. 8
0
        /// <summary>
        /// À chaque tour de boucle il vérifie l'état du niveau et appelle la classe nécessaire
        /// </summary>
        /// <param name="gameTime">le temps du jeu</param>
        public override void Update(GameTime gameTime)
        {
            Game.IsMouseVisible = true;
            Point point = GestionnaireManager.GetPositionSouris();

            PosSouris = new Vector2(point.X, point.Y);

            if (PartieEnCours.EstRéussi)
            {
                InitialiserMenuContinuer();
            }

            if (PartieEnCours.EstÉchec)
            {
                Vector2 PosTexte = new Vector2(Game.Window.ClientBounds.Width / 2, Game.Window.ClientBounds.Height / 2 - 150);
                AfficheurTexte = new AfficheurTexte(Game, Color.Red, PosTexte, "Vous avez échoué.", INTERVALLE_MOYEN);
                Game.Components.Add(AfficheurTexte);
                //Boutton Recommencer = new Boutton(Game, "Recommencer Niveau", new Rectangle(Game.Window.ClientBounds.Width / 2, Game.Window.ClientBounds.Height / 2 - 50,
                //LARGEUR_BOUTTON, HAUTEUR_BOUTTON), Color.Blue, "fond écran blanc", "FondEcranGris", NbSoldatsContinuer,
                //PartieEnCours.GetNbSections(), INTERVALLE_MOYEN);
                //Bouttons.Add(Recommencer);
                Bouttons.Add(Exit);
                //Bouttons.Add(Réinitialiser);
                //Game.Components.Add(Réinitialiser);
                //Game.Components.Add(Recommencer);
                Game.Components.Add(Exit);
                Afficheur = new AfficheurNb(Game, Color.Red, CompteurNiveau, new Vector2(0, 0), "Niveau :", INTERVALLE_MOYEN);
                Game.Components.Add(Afficheur);
                PartieEnCours.EstÉchec = false;
            }

            if (GestionnaireManager.EstSourisActive)
            {
                GestionBouttonsDeLaListe();


                if (EstDansBoutton(Mute))
                {
                    if (GestionnaireManager.EstNouveauClicGauche())
                    {
                        Mute.ChangerDeCouleur();
                        PartieEnCours.FaireJouerMusique();
                    }
                }
            }
            base.Update(gameTime);
        }
Esempio n. 9
0
        /// <summary>
        /// Initialise les différents boutton de difficulté
        /// </summary>
        public override void Initialize()
        {
            string son  = "icone son";
            string mute = "mute button";

            Rectangle temp = Game.Window.ClientBounds;

            RectangleAffichageMute = new Rectangle(0, temp.Height - MARGE_BAS, 60, 60);

            Bouttons         = new List <Boutton>();
            DifficultéFacile = new Boutton(Game, "Facile", new Rectangle(temp.Width - MARGE_DROITE, temp.Top + MARGE_BAS, LARGEUR_BOUTTON, HAUTEUR_BOUTTON), Color.Blue, NOM_IMAGE_AVANT, NOM_IMAGE_APRÈS,
                                           MAXIMUM_NOMBRE_SOLDAT, MINIMUM_NOMBRE_SECTION, INTERVALLE_MOYEN);
            DifficultéMoyenne = new Boutton(Game, "Moyen", new Rectangle(temp.Width - MARGE_DROITE, temp.Top + MARGE_BAS * 3, LARGEUR_BOUTTON, HAUTEUR_BOUTTON), Color.Blue, NOM_IMAGE_AVANT, NOM_IMAGE_APRÈS,
                                            MAXIMUM_NOMBRE_SOLDAT, MINIMUM_NOMBRE_SECTION + 10, INTERVALLE_MOYEN);
            DifficultéDifficile = new Boutton(Game, "Difficile", new Rectangle(temp.Width - MARGE_DROITE, temp.Top + MARGE_BAS * 5, LARGEUR_BOUTTON, HAUTEUR_BOUTTON), Color.Blue, NOM_IMAGE_AVANT, NOM_IMAGE_APRÈS,
                                              MAXIMUM_NOMBRE_SOLDAT, MINIMUM_NOMBRE_SECTION + 20, INTERVALLE_MOYEN);
            Mute = new Boutton(Game, " ", RectangleAffichageMute, Color.White, son, mute, 0, 0, INTERVALLE_MOYEN);

            Exit = new Boutton(Game, "Quitter", new Rectangle(temp.Width / 2 - LARGEUR_BOUTTON / 2, temp.Height / 2 + DISTANCE_ENTRE_BOUTTON_QUITTER, LARGEUR_BOUTTON, HAUTEUR_BOUTTON), Color.Blue, NOM_IMAGE_AVANT, NOM_IMAGE_APRÈS, 0, 0, INTERVALLE_MOYEN);

            Bouttons.Add(DifficultéFacile);
            Bouttons.Add(DifficultéMoyenne);
            Bouttons.Add(DifficultéDifficile);

            foreach (Boutton b in Bouttons)
            {
                Game.Components.Add(b);
            }

            PosInitialeNiveau = new Vector3(0, 0, 0);

            AnciennePosSouris = PosSouris;
            PartieEnCours     = new Jeu(Game, 0, PosInitialeNiveau, 0, INTERVALLE_MOYEN);

            CompteurNiveau = 0;
            Afficheur      = new AfficheurNb(Game, Color.Red, ++CompteurNiveau, new Vector2(0, 0), "Niveau :", INTERVALLE_MOYEN);
            Game.Components.Add(Afficheur);
            Vector2 PosTexte = new Vector2(Game.Window.ClientBounds.Width / 4, Game.Window.ClientBounds.Height / 4);

            AfficheurTexte = new AfficheurTexte(Game, Color.Red, PosTexte, "Army Run!", INTERVALLE_MOYEN);
            Game.Components.Add(AfficheurTexte);
            NbSoldatsContinuer = 30;
            BouttonMute        = true;

            base.Initialize();
        }
Esempio n. 10
0
        /// <summary>
        /// Fonction qui change le Pokémon de l'adversaire s'il lui en reste qui sont vivants.
        /// </summary>
        void ChangerOpponentPokemon()
        {
            TourOpponentComplété = false;
            TourUserComplété     = false;
            AfficheurTexte messageA = new AfficheurTexte(Game, PositionBox, Jeu.LargeurBoxMessage, Jeu.HauteurBoxMessage, OpponentTrainer.Nom + "'s " + OpponentPokemon.Nom + " fainted!", IntervalMAJ);

            Game.Components.Add(messageA);

            OpponentPokemon = OpponentTrainer.NextPokemonEnVie();
            NomOpponentPokemon.RemplacerMessage(OpponentPokemon.ToString());
            VieOpponentPokemon.RemplacerMessage(OpponentPokemon.VieToString());

            string         messageTour = OpponentTrainer.Nom + " send out " + OpponentPokemon.Nom + "!";
            AfficheurTexte messageB    = new AfficheurTexte(Game, PositionBox, Jeu.LargeurBoxMessage, Jeu.HauteurBoxMessage, messageTour, IntervalMAJ);

            Game.Components.Add(messageB);
        }
Esempio n. 11
0
        /// <summary>
        /// Fonction qui change le pokémon du joueur.
        /// </summary>
        /// <param name="pokémonSélectionné">Le numéro en inventaire du pokémon choisi</param>
        void ChangerUserPokémon(int pokémonSélectionné)
        {
            UserPokemon = UserTrainer[pokémonSélectionné];

            PositionInfoUserPokemon = new Vector2(Game.Window.ClientBounds.Width - (UserPokemon.ToString().Count() + 3) * Cadre.TAILLE_TILE, Game.Window.ClientBounds.Height - Cadre.TAILLE_TILE * 9);
            NomUserPokemon.Visible  = false;
            VieUserPokemon.Visible  = false;
            NomUserPokemon.RemplacerPosition(PositionInfoUserPokemon);
            NomUserPokemon.RemplacerMessage(UserPokemon.ToString());
            VieUserPokemon.RemplacerPosition(new Vector2(PositionInfoUserPokemon.X, PositionInfoUserPokemon.Y + Cadre.TAILLE_TILE));
            VieUserPokemon.RemplacerMessage(UserPokemon.VieToString());

            string         messageTour = UserTrainer.Nom + " send out " + UserPokemon.Nom + "!";
            AfficheurTexte message     = new AfficheurTexte(Game, PositionBox, Jeu.LargeurBoxMessage, Jeu.HauteurBoxMessage, messageTour, IntervalMAJ);

            Game.Components.Add(message);
        }
Esempio n. 12
0
        /// <summary>
        /// Fonction qui affiche le message de l'attaque aléatoire de l'adversaire et l'effectue.
        /// </summary>
        void EffectuerTourOpponent()
        {
            int    nbAléatoire = Générateur.Next(0, OpponentPokemon.NbAttaques);
            string préfixe     = "";

            if (EstOpponentSauvage)
            {
                préfixe = "Wild ";
            }
            else
            {
                préfixe = "Foe ";
            }
            AfficheurTexte message = new AfficheurTexte(Game, PositionBox, Jeu.LargeurBoxMessage, Jeu.HauteurBoxMessage, préfixe + OpponentPokemon.Nom + " used " + OpponentPokemon[nbAléatoire].ToString() + "!", IntervalMAJ);

            Game.Components.Add(message);
            EffectuerAttaque(OpponentPokemon, UserPokemon, OpponentPokemon[nbAléatoire]);
        }
Esempio n. 13
0
 /// <summary>
 /// Fonction qui sert à déterminer si le joueur peut fuir le combat ou non.
 /// </summary>
 void EssayerFuir()
 {
     MainMenu.TentativeFuite = false;
     if (!EstOpponentSauvage)
     {
         TourUserComplété = true;
         AfficheurTexte message = new AfficheurTexte(Game, PositionBox, Jeu.LargeurBoxMessage, Jeu.HauteurBoxMessage, "There's no running from a trainer battle!", IntervalMAJ);
         Game.Components.Add(message);
         MainMenu.BattleMenuState = BattleMenuState.MAIN;
         CombatState = CombatState.BATTLE_MENU;
     }
     else
     {
         AfficheurTexte message = new AfficheurTexte(Game, PositionBox, Jeu.LargeurBoxMessage, Jeu.HauteurBoxMessage, "Got away safely!", IntervalMAJ);
         Game.Components.Add(message);
         CombatState = CombatState.END;
     }
 }
Esempio n. 14
0
        /// <summary>
        /// Initialise le bouton menu recommencer
        /// </summary>
        void InitialiserMenuRecommencer()
        {
            Vector2 PosTexte = new Vector2(Game.Window.ClientBounds.Width / 2, Game.Window.ClientBounds.Height / 2 - 150);

            AfficheurTexte = new AfficheurTexte(Game, Color.Red, PosTexte, "Vous avez échoué.", INTERVALLE_MOYEN);
            Game.Components.Add(AfficheurTexte);
            CalculerNbSoldats(DIMINUTION_SOLDTAS_RECOMMENCER);
            Boutton Recommencer = new Boutton(Game, "Recommencer", new Rectangle(Game.Window.ClientBounds.Width / 2 - LARGEUR_BOUTTON / 2, Game.Window.ClientBounds.Height / 2 - HAUTEUR_BOUTTON / 2,
                                                                                 LARGEUR_BOUTTON, HAUTEUR_BOUTTON), Color.Blue, NOM_IMAGE_AVANT, NOM_IMAGE_APRÈS, NbSoldatsContinuer,
                                              PartieEnCours.GetNbSections(), INTERVALLE_MOYEN);

            Bouttons.Add(Recommencer);
            Bouttons.Add(Exit);
            Game.Components.Add(Recommencer);
            Game.Components.Add(Exit);
            Afficheur = new AfficheurNb(Game, Color.Red, CompteurNiveau, new Vector2(0, 0), "Niveau :", INTERVALLE_MOYEN);
            Game.Components.Add(Afficheur);
            PartieEnCours.DéfinirÉtatJeu(PartieEnCours.EstRéussi, false);
        }
Esempio n. 15
0
        /// <summary>
        /// initialise menu continuer
        /// </summary>
        void InitialiserMenuContinuer()
        {
            Vector2 PosTexte = new Vector2(Game.Window.ClientBounds.Width / 2, Game.Window.ClientBounds.Height / 2 - 150);

            AfficheurTexte = new AfficheurTexte(Game, Color.Red, PosTexte, "Bravo! Vous avez complété le niveau " + CompteurNiveau.ToString(), INTERVALLE_MOYEN);

            Game.Components.Add(AfficheurTexte);
            Boutton Continuer = new Boutton(Game, "Continuer", new Rectangle(Game.Window.ClientBounds.Width / 2 - LARGEUR_BOUTTON / 2, Game.Window.ClientBounds.Height / 2 - HAUTEUR_BOUTTON / 2,
                                                                             LARGEUR_BOUTTON, HAUTEUR_BOUTTON), Color.Blue, NOM_IMAGE_AVANT, NOM_IMAGE_APRÈS,
                                            CalculerNbSoldats(AUGMENTATION_SOLDATS_NIVEAU), CalculerNbSection(), INTERVALLE_MOYEN);

            NbSoldatsContinuer = Continuer.NombreSoldats;
            Bouttons.Add(Continuer);
            Bouttons.Add(Exit);
            Game.Components.Add(Exit);
            Game.Components.Add(Continuer);
            Afficheur = new AfficheurNb(Game, Color.Red, ++CompteurNiveau, new Vector2(0, 0), "Niveau :", INTERVALLE_MOYEN);
            Game.Components.Add(Afficheur);
            PartieEnCours.DéfinirÉtatJeu(false, PartieEnCours.EstÉchec);
        }
Esempio n. 16
0
        /// <summary>
        /// Fonction qui affiche un message d'effet si le multiplicateur de type est différent de 100%.
        /// </summary>
        /// <param name="multiplicateurType">Le multiplicateur par rapport au type, 1.00 étant 100%</param>
        private void AfficherMessageMultiplicateur(float multiplicateurType)
        {
            int pourcentageMultiplicatif = (int)(multiplicateurType * 100);

            if (pourcentageMultiplicatif == 0)
            {
                AfficheurTexte messageA = new AfficheurTexte(Game, PositionBox, Jeu.LargeurBoxMessage, Jeu.HauteurBoxMessage, "It had no effect.", IntervalMAJ);
                Game.Components.Add(messageA);
            }
            else if (pourcentageMultiplicatif < 100)
            {
                AfficheurTexte messageB = new AfficheurTexte(Game, PositionBox, Jeu.LargeurBoxMessage, Jeu.HauteurBoxMessage, "It's not very effective...", IntervalMAJ);
                Game.Components.Add(messageB);
            }
            else if (pourcentageMultiplicatif > 100)
            {
                AfficheurTexte messageC = new AfficheurTexte(Game, PositionBox, Jeu.LargeurBoxMessage, Jeu.HauteurBoxMessage, "It's super effective!", IntervalMAJ);
                Game.Components.Add(messageC);
            }
        }
Esempio n. 17
0
        /// <summary>
        /// Fonction qui affiche les messages du début d'un combat.
        /// </summary>
        private void AfficherMessagesInitialisation()
        {
            if (EstOpponentSauvage)
            {
                AfficheurTexte messageA = new AfficheurTexte(Game, PositionBox, Jeu.LargeurBoxMessage, Jeu.HauteurBoxMessage, "Wild " + OpponentPokemon.Nom + " appeared!", IntervalMAJ);
                Game.Components.Add(messageA);
            }
            else
            {
                OpponentPokemon = OpponentTrainer.NextPokemonEnVie();
                AfficheurTexte messageA = new AfficheurTexte(Game, PositionBox, Jeu.LargeurBoxMessage, Jeu.HauteurBoxMessage, "Trainer " + OpponentTrainer.Nom + " wants to battle!", IntervalMAJ);
                Game.Components.Add(messageA);
                AfficheurTexte messageA2 = new AfficheurTexte(Game, PositionBox, Jeu.LargeurBoxMessage, Jeu.HauteurBoxMessage, "Trainer " + OpponentTrainer.Nom + " send out " + OpponentPokemon.Nom + "!", IntervalMAJ);
                Game.Components.Add(messageA2);
            }

            AfficheurTexte messageB = new AfficheurTexte(Game, PositionBox, Jeu.LargeurBoxMessage, Jeu.HauteurBoxMessage, UserTrainer.Nom + ": Go, " + UserPokemon.Nom + "!", IntervalMAJ);

            Game.Components.Add(messageB);
        }
Esempio n. 18
0
        /// <summary>
        /// Fonction de transition qui vérifie l'état du combat, s'il doit finir, continuer et comment procéder si l'on continue.
        /// </summary>
        void GérerTransitionVERIFY_OUTCOME()
        {
            GamePad.SetVibration(PlayerIndex.One, 0, 0);
            if (UserPokemon.EstEnVie)
            {
                if (EstOpponentSauvage || !(OpponentTrainer.EstEnVie))
                {
                    CombatState = CombatState.VICTORY;
                }
                else
                {
                    DonnerExp();
                    ChangerOpponentPokemon();
                    MainMenu.BattleMenuState = BattleMenuState.MAIN;
                    CombatState = CombatState.BATTLE_MENU;
                }
            }
            else
            {
                if (!UserTrainer.EstEnVie)
                {
                    CombatState = CombatState.DEFEAT;
                }
                else
                {
                    NomUserPokemon.Visible = false;
                    VieUserPokemon.Visible = false;
                    AfficheurTexte message = new AfficheurTexte(Game, PositionBox, Jeu.LargeurBoxMessage, Jeu.HauteurBoxMessage, UserPokemon.Nom + " fainted!", IntervalMAJ);
                    Game.Components.Add(message);

                    MainMenu.BackLock        = true; //Pour forcer le joueur à changer de pokemon sans pouvoir revenir dans le menu.
                    MainMenu.BattleMenuState = BattleMenuState.POKEMON;
                    CombatState = CombatState.TOUR_USER;
                }
            }
        }