summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorYamaArashi <shadow962@live.com>2016-12-29 13:13:07 -0800
committerYamaArashi <shadow962@live.com>2016-12-29 13:13:07 -0800
commitb42f5c0f7fc9ac0161a6b6e2d764911ef375d040 (patch)
tree295e46c51b25e9e85f35f9e7a7e26395b40b77be /include
parent0edc7cbd88b31a6e57608810182781b6cf31b85a (diff)
use BUGFIX ifdefs
Diffstat (limited to 'include')
-rw-r--r--include/config.h15
-rw-r--r--include/global.h5
2 files changed, 16 insertions, 4 deletions
diff --git a/include/config.h b/include/config.h
new file mode 100644
index 000000000..251cbc6c2
--- /dev/null
+++ b/include/config.h
@@ -0,0 +1,15 @@
+#ifndef GUARD_CONFIG_H
+#define GUARD_CONFIG_H
+
+#ifndef REVISION
+#define REVISION 0
+#endif
+
+#if REVISION == 2
+#define BUGFIX_BERRY
+#endif
+
+// European editions of Ruby/Sapphire and all editions of Emerald have this fix.
+// #define BUGFIX_TRAINERAPPROACH
+
+#endif // GUARD_CONFIG_H
diff --git a/include/global.h b/include/global.h
index d23204760..66b6b6b50 100644
--- a/include/global.h
+++ b/include/global.h
@@ -2,10 +2,7 @@
#define GUARD_GLOBAL_H
#include "gba/gba.h"
-
-#ifndef REVISION
-#define REVISION 0
-#endif
+#include "config.h"
// Prevent cross-jump optimization.
#define BLOCK_CROSS_JUMP asm("");