RocketBot icon indicating copy to clipboard operation
RocketBot copied to clipboard

Evolve above IV

Open Gateway753 opened this issue 10 years ago • 4 comments

For exemple, evolve pokémon only above 90% IV Can someone make this?

Gateway753 avatar Jul 29 '16 21:07 Gateway753

In mainform.cs, something like this should work:

private async Task EvolveAllGivenPokemons(Client client, IEnumerable pokemonToEvolve) { foreach (var pokemon in pokemonToEvolve) { if(Math.Round(Perfect(pokemon))>=90) {

MatthewHudnall avatar Jul 29 '16 22:07 MatthewHudnall

I wrote a similar evolveroutine for myself. This would generate a List of Pokemon above a certain IV and then try to evolve them all.

replace if (ClientSettings.EvolveAllGivenPokemons) await EvolveAllGivenPokemons(client, pokemons); with if (ClientSettings.EvolveAllGivenPokemons) await evolvemaxIV(client, 90);

put in mainform.cs

private async Task evolvemaxIV(Client client, int minIV) { var pokemonstoevolve = new List { }; var inventory = await client.GetInventory(); var pokemons = inventory.InventoryDelta.InventoryItems .Select(i => i.InventoryItemData?.Pokemon) .Where(p => p != null && p?.PokemonId > 0) .OrderByDescending(key => key.Cp); foreach (var pokemon in pokemons) { if (((float)(pokemon.IndividualAttack + pokemon.IndividualDefense + pokemon.IndividualStamina) / (3.0f * 15.0f)) * 100.0f >= minIV) { pokemonstoevolve.Add(Convert.ToString(pokemon.PokemonId)); } } var toevolve = inventory.InventoryDelta.InventoryItems .Select(i => i.InventoryItemData?.Pokemon) .Where(p => p != null && pokemonstoevolve.Contains(Convert.ToString(p?.PokemonId))); await EvolveAllGivenPokemons(client, toevolve); }

Solrian avatar Jul 29 '16 22:07 Solrian

@Solrian what mode do you have the transfer on while using your code? I currently use the duplicateIV transfer option.

maddhadder90 avatar Jul 30 '16 03:07 maddhadder90

my personal code is a little more complex than this example, but i use it on duplicateIV also.

Solrian avatar Jul 30 '16 04:07 Solrian