Skip to content

Commit

Permalink
Merge pull request #1465 from Ilses/master
Browse files Browse the repository at this point in the history
Fix RNG in UpgradePokemon
  • Loading branch information
NecronomiconCoding authored Jul 30, 2016
2 parents 1199b6a + 2d64255 commit e730192
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion PoGo.NecroBot.Logic/Tasks/LevelUpPokemonTask.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ namespace PoGo.NecroBot.Logic.Tasks
{
internal class LevelUpPokemonTask
{
private static readonly Random rand = new Random();

public static async Task Execute(ISession session, CancellationToken cancellationToken)
{
if (DisplayPokemonStatsTask.PokemonId.Count == 0 || DisplayPokemonStatsTask.PokemonIdcp.Count == 0)
Expand All @@ -20,7 +22,6 @@ public static async Task Execute(ISession session, CancellationToken cancellatio
}
if (session.LogicSettings.LevelUpByCPorIv.ToLower().Contains("iv"))
{
var rand = new Random();
var randomNumber = rand.Next(0, DisplayPokemonStatsTask.PokemonId.Count - 1);

var upgradeResult =
Expand Down

0 comments on commit e730192

Please sign in to comment.