mirror of
https://github.com/kwsch/PKHeX
synced 2024-11-27 06:20:25 +00:00
d47bb1d297
With the new version of Visual Studio bringing C# 12, we can revise our logic for better readability as well as use new methods/APIs introduced in the .NET 8.0 BCL.
29 lines
831 B
C#
29 lines
831 B
C#
namespace PKHeX.Core;
|
|
|
|
/// <summary>
|
|
/// Structure containing the Mystery Gift Data
|
|
/// </summary>
|
|
public class MysteryGiftAlbum(DataMysteryGift[] Gifts, bool[] Flags)
|
|
{
|
|
/// <summary>
|
|
/// Mystery Gift data received
|
|
/// </summary>
|
|
public readonly DataMysteryGift[] Gifts = Gifts;
|
|
|
|
/// <summary>
|
|
/// Received Flag list
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// this[index] == true iff index=<see cref="MysteryGift.CardID"/> has been received already.
|
|
/// </remarks>
|
|
public readonly bool[] Flags = Flags;
|
|
}
|
|
|
|
public sealed class EncryptedMysteryGiftAlbum(DataMysteryGift[] Gifts, bool[] Flags, uint Seed)
|
|
: MysteryGiftAlbum(Gifts, Flags)
|
|
{
|
|
/// <summary>
|
|
/// Encryption Seed (only used in Generation 5 to encrypt the stored data)
|
|
/// </summary>
|
|
public readonly uint Seed = Seed;
|
|
}
|