From 40a8bd556e7daa65c3e63059b871f85c8ffce072 Mon Sep 17 00:00:00 2001 From: rubidium Date: Mon, 10 Aug 2009 10:25:40 +0000 Subject: (svn r17142) -Fix [FS#3103] (r17139): MSVC didn't like some template stuff --- src/gfxinit.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'src/gfxinit.cpp') diff --git a/src/gfxinit.cpp b/src/gfxinit.cpp index 5ec306a4e..22b97efcb 100644 --- a/src/gfxinit.cpp +++ b/src/gfxinit.cpp @@ -106,7 +106,7 @@ void CheckExternalFiles() char *add_pos = error_msg; const char *last = lastof(error_msg); - for (uint i = 0; i < lengthof(used_set->files); i++) { + for (uint i = 0; i < MAX_GFT; i++) { if (!used_set->files[i].CheckMD5()) { add_pos += seprintf(add_pos, last, "Your '%s' file is corrupted or missing! %s\n", used_set->files[i].filename, used_set->files[i].missing_warning); } @@ -231,8 +231,11 @@ bool MD5File::CheckMD5() const } /** Names corresponding to the GraphicsFileType */ +const char *_graphics_file_names[] = { "base", "logos", "arctic", "tropical", "toyland", "extra" }; + +/** Implementation */ template -/* static */ const char *BaseSet::file_names[Tnum_files] = { "base", "logos", "arctic", "tropical", "toyland", "extra" }; +/* static */ const char **BaseSet::file_names = _graphics_file_names; extern void UpdateNewGRFConfigPalette(); -- cgit v1.2.3-54-g00ecf