summaryrefslogtreecommitdiff
path: root/include/global.h
diff options
context:
space:
mode:
authorKDSKardabox <bollygame94@gmail.com>2018-02-18 17:35:36 +0530
committerKDSKardabox <bollygame94@gmail.com>2018-02-18 17:35:36 +0530
commit5ed68a87f830d7d8613d00d692629618f3df673f (patch)
tree57826021bd98aa7c42a823e6d0d0fb4a00f0b006 /include/global.h
parentb1cb82fc670ebbb7bcb8de85c780344e6dbd9349 (diff)
parentef3a7a06b4e6192a6072b4ab221a54484bee91dc (diff)
Merge branch 'master' of https://github.com/pret/pokeemerald
Diffstat (limited to 'include/global.h')
-rw-r--r--include/global.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/include/global.h b/include/global.h
index 8c56c0a58..f88203c90 100644
--- a/include/global.h
+++ b/include/global.h
@@ -35,6 +35,12 @@
// Converts a number to Q4.12 fixed-point format
#define Q_4_12(n) ((s16)((n) * 4096))
+// Converts a Q8.8 fixed-point format number to a regular integer
+#define Q_8_8_TO_INT(n) ((int)((n) / 256))
+
+// Converts a Q4.12 fixed-point format number to a regular integer
+#define Q_4_12_TO_INT(n) ((int)((n) / 4096))
+
#define PARTY_SIZE 6
#define POKEMON_NAME_LENGTH 10