Beispiel #1
0
        private static IReadOnlyList <ComboItem> GetVersionList(GameStrings s)
        {
            var list  = s.gamelist;
            var games = new byte[]
            {
                44, 45,         // 8 swsh
                42, 43,         // 7 gg
                30, 31,         // 7 sm
                32, 33,         // 7 usum
                24, 25,         // 6 xy
                27, 26,         // 6 oras
                21, 20,         // 5 bw
                23, 22,         // 5 b2w2
                10, 11, 12,     // 4 dppt
                07, 08,         // 4 hgss
                02, 01, 03,     // 3 rse
                04, 05,         // 3 frlg
                15,             // 3 cxd

                39, 40, 41,     // 7vc2
                35, 36, 37, 38, // 7vc1
                34,             // 7go
            };

            return(Util.GetUnsortedCBList(list, games));
        }
Beispiel #2
0
        public static IReadOnlyList <ComboItem> LanguageDataSource(int gen)
        {
            var languages = LanguageList.ToList();

            Util.GetUnsortedCBList("languages");
            if (gen == 3)
            {
                languages.RemoveAll(l => l.Value >= (int)LanguageID.Korean);
            }
            else if (gen < 7)
            {
                languages.RemoveAll(l => l.Value > (int)LanguageID.Korean);
            }
            return(languages);
        }
Beispiel #3
0
        public GameDataSource(GameStrings s)
        {
            Strings                 = s;
            BallDataSource          = Util.GetVariedCBListBall(s.itemlist, ball_nums, ball_vals);
            SpeciesDataSource       = Util.GetCBList(s.specieslist);
            NatureDataSource        = Util.GetCBList(s.natures);
            AbilityDataSource       = Util.GetCBList(s.abilitylist);
            EncounterTypeDataSource = Util.GetUnsortedCBList(s.encountertypelist, Gen4EncounterTypes);

            var moves = Util.GetCBList(s.movelist);

            HaXMoveDataSource = moves;
            var legal = new List <ComboItem>(moves);

            legal.RemoveAll(m => Legal.Z_Moves.Contains(m.Value));
            LegalMoveDataSource = legal;

            VersionDataSource = GetVersionList(s);

            Met = new MetDataSource(s);

            Empty = new ComboItem(s.Species[0], 0);
        }