mirror of
https://github.com/kwsch/PKHeX
synced 2024-12-11 13:13:06 +00:00
fc754b346b
[Language Reference](https://docs.microsoft.com/en-us/dotnet/csharp/language-reference/proposals/csharp-10.0/file-scoped-namespaces) Updates all the files, one less level of indentation. Some small changes were made to API surfaces, renaming `PKM pkm` -> `PKM pk`, and `LegalityAnalysis.pkm` -> `LegalityAnalysis.Entity`
17 lines
587 B
C#
17 lines
587 B
C#
using System;
|
|
using static System.Buffers.Binary.BinaryPrimitives;
|
|
|
|
namespace PKHeX.Core;
|
|
|
|
public sealed class RTC3
|
|
{
|
|
public readonly byte[] Data;
|
|
public const int Size = 8;
|
|
|
|
public RTC3(byte[] data) => Data = data;
|
|
|
|
public int Day { get => ReadUInt16LittleEndian(Data.AsSpan(0x00)); set => WriteUInt16LittleEndian(Data.AsSpan(0x00), (ushort)value); }
|
|
public int Hour { get => Data[2]; set => Data[2] = (byte)value; }
|
|
public int Minute { get => Data[3]; set => Data[3] = (byte)value; }
|
|
public int Second { get => Data[4]; set => Data[4] = (byte)value; }
|
|
}
|