about summary refs log tree commit diff stats
path: root/gba/source/gamedata.h
diff options
context:
space:
mode:
Diffstat (limited to 'gba/source/gamedata.h')
-rw-r--r--gba/source/gamedata.h29
1 files changed, 29 insertions, 0 deletions
diff --git a/gba/source/gamedata.h b/gba/source/gamedata.h new file mode 100644 index 0000000..4d0a2a9 --- /dev/null +++ b/gba/source/gamedata.h
@@ -0,0 +1,29 @@
1/*
2 * Copyright (C) 2017 hatkirby
3 * Copyright (C) 2017 slipstream/RoL
4 *
5 * This software may be modified and distributed under the terms
6 * of the MIT license. See the LICENSE file for details.
7 */
8#ifndef _GAMEDATA_H_
9#define _GAMEDATA_H_
10
11#include <gba.h>
12#include "saveblocks.h"
13
14#define GAME_RUBY (((*(u32*)(0x80000AC)) << 8) == 'VXA\x00')
15#define GAME_SAPP (((*(u32*)(0x80000AC)) << 8) == 'PXA\x00')
16#define GAME_RS ((GAME_RUBY) || (GAME_SAPP))
17#define GAME_FR (((*(u32*)(0x80000AC)) << 8) == 'RPB\x00')
18#define GAME_LG (((*(u32*)(0x80000AC)) << 8) == 'GPB\x00')
19#define GAME_FRLG ((GAME_FR) || (GAME_LG))
20#define GAME_EM (((*(u32*)(0x80000AC)) << 8) == 'EPB\x00')
21
22#define LANG_JAPAN ((*(u8*)(0x80000AF)) == 'J')
23
24bool initSaveData(
25 pSaveBlock1* SaveBlock1,
26 pSaveBlock2* SaveBlock2,
27 pSaveBlock3* SaveBlock3);
28
29#endif