mirror of
https://github.com/kwsch/PKHeX
synced 2024-11-24 04:53:08 +00:00
Add DexNav count 0->1 on modify (ORAS only)
This commit is contained in:
parent
71ed9872a8
commit
8218fbfefb
1 changed files with 6 additions and 0 deletions
|
@ -413,6 +413,8 @@ namespace PKHeX
|
||||||
public void setPSSStat(int index, uint value) { BitConverter.GetBytes(value).CopyTo(Data, PSSStats + 4*index); }
|
public void setPSSStat(int index, uint value) { BitConverter.GetBytes(value).CopyTo(Data, PSSStats + 4*index); }
|
||||||
public ushort getMaisonStat(int index) { return BitConverter.ToUInt16(Data, MaisonStats + 2 * index); }
|
public ushort getMaisonStat(int index) { return BitConverter.ToUInt16(Data, MaisonStats + 2 * index); }
|
||||||
public void setMaisonStat(int index, ushort value) { BitConverter.GetBytes(value).CopyTo(Data, MaisonStats + 2*index); }
|
public void setMaisonStat(int index, ushort value) { BitConverter.GetBytes(value).CopyTo(Data, MaisonStats + 2*index); }
|
||||||
|
public uint getEncounterCount(int index) { return BitConverter.ToUInt16(Data, EncounterCount + 2*index); }
|
||||||
|
public void setEncounterCount(int index, ushort value) { BitConverter.GetBytes(value).CopyTo(Data, EncounterCount + 2*index); }
|
||||||
|
|
||||||
// Misc Properties
|
// Misc Properties
|
||||||
public int PartyCount
|
public int PartyCount
|
||||||
|
@ -573,6 +575,10 @@ namespace PKHeX
|
||||||
// Set the Language
|
// Set the Language
|
||||||
if (lang < 0) lang = 1;
|
if (lang < 0) lang = 1;
|
||||||
Data[PokeDexLanguageFlags + (bit * 7 + lang) / 8] |= (byte)(1 << (((bit * 7) + lang) % 8));
|
Data[PokeDexLanguageFlags + (bit * 7 + lang) / 8] |= (byte)(1 << (((bit * 7) + lang) % 8));
|
||||||
|
|
||||||
|
// Set DexNav count (only if not encountered previously)
|
||||||
|
if (ORAS && getEncounterCount(pk6.Species - 1) == 0)
|
||||||
|
setEncounterCount(pk6.Species - 1, 1);
|
||||||
}
|
}
|
||||||
public int getBoxWallpaper(int box)
|
public int getBoxWallpaper(int box)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue