More settings fuckery, good night
This commit is contained in:
6
HighRollerClassic/DataStructures/SettingValueType.cs
Normal file
6
HighRollerClassic/DataStructures/SettingValueType.cs
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
namespace HighRollerClassic.DataStructures;
|
||||||
|
|
||||||
|
public enum SettingValueType
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
22
HighRollerClassic/DataStructures/TrackedValue.cs
Normal file
22
HighRollerClassic/DataStructures/TrackedValue.cs
Normal file
@@ -0,0 +1,22 @@
|
|||||||
|
using System;
|
||||||
|
|
||||||
|
namespace HighRollerClassic.DataStructures;
|
||||||
|
|
||||||
|
public class TrackedValue<TParent, TValue>
|
||||||
|
{
|
||||||
|
public TValue Value { get; set; }
|
||||||
|
public bool IsValid { get; set; }
|
||||||
|
public bool HasChanged { get; set; }
|
||||||
|
|
||||||
|
private const uint MinRoll = 1;
|
||||||
|
private const uint MaxRoll = 999;
|
||||||
|
private const uint MaxGil = 999_999_999;
|
||||||
|
|
||||||
|
private Func<uint, bool> multiplierRollValid = v => v is >= MinRoll and <= MaxRoll;
|
||||||
|
private Func<uint, bool> maxBetValid = v => v <= MaxGil;
|
||||||
|
|
||||||
|
private static bool StepValid(uint step, uint bet)
|
||||||
|
{
|
||||||
|
return step <= bet;
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -9,4 +9,6 @@ public class Player(MenuTargetDefault target)
|
|||||||
public int Bank { get; private set; } = 0;
|
public int Bank { get; private set; } = 0;
|
||||||
|
|
||||||
public ulong ContentId { get; private set; } = target.TargetContentId;
|
public ulong ContentId { get; private set; } = target.TargetContentId;
|
||||||
|
|
||||||
|
// TODO implement roll history FULL
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user