using System;
using System.Collections.Generic;

namespace PokePurple.Library.Singletons;

public class Generations
{
    private List<Range> _generations =
    [
        new Range(1,151),
        new Range(152, 251),
        new Range(252, 386),
        new Range(387, 493),
        new Range(494, 649),
        new Range(650, 721),
        new Range(722, 809),
        new Range(810, 905),
        new Range(906, 1025)
    ];

    public int Generation = 1;

    public int PickRandomPokemon()
    {
        var maxRange = _generations[Generation].End.Value;
        var random = new Random();
        var id = random.Next(1, maxRange);
        return id;
    }
}