PKHeX/PKHeX.Core/Legality/LearnSource/Sources/Shared/LearnSource4.cs
Kurt 88830e0d00
Update from .NET Framework 4.6 to .NET 7 (#3729)
Updates from net46->net7, dropping support for mono in favor of using the latest runtime (along with the performance/API improvements). Releases will be posted as 64bit only for now.

Refactors a good amount of internal API methods to be more performant and more customizable for future updates & fixes.

Adds functionality for Batch Editor commands to `>`, `<` and <=/>=

TID/SID properties renamed to TID16/SID16 for clarity; other properties exposed for Gen7 / display variants.

Main window has a new layout to account for DPI scaling (8 point grid)

Fixed: Tatsugiri and Paldean Tauros now output Showdown form names as Showdown expects
Changed: Gen9 species now interact based on the confirmed National Dex IDs (closes #3724)
Fixed: Pokedex set all no longer clears species with unavailable non-base forms (closes #3720)
Changed: Hyper Training suggestions now apply for level 50 in SV. (closes #3714)
Fixed: B2/W2 hatched egg met locations exclusive to specific versions are now explicitly checked (closes #3691)
Added: Properties for ribbon/mark count (closes #3659)
Fixed: Traded SV eggs are now checked correctly (closes #3692)
2023-01-21 20:02:33 -08:00

79 lines
2.6 KiB
C#

using System;
namespace PKHeX.Core;
internal static class LearnSource4
{
/// <summary>
/// Gets the preferred list of HM moves to disallow on transfer from <see cref="PK4"/> to <see cref="PK5"/>.
/// </summary>
/// <remarks>
/// If the moveset has Defog, then we prefer HG/SS (remove Whirlpool) over D/P/Pt.
/// Defog is a competitively viable move, while Whirlpool is not really useful.
/// </remarks>
/// <param name="hasDefog">True if the current moveset has <see cref="Move.Defog"/>.</param>
public static ReadOnlySpan<ushort> GetPreferredTransferHMs(bool hasDefog) => hasDefog ? HM_HGSS : HM_DPPt;
internal static readonly ushort[] SpecialTutors_4 =
{
(int)Move.BlastBurn,
(int)Move.HydroCannon,
(int)Move.FrenzyPlant,
(int)Move.DracoMeteor,
};
internal static readonly ushort[][] SpecialTutors_Compatibility_4 =
{
new ushort[] { 006, 157, 257, 392 },
new ushort[] { 009, 160, 260, 395 },
new ushort[] { 003, 154, 254, 389 },
new ushort[] { 147, 148, 149, 230, 329, 330, 334, 371, 372, 373, 380, 381, 384, 443, 444, 445, 483, 484, 487 },
};
internal static readonly ushort[] Tutors_4 =
{
291, 189, 210, 196, 205, 009, 007, 276, 008, 442, 401, 466, 380, 173, 180, 314,
270, 283, 200, 246, 235, 324, 428, 410, 414, 441, 239, 402, 334, 393, 387, 340,
271, 257, 282, 389, 129, 253, 162, 220, 081, 366, 356, 388, 277, 272, 215, 067,
143, 335, 450, 029,
};
internal static readonly ushort[] TM_4 =
{
264, 337, 352, 347, 046, 092, 258, 339, 331, 237,
241, 269, 058, 059, 063, 113, 182, 240, 202, 219,
218, 076, 231, 085, 087, 089, 216, 091, 094, 247,
280, 104, 115, 351, 053, 188, 201, 126, 317, 332,
259, 263, 290, 156, 213, 168, 211, 285, 289, 315,
355, 411, 412, 206, 362, 374, 451, 203, 406, 409,
261, 318, 373, 153, 421, 371, 278, 416, 397, 148,
444, 419, 086, 360, 014, 446, 244, 445, 399, 157,
404, 214, 363, 398, 138, 447, 207, 365, 369, 164,
430, 433,
};
internal static readonly ushort[] HM_DPPt =
{
(int)Move.Cut,
(int)Move.Fly,
(int)Move.Surf,
(int)Move.Strength,
(int)Move.Defog,
(int)Move.RockSmash,
(int)Move.Waterfall,
(int)Move.RockClimb,
};
internal static readonly ushort[] HM_HGSS =
{
(int)Move.Cut,
(int)Move.Fly,
(int)Move.Surf,
(int)Move.Strength,
(int)Move.Whirlpool,
(int)Move.RockSmash,
(int)Move.Waterfall,
(int)Move.RockClimb,
};
}