Example #1
0
        /// <summary>
        /// Gets the correct Transfer Met location for the origin game.
        /// </summary>
        /// <param name="pkm">Pokémon data to suggest for</param>
        /// <remarks>
        /// Returns -1 if the met location is not overriden with a transfer location
        /// </remarks>
        public static int GetSuggestedTransferLocation(PKM pkm)
        {
            if (pkm.HasOriginalMetLocation)
            {
                return(-1);
            }
            if (pkm.Version == (int)GameVersion.GO)
            {
                return(30012);
            }
            if (pkm.VC1)
            {
                return(Legal.Transfer1);
            }
            if (pkm.VC2)
            {
                return(Legal.Transfer2);
            }
            if (pkm.Format == 4) // Pal Park
            {
                return(Legal.Transfer3);
            }

            if (pkm.GenNumber >= 5)
            {
                return(-1);
            }

            if (pkm.Format >= 5) // Transporter
            {
                return(Legal.GetTransfer45MetLocation(pkm));
            }
            return(-1);
        }