mirror of
https://github.com/kwsch/PKHeX.git
synced 2026-05-05 21:17:14 -05:00
parent
988385e450
commit
f5344452cf
|
|
@ -81,7 +81,7 @@ public bool IsFunfestMissionsUnlocked
|
|||
|
||||
public bool IsFunfestMissionUnlocked(int mission)
|
||||
{
|
||||
if ((uint) mission >= MaxMissionIndex)
|
||||
if ((uint) mission > MaxMissionIndex)
|
||||
throw new ArgumentOutOfRangeException(nameof(mission));
|
||||
|
||||
if (mission == 0)
|
||||
|
|
@ -98,7 +98,7 @@ public bool IsFunfestMissionUnlocked(int mission)
|
|||
|
||||
public void UnlockFunfestMission(int mission)
|
||||
{
|
||||
if ((uint)mission >= MaxMissionIndex)
|
||||
if ((uint)mission > MaxMissionIndex)
|
||||
throw new ArgumentOutOfRangeException(nameof(mission));
|
||||
|
||||
IsFunfestMissionsUnlocked = true;
|
||||
|
|
|
|||
|
|
@ -387,7 +387,7 @@ private void LoadFestaMissionRecord()
|
|||
{
|
||||
FestaBlock5 block = ((SAV5B2W2) SAV).Festa;
|
||||
int mission = LB_FunfestMissions.SelectedIndex;
|
||||
if ((uint) mission >= FestaBlock5.MaxMissionIndex)
|
||||
if ((uint) mission > FestaBlock5.MaxMissionIndex)
|
||||
return;
|
||||
bool unlocked = block.IsFunfestMissionUnlocked(mission);
|
||||
L_FMUnlocked.Visible = unlocked;
|
||||
|
|
@ -407,7 +407,7 @@ private void ChangeFestaMissionValue(object sender, EventArgs e)
|
|||
|
||||
FestaBlock5 block = ((SAV5B2W2)SAV).Festa;
|
||||
int mission = LB_FunfestMissions.SelectedIndex;
|
||||
if ((uint)mission >= FestaBlock5.MaxMissionIndex)
|
||||
if ((uint)mission > FestaBlock5.MaxMissionIndex)
|
||||
return;
|
||||
|
||||
var score = new Funfest5Score((int)NUD_FMBestTotal.Value, (int)NUD_FMBestScore.Value, CB_FMLevel.SelectedIndex & 3, CHK_FMNew.Checked);
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user