From fc216aeeb86f5e84db06f51ad1e3172d6c343b3b Mon Sep 17 00:00:00 2001 From: rubidium Date: Tue, 2 Sep 2008 18:45:15 +0000 Subject: (svn r14229) -Feature: allow overriding the palette of the base GRFs. This way you can play with NewGRFs made for the Windows palette with the DOS palettes base GRFs (and vice versa). Note that for this to work correctly ALL NewGRFs must use the same palette; mix and match is not yet supported. --- src/newgrf.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'src/newgrf.cpp') diff --git a/src/newgrf.cpp b/src/newgrf.cpp index a701b2f37..dea96f88c 100644 --- a/src/newgrf.cpp +++ b/src/newgrf.cpp @@ -3652,7 +3652,11 @@ bool GetGlobalVariable(byte param, uint32 *value) } case 0x0D: // TTD Version, 00=DOS, 01=Windows - *value = _use_palette; + if (_palette_remap_grf[_file_index]) { + *value = !_use_palette; + } else { + *value = _use_palette; + } return true; case 0x0E: // Y-offset for train sprites -- cgit v1.2.3-54-g00ecf