diff options
author | frosch <frosch@openttd.org> | 2011-11-18 14:40:57 +0000 |
---|---|---|
committer | frosch <frosch@openttd.org> | 2011-11-18 14:40:57 +0000 |
commit | 0d901d599f1c492006bd6e5a0aba96a76b42d765 (patch) | |
tree | 9c761b85e9f85890fb07a345494c206e0eccfcb7 /src/newgrf_config.h | |
parent | b725913f3b57110e18114f1f316e810d1d807e35 (diff) | |
download | openttd-0d901d599f1c492006bd6e5a0aba96a76b42d765.tar.xz |
(svn r23249) -Feature: Also allow viewing of the other two textfiles supplied by BaNaNaS tars, i.e. changelog and license.
Diffstat (limited to 'src/newgrf_config.h')
-rw-r--r-- | src/newgrf_config.h | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/src/newgrf_config.h b/src/newgrf_config.h index 7576c9682..94b9a25ce 100644 --- a/src/newgrf_config.h +++ b/src/newgrf_config.h @@ -146,6 +146,18 @@ struct GRFTextWrapper : public SimpleCountedObject { ~GRFTextWrapper(); }; +/** Additional text files accompanying NewGRFs */ +enum TextfileType { + TFT_BEGIN, + + TFT_README = TFT_BEGIN, ///< NewGRF readme + TFT_CHANGELOG, ///< NewGRF changelog + TFT_LICENSE, ///< NewGRF license + + TFT_END +}; +DECLARE_POSTFIX_INCREMENT(TextfileType) + /** Information about GRF, used in the game and (part of it) in savegames */ struct GRFConfig : ZeroedMemoryAllocator { GRFConfig(const char *filename = NULL); @@ -175,7 +187,7 @@ struct GRFConfig : ZeroedMemoryAllocator { bool IsOpenTTDBaseGRF() const; - const char *GetTextfile() const; + const char *GetTextfile(TextfileType type) const; const char *GetName() const; const char *GetDescription() const; |