PKHeX/PKHeX.Core/Legality/Encounters/EncounterSlot/EncounterSlot5.cs
Kurt a159da0abf Reduce allocations of default valid/invalid
Condense some expressions, make some comments/params clear and consistent.
2021-07-30 13:05:34 -07:00

19 lines
688 B
C#

namespace PKHeX.Core
{
/// <summary>
/// Encounter Slot found in <see cref="GameVersion.Gen5"/>.
/// </summary>
/// <inheritdoc cref="EncounterSlot"/>
public sealed record EncounterSlot5 : EncounterSlot
{
public override int Generation => 5;
public EncounterSlot5(EncounterArea5 area, int species, int form, int min, int max) : base(area, species, form, min, max)
{
}
public bool IsHiddenGrotto() => Area.Type == SlotType.HiddenGrotto;
protected override HiddenAbilityPermission IsHiddenAbilitySlot() => Area.Type == SlotType.HiddenGrotto ? HiddenAbilityPermission.Always : HiddenAbilityPermission.Never;
}
}