mirror of
https://github.com/pret/pokeheartgold.git
synced 2024-12-18 02:18:14 +00:00
Fill out player_data.h structs
This commit is contained in:
parent
6b6d92e7dc
commit
60f161432a
@ -1,16 +1,16 @@
|
||||
#ifndef POKEHEARTGOLD_IGT_H
|
||||
#define POKEHEARTGOLD_IGT_H
|
||||
|
||||
struct IGT {
|
||||
typedef struct IGT {
|
||||
u16 hours;
|
||||
u8 minutes;
|
||||
u8 seconds;
|
||||
};
|
||||
} IGT;
|
||||
|
||||
void InitIGT(struct IGT* igt);
|
||||
void AddIGTSeconds(struct IGT* igt, u32 seconds_to_add);
|
||||
u16 GetIGTHours(struct IGT* igt);
|
||||
u8 GetIGTMinutes(struct IGT* igt);
|
||||
u8 GetIGTSeconds(struct IGT* igt);
|
||||
void InitIGT(IGT* igt);
|
||||
void AddIGTSeconds(IGT* igt, u32 seconds_to_add);
|
||||
u16 GetIGTHours(IGT* igt);
|
||||
u8 GetIGTMinutes(IGT* igt);
|
||||
u8 GetIGTSeconds(IGT* igt);
|
||||
|
||||
#endif
|
||||
|
@ -2,8 +2,31 @@
|
||||
#define POKEHEARTGOLD_PLAYER_DATA_H
|
||||
|
||||
#include "save.h"
|
||||
#include "options.h"
|
||||
#include "coins.h"
|
||||
#include "igt.h"
|
||||
|
||||
typedef struct PLAYERDATA PLAYERDATA;
|
||||
typedef struct PLAYERPROFILE {
|
||||
u16 name[OT_NAME_LENGTH + 1];
|
||||
u32 id;
|
||||
u32 money;
|
||||
u8 gender;
|
||||
u8 language;
|
||||
u8 johtoBadges;
|
||||
u8 avatar;
|
||||
u8 version;
|
||||
u8 gameClear:1;
|
||||
u8 natDex:1;
|
||||
u8 dummy;
|
||||
u8 kantoBadges;
|
||||
} PLAYERPROFILE;
|
||||
|
||||
typedef struct PLAYERDATA {
|
||||
OPTIONS options;
|
||||
PLAYERPROFILE profile;
|
||||
u16 coins;
|
||||
IGT igt;
|
||||
} PLAYERDATA;
|
||||
|
||||
u16 *Sav2_PlayerData_GetCoinsAddr(SAVEDATA *saveData);
|
||||
|
||||
|
@ -21,6 +21,5 @@ typedef struct POKEWALKER {
|
||||
} POKEWALKER; // size=0x134
|
||||
|
||||
void Pokewalker_UnlockCourse(POKEWALKER *pokeWalker, int courseNo);
|
||||
BOOL sub_020326FC(POKEWALKER *pokeWalker);
|
||||
|
||||
#endif //POKEHEARTGOLD_POKEWALKER_H
|
||||
|
@ -1,5 +1,7 @@
|
||||
#include "pokewalker.h"
|
||||
|
||||
static BOOL sub_020326FC(POKEWALKER *pokeWalker);
|
||||
|
||||
POKEWALKER *Sav2_Pokewalker_get(SAVEDATA *saveData) {
|
||||
return SavArray_get(saveData, SAVE_POKEWALKER);
|
||||
}
|
||||
@ -69,7 +71,9 @@ BOOL sub_020326DC(POKEWALKER *pokeWalker, BOXMON *boxmon) {
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
BOOL sub_020326FC(POKEWALKER *pokeWalker) {
|
||||
static BOOL sub_020326FC(POKEWALKER *pokeWalker) {
|
||||
// This is an annoying hack to get it matching.
|
||||
// Should just memcmp with (BOXMON){}
|
||||
u8 * ptr = (u8 *)pokeWalker;
|
||||
int i;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user