summaryrefslogtreecommitdiff
path: root/include/global.h
diff options
context:
space:
mode:
authorProjectRevoTPP <projectrevotpp@hotmail.com>2017-09-23 15:02:32 -0400
committerProjectRevoTPP <projectrevotpp@hotmail.com>2017-09-23 15:02:32 -0400
commitd740eabb3c19bae406d184c6f29c81b2c5dc952f (patch)
treed3641957151d385b2ddaeb4c944da3cef54583f2 /include/global.h
parent57543e164e0ed15c23e295ffa08e5804d4d32037 (diff)
parenta57915fa5bd8c2e68bc291a371e66e3cafd7e195 (diff)
merge
Diffstat (limited to 'include/global.h')
-rw-r--r--include/global.h11
1 files changed, 10 insertions, 1 deletions
diff --git a/include/global.h b/include/global.h
index fa7856786..4014c6dde 100644
--- a/include/global.h
+++ b/include/global.h
@@ -18,6 +18,14 @@ void memcpy(void *, const void *, size_t);
#define ARRAY_COUNT(array) (sizeof(array) / sizeof((array)[0]))
+// useful math macros
+
+// Converts a number to Q8.8 fixed-point format
+#define Q_8_8(n) ((s16)((n) * 256))
+
+// Converts a number to Q4.12 fixed-point format
+#define Q_4_12(n) ((s16)((n) * 4096))
+
#define POKEMON_NAME_LENGTH 10
#define OT_NAME_LENGTH 7
@@ -645,7 +653,8 @@ struct DaycareMon
struct MailStruct mail;
u8 OT_name[OT_NAME_LENGTH + 1];
u8 monName[11];
- u8 language;
+ u8 language_maybe : 4;
+ u8 unknown : 4;
u32 stepsTaken;
};