summaryrefslogtreecommitdiff
path: root/debug.c
diff options
context:
space:
mode:
authortruelight <truelight@openttd.org>2005-07-10 14:57:43 +0000
committertruelight <truelight@openttd.org>2005-07-10 14:57:43 +0000
commit3c9456dd45f38386b3357dee2fc93924bdd46696 (patch)
treed80479fbf61384ebe9e039f86a4290aefd69ff45 /debug.c
parentb45eee31570afd2045d199dd18a154c42952ad56 (diff)
downloadopenttd-3c9456dd45f38386b3357dee2fc93924bdd46696.tar.xz
(svn r2542) -Add: [GPMI] Added GPMI (http://sourceforge.net/projects/libgpmi/)
support to OpenTTD in preperation of AIScripts (long term). It is OFF by default. Add GPMI:=1 to Makefile.config to enable.
Diffstat (limited to 'debug.c')
-rw-r--r--debug.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/debug.c b/debug.c
index fe36348fc..089f77850 100644
--- a/debug.c
+++ b/debug.c
@@ -15,6 +15,9 @@ int _debug_net_level;
int _debug_spritecache_level;
int _debug_oldloader_level;
int _debug_pbs_level;
+#ifdef GPMI
+int _debug_gpmi_level;
+#endif /* GPMI */
int _debug_npf_level;
@@ -46,6 +49,9 @@ typedef struct DebugLevel {
DEBUG_LEVEL(spritecache),
DEBUG_LEVEL(oldloader),
DEBUG_LEVEL(pbs),
+#ifdef GPMI
+ DEBUG_LEVEL(gpmi),
+#endif
DEBUG_LEVEL(npf)
};
#undef DEBUG_LEVEL
@@ -120,3 +126,10 @@ const char *GetDebugString(void)
return dbgstr;
}
+
+#ifdef GPMI
+void gpmi_debug_openttd(int level, char *s)
+{
+ DEBUG(gpmi, level)("[GPMI] %s", s);
+}
+#endif /* GPMI */