2020-06-19 23:51:15 +00:00
|
|
|
|
using static PKHeX.Core.Species;
|
|
|
|
|
|
|
|
|
|
namespace PKHeX.Core
|
2020-05-16 22:15:41 +00:00
|
|
|
|
{
|
|
|
|
|
public interface IDynamaxLevel
|
|
|
|
|
{
|
|
|
|
|
byte DynamaxLevel { get; set; }
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public static class DynamaxLevelExtensions
|
|
|
|
|
{
|
|
|
|
|
public static bool CanHaveDynamaxLevel(this IDynamaxLevel _, PKM pkm)
|
|
|
|
|
{
|
|
|
|
|
if (pkm.IsEgg)
|
|
|
|
|
return false;
|
2020-06-19 23:51:15 +00:00
|
|
|
|
var species = pkm.Species;
|
2020-06-20 12:52:54 +00:00
|
|
|
|
if (species == (int)Zacian || species == (int)Zamazenta || species == (int)Eternatus)
|
2020-05-16 22:15:41 +00:00
|
|
|
|
return false;
|
|
|
|
|
return true;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|