mirror of
https://github.com/mm201/pkmn-classic-framework.git
synced 2026-09-12 12:15:14 -05:00
Moved a bunch of common fields over to GtsRecordBase.
This commit is contained in:
@@ -52,42 +52,9 @@ namespace PkmnFoundations.Structures
|
||||
/// </summary>
|
||||
public byte[] Data;
|
||||
|
||||
/// <summary>
|
||||
/// National Dex species number
|
||||
/// </summary>
|
||||
public ushort Species;
|
||||
|
||||
/// <summary>
|
||||
/// Pokémon gender
|
||||
/// </summary>
|
||||
public Genders Gender;
|
||||
|
||||
/// <summary>
|
||||
/// Pokémon level
|
||||
/// </summary>
|
||||
public byte Level;
|
||||
|
||||
/// <summary>
|
||||
/// Requested National Dex species number
|
||||
/// </summary>
|
||||
public ushort RequestedSpecies;
|
||||
|
||||
public Genders RequestedGender;
|
||||
|
||||
public byte RequestedMinLevel;
|
||||
public byte RequestedMaxLevel;
|
||||
public byte Unknown1;
|
||||
public TrainerGenders TrainerGender;
|
||||
public byte Unknown2;
|
||||
|
||||
public DateTime ? TimeDeposited;
|
||||
public DateTime ? TimeExchanged;
|
||||
|
||||
/// <summary>
|
||||
/// User ID of the player (not Personality Value)
|
||||
/// </summary>
|
||||
public int PID;
|
||||
|
||||
/// <summary>
|
||||
/// 16 bytes
|
||||
/// </summary>
|
||||
@@ -95,15 +62,6 @@ namespace PkmnFoundations.Structures
|
||||
|
||||
public ushort TrainerOT;
|
||||
|
||||
public byte TrainerCountry;
|
||||
public byte TrainerRegion;
|
||||
public byte TrainerClass;
|
||||
|
||||
public byte IsExchanged;
|
||||
|
||||
public byte TrainerVersion;
|
||||
public byte TrainerLanguage;
|
||||
|
||||
protected override void Save(BinaryWriter writer)
|
||||
{
|
||||
// todo: enclose in properties and validate these when assigning.
|
||||
|
||||
@@ -47,49 +47,14 @@ namespace PkmnFoundations.Structures
|
||||
|
||||
}
|
||||
|
||||
// xxx: Data and Unknown0 should be one field.
|
||||
|
||||
/// <summary>
|
||||
/// Obfuscated Pokémon (pkm) data. 220 bytes
|
||||
/// Obfuscated Pokémon (pkm) data. 236 bytes
|
||||
/// </summary>
|
||||
public byte[] Data;
|
||||
|
||||
/// <summary>
|
||||
/// National Dex species number
|
||||
/// </summary>
|
||||
public ushort Species;
|
||||
|
||||
/// <summary>
|
||||
/// Pokémon gender
|
||||
/// </summary>
|
||||
public Genders Gender;
|
||||
|
||||
/// <summary>
|
||||
/// Pokémon level
|
||||
/// </summary>
|
||||
public byte Level;
|
||||
|
||||
/// <summary>
|
||||
/// Requested National Dex species number
|
||||
/// </summary>
|
||||
public ushort RequestedSpecies;
|
||||
|
||||
public Genders RequestedGender;
|
||||
|
||||
public byte RequestedMinLevel;
|
||||
public byte RequestedMaxLevel;
|
||||
public byte Unknown1;
|
||||
public TrainerGenders TrainerGender;
|
||||
public byte Unknown2;
|
||||
|
||||
public DateTime ? TimeDeposited;
|
||||
public DateTime ? TimeExchanged;
|
||||
|
||||
/// <summary>
|
||||
/// User ID of the player (not Personality Value)
|
||||
/// </summary>
|
||||
public int PID;
|
||||
|
||||
public uint TrainerOT;
|
||||
|
||||
/// <summary>
|
||||
@@ -97,15 +62,6 @@ namespace PkmnFoundations.Structures
|
||||
/// </summary>
|
||||
public EncodedString5 TrainerName;
|
||||
|
||||
public byte TrainerCountry;
|
||||
public byte TrainerRegion;
|
||||
public byte TrainerClass;
|
||||
|
||||
public byte IsExchanged;
|
||||
|
||||
public byte TrainerVersion;
|
||||
public byte TrainerLanguage;
|
||||
|
||||
public byte TrainerBadges; // speculative. Usually 8.
|
||||
public byte TrainerUnityTower;
|
||||
|
||||
|
||||
@@ -25,6 +25,50 @@ namespace PkmnFoundations.Structures
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// National Dex species number
|
||||
/// </summary>
|
||||
public ushort Species;
|
||||
|
||||
/// <summary>
|
||||
/// Pokémon gender
|
||||
/// </summary>
|
||||
public Genders Gender;
|
||||
|
||||
/// <summary>
|
||||
/// Pokémon level
|
||||
/// </summary>
|
||||
public byte Level;
|
||||
|
||||
/// <summary>
|
||||
/// Requested National Dex species number
|
||||
/// </summary>
|
||||
public ushort RequestedSpecies;
|
||||
|
||||
public Genders RequestedGender;
|
||||
|
||||
public byte RequestedMinLevel;
|
||||
public byte RequestedMaxLevel;
|
||||
|
||||
public TrainerGenders TrainerGender;
|
||||
|
||||
public DateTime? TimeDeposited;
|
||||
public DateTime? TimeExchanged;
|
||||
|
||||
/// <summary>
|
||||
/// User ID of the player (not Personality Value)
|
||||
/// </summary>
|
||||
public int PID;
|
||||
|
||||
public byte TrainerCountry;
|
||||
public byte TrainerRegion;
|
||||
public byte TrainerClass;
|
||||
|
||||
public byte IsExchanged;
|
||||
|
||||
public byte TrainerVersion;
|
||||
public byte TrainerLanguage;
|
||||
|
||||
public static bool CheckLevels(byte min, byte max, byte other)
|
||||
{
|
||||
if (max == 0) max = 255;
|
||||
|
||||
Reference in New Issue
Block a user