Beispiel #1
0
 public Equipe(string nom, Pokemons p1, Pokemons p2, Pokemons p3)
 {
     NomEquipe = nom;
     Pokémon1  = p1;
     Pokémon2  = p2;
     Pokémon3  = p3;
 }
Beispiel #2
0
 public void creaBasePokemons()
 {
     for (int i = 0; i < 48; i++)
     {
         int      pv        = alea.Next(500, 1001);
         int      puissance = alea.Next(300, 501);
         int      nb        = alea.Next(0, 6);
         string   type      = types[nb, 0];
         string   faiblesse = types[nb, 1];
         Pokemons P         = new Pokemons(nomspokemons[i], pv, puissance, type, faiblesse);
         bddpokemon.Add(P);
     }
 }
Beispiel #3
0
        public void creaEquipe()
        {
            BddPokemon pokemonsdispo = new BddPokemon();

            pokemonsdispo.creaBasePokemons();
            bddpokemon2 = pokemonsdispo.bddpokemon;
            for (int i = 0; i < 16; i++)
            {
                string   nomequipe = noms[i];
                int      nb1       = alea.Next(0, 47 - i * 3);
                int      nb2       = alea.Next(0, 47 - i * 3);
                int      nb3       = alea.Next(0, 47 - i * 3);
                Pokemons p1        = bddpokemon2[nb1];
                Console.WriteLine(p1);
                Pokemons p2 = bddpokemon2[nb2];
                Pokemons p3 = bddpokemon2[nb3];
                //Equipe equipe = new Equipe(nomequipe, p1, p2, p3);

                //delete les 3 poké de la liste des pokémons
                bddpokemon2.Remove(p1);
                bddpokemon2.Remove(p2);
                bddpokemon2.Remove(p3);
            }
        }