summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2011-12-22 20:05:52 +0000
committerrubidium <rubidium@openttd.org>2011-12-22 20:05:52 +0000
commitd17552822005b76f91c09c18a2033b28e0282c7c (patch)
tree95ae6a112ca2ff834e81ef81e176bdf0d4f321c3
parent3f48d127b7126752ee53996f38498e56d3da6f1b (diff)
downloadopenttd-d17552822005b76f91c09c18a2033b28e0282c7c.tar.xz
(svn r23660) -Feature-ish: add the game script to the crash log
-rw-r--r--src/crashlog.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/crashlog.cpp b/src/crashlog.cpp
index c5719ad47..8948fec1d 100644
--- a/src/crashlog.cpp
+++ b/src/crashlog.cpp
@@ -28,6 +28,8 @@
#include "language.h"
#include "ai/ai_info.hpp"
+#include "game/game.hpp"
+#include "game/game_info.hpp"
#include "company_base.h"
#include "company_func.h"
@@ -154,6 +156,10 @@ char *CrashLog::LogConfiguration(char *buffer, const char *last) const
buffer += seprintf(buffer, last, " %2i: %s (v%d)\n", (int)c->index, c->ai_info->GetName(), c->ai_info->GetVersion());
}
}
+
+ if (Game::GetInfo() != NULL) {
+ buffer += seprintf(buffer, last, " GS: %s (v%d)\n", Game::GetInfo()->GetName(), Game::GetInfo()->GetVersion());
+ }
buffer += seprintf(buffer, last, "\n");
return buffer;