mirror of
https://github.com/kwsch/PKHeX
synced 2024-12-11 21:22:41 +00:00
Add pokestar studio fame / star stat pk5[0x87]
how did this get forgotten so easily lol added legality check; eggs can't participate in pokestar studio. not editable from GUI, use ExtraBytes editor. Re-add 0x86 (array was copied from pk4?) and reorder/comment
This commit is contained in:
parent
ede44aaa1b
commit
5fcd8541ba
3 changed files with 14 additions and 2 deletions
|
@ -111,6 +111,7 @@ namespace PKHeX.Core
|
||||||
public static string LEggPP { get; set; } = "Eggs cannot have modified move PP counts.";
|
public static string LEggPP { get; set; } = "Eggs cannot have modified move PP counts.";
|
||||||
public static string LEggPPUp { get; set; } = "Cannot apply PP Ups to an Egg.";
|
public static string LEggPPUp { get; set; } = "Cannot apply PP Ups to an Egg.";
|
||||||
public static string LEggShinyLeaf { get; set; } = "Eggs cannot have Shiny Leaf/Crown.";
|
public static string LEggShinyLeaf { get; set; } = "Eggs cannot have Shiny Leaf/Crown.";
|
||||||
|
public static string LEggShinyPokeStar { get; set; } = "Eggs cannot be a Pokéstar Studios star.";
|
||||||
public static string LEggSpecies { get; set; } = "Can't obtain Egg for this species.";
|
public static string LEggSpecies { get; set; } = "Can't obtain Egg for this species.";
|
||||||
public static string LEggUnhatched { get; set; } = "Valid un-hatched Egg.";
|
public static string LEggUnhatched { get; set; } = "Valid un-hatched Egg.";
|
||||||
|
|
||||||
|
|
|
@ -23,6 +23,9 @@ namespace PKHeX.Core
|
||||||
|
|
||||||
switch (pkm)
|
switch (pkm)
|
||||||
{
|
{
|
||||||
|
case PK5 pk5 when pk5.PokeStarFame != 0 && pk5.IsEgg:
|
||||||
|
data.AddLine(GetInvalid(LEggShinyPokeStar, CheckIdentifier.Egg));
|
||||||
|
break;
|
||||||
case PK4 pk4 when pk4.ShinyLeaf != 0:
|
case PK4 pk4 when pk4.ShinyLeaf != 0:
|
||||||
data.AddLine(GetInvalid(LEggShinyLeaf, CheckIdentifier.Egg));
|
data.AddLine(GetInvalid(LEggShinyLeaf, CheckIdentifier.Egg));
|
||||||
break;
|
break;
|
||||||
|
|
|
@ -8,7 +8,13 @@ namespace PKHeX.Core
|
||||||
{
|
{
|
||||||
private static readonly byte[] Unused =
|
private static readonly byte[] Unused =
|
||||||
{
|
{
|
||||||
0x42, 0x43, 0x44, 0x45, 0x46, 0x47, 0x5E, 0x63, 0x64, 0x65, 0x66, 0x67, 0x87
|
0x87, // PokeStar Fame -- this is first to prevent 0x42 from being the first ExtraByte as this byte has GUI functionality
|
||||||
|
0x42, // Hidden Ability/NPokemon
|
||||||
|
0x43, 0x44, 0x45, 0x46, 0x47,
|
||||||
|
0x5E, // unused
|
||||||
|
0x63, // last 8 bits of a 32bit ribbonset
|
||||||
|
0x64, 0x65, 0x66, 0x67, // unused 32bit ribbonset?
|
||||||
|
0x86, // unused
|
||||||
};
|
};
|
||||||
|
|
||||||
public override byte[] ExtraBytes => Unused;
|
public override byte[] ExtraBytes => Unused;
|
||||||
|
@ -239,7 +245,9 @@ namespace PKHeX.Core
|
||||||
public override int Met_Level { get => Data[0x84] & ~0x80; set => Data[0x84] = (byte)((Data[0x84] & 0x80) | value); }
|
public override int Met_Level { get => Data[0x84] & ~0x80; set => Data[0x84] = (byte)((Data[0x84] & 0x80) | value); }
|
||||||
public override int OT_Gender { get => Data[0x84] >> 7; set => Data[0x84] = (byte)((Data[0x84] & ~0x80) | value << 7); }
|
public override int OT_Gender { get => Data[0x84] >> 7; set => Data[0x84] = (byte)((Data[0x84] & ~0x80) | value << 7); }
|
||||||
public override int EncounterType { get => Data[0x85]; set => Data[0x85] = (byte)value; }
|
public override int EncounterType { get => Data[0x85]; set => Data[0x85] = (byte)value; }
|
||||||
// 0x86-0x87 Unused
|
// 0x86 Unused
|
||||||
|
public byte PokeStarFame { get => Data[0x87]; set => Data[0x87] = value; }
|
||||||
|
public bool IsPokeStar { get => PokeStarFame > 250; set => PokeStarFame = 255; }
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
#region Battle Stats
|
#region Battle Stats
|
||||||
|
|
Loading…
Reference in a new issue