Added Backend Classes and FUnctions for an working Game. But lacking Implementations

This commit is contained in:
jhim
2026-02-27 11:16:21 +01:00
committed by Jonas
parent 120c671dce
commit 5db7ac1676
12 changed files with 183 additions and 15 deletions
+20
View File
@@ -0,0 +1,20 @@
namespace API.Models.DataClasses
{
public readonly record struct SixDigitInt
{
public int Value { get; }
public SixDigitInt(int value)
{
if (value < 0 || value > 999999)
throw new ArgumentOutOfRangeException(nameof(value),
"Wert muss zwischen 0 und 999999 liegen.");
Value = value;
}
public override string ToString() => Value.ToString("D6");
public static implicit operator int(SixDigitInt v) => v.Value;
}
}