mirror of
https://github.com/kwsch/PKHeX.git
synced 2026-05-15 16:41:03 -05:00
Clamp roto rally score to 99_999
https://github.com/kwsch/PKHeX/issues/2639#issuecomment-575863541
This commit is contained in:
parent
e3cafe5cd6
commit
e4e1681e1c
|
|
@ -19,11 +19,15 @@ public int TrainerID
|
|||
set => SAV.SetData(Data, BitConverter.GetBytes(value), 0x1C);
|
||||
}
|
||||
|
||||
public const int RotoRallyScoreMax = 99_999;
|
||||
|
||||
public int RotoRallyScore
|
||||
{
|
||||
get => BitConverter.ToInt32(Data, 0x28);
|
||||
set
|
||||
{
|
||||
if (value > RotoRallyScoreMax)
|
||||
value = RotoRallyScoreMax;
|
||||
var data = BitConverter.GetBytes(value);
|
||||
SAV.SetData(Data, data, 0x28);
|
||||
// set to the other block since it doesn't have an accessor
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user