From c9120cd71491f5be5c056ccde420b8d146eccb68 Mon Sep 17 00:00:00 2001 From: frosch Date: Sun, 9 Aug 2015 10:21:06 +0000 Subject: [PATCH 01/29] (svn r27365) -Fix: Center settings filter warning also vertically, and also in case of multiple lines. --- src/settings_gui.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/settings_gui.cpp b/src/settings_gui.cpp index f1af4804e4..19949671f4 100644 --- a/src/settings_gui.cpp +++ b/src/settings_gui.cpp @@ -1883,13 +1883,13 @@ struct GameSettingsWindow : Window { if (this->warn_missing != WHR_NONE) { const int left = panel->pos_x; const int right = left + panel->current_x - 1; - const int top = panel->pos_y; + const int top = panel->pos_y + WD_FRAMETEXT_TOP + (SETTING_HEIGHT - FONT_HEIGHT_NORMAL) * this->warn_lines / 2; SetDParam(0, _game_settings_restrict_dropdown[this->filter.min_cat]); if (this->warn_lines == 1) { /* If the warning fits at one line, center it. */ - DrawString(left + WD_FRAMETEXT_LEFT, right - WD_FRAMETEXT_RIGHT, top + WD_FRAMETEXT_TOP, warn_str, TC_FROMSTRING, SA_HOR_CENTER); + DrawString(left + WD_FRAMETEXT_LEFT, right - WD_FRAMETEXT_RIGHT, top, warn_str, TC_FROMSTRING, SA_HOR_CENTER); } else { - DrawStringMultiLine(left + WD_FRAMERECT_LEFT, right - WD_FRAMERECT_RIGHT, top + WD_FRAMERECT_TOP, INT32_MAX, warn_str); + DrawStringMultiLine(left + WD_FRAMERECT_LEFT, right - WD_FRAMERECT_RIGHT, top, INT32_MAX, warn_str, TC_FROMSTRING, SA_HOR_CENTER); } } } From 9f72662ecc3915b8ea217c68c54257b8ad108d53 Mon Sep 17 00:00:00 2001 From: frosch Date: Sun, 9 Aug 2015 10:22:51 +0000 Subject: [PATCH 02/29] (svn r27366) -Fix [FS#6358]: Clickareas in settings tree were misaligned when the filter warning was displayed, if the setting height was defined by the icons instead of the font. --- src/settings_gui.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/settings_gui.cpp b/src/settings_gui.cpp index 19949671f4..0652d1bd81 100644 --- a/src/settings_gui.cpp +++ b/src/settings_gui.cpp @@ -1943,7 +1943,7 @@ struct GameSettingsWindow : Window { { switch (widget) { case WID_GS_OPTIONSPANEL: { - int top_pos = r.top + SETTINGTREE_TOP_OFFSET + 1 + this->warn_lines * FONT_HEIGHT_NORMAL; + int top_pos = r.top + SETTINGTREE_TOP_OFFSET + 1 + this->warn_lines * SETTING_HEIGHT; uint last_row = this->vscroll->GetPosition() + this->vscroll->GetCapacity() - this->warn_lines; int next_row = GetSettingsTree().Draw(settings_ptr, r.left + SETTINGTREE_LEFT_OFFSET, r.right - SETTINGTREE_RIGHT_OFFSET, top_pos, this->vscroll->GetPosition(), last_row, this->last_clicked); From ee700fd3b16a2f68095fe96f5d9f56aba532d608 Mon Sep 17 00:00:00 2001 From: rubidium Date: Sun, 9 Aug 2015 12:33:27 +0000 Subject: [PATCH 03/29] (svn r27367) -Codechange: make a distinction between the layouting part of ICU (lx) or the sorting/collation part of ICU (i18n) --- config.lib | 2 +- src/crashlog.cpp | 15 ++++++++++----- src/gfx_layout.cpp | 10 +++++----- src/gfx_layout.h | 10 +++++----- src/language.h | 8 ++++---- src/string.cpp | 10 +++++----- src/strings.cpp | 12 ++++++------ 7 files changed, 36 insertions(+), 31 deletions(-) diff --git a/config.lib b/config.lib index 68d8b13a8e..6fed7e803b 100644 --- a/config.lib +++ b/config.lib @@ -1754,7 +1754,7 @@ make_cflags_and_ldflags() { fi if [ -n "$icu_config" ]; then - CFLAGS="$CFLAGS -DWITH_ICU" + CFLAGS="$CFLAGS -DWITH_ICU_LAYOUT -DWITH_ICU_SORT" CFLAGS="$CFLAGS `$icu_config --cppflags | tr '\n\r' ' '`" # Some icu-configs have the 'feature' of not adding a space where others do add the space diff --git a/src/crashlog.cpp b/src/crashlog.cpp index e8290a7c3f..7ddc2131f9 100644 --- a/src/crashlog.cpp +++ b/src/crashlog.cpp @@ -196,9 +196,9 @@ char *CrashLog::LogConfiguration(char *buffer, const char *last) const # include # include FT_FREETYPE_H #endif /* WITH_FREETYPE */ -#ifdef WITH_ICU +#if defined(WITH_ICU_LAYOUT) || defined(WITH_ICU_SORT) # include -#endif /* WITH_ICU */ +#endif /* WITH_ICU_SORT || WITH_ICU_LAYOUT */ #ifdef WITH_LZMA # include #endif @@ -241,14 +241,19 @@ char *CrashLog::LogLibraries(char *buffer, const char *last) const buffer += seprintf(buffer, last, " FreeType: %d.%d.%d\n", major, minor, patch); #endif /* WITH_FREETYPE */ -#ifdef WITH_ICU +#if defined(WITH_ICU_LAYOUT) || defined(WITH_ICU_SORT) /* 4 times 0-255, separated by dots (.) and a trailing '\0' */ char buf[4 * 3 + 3 + 1]; UVersionInfo ver; u_getVersion(ver); u_versionToString(ver, buf); - buffer += seprintf(buffer, last, " ICU: %s\n", buf); -#endif /* WITH_ICU */ +#ifdef WITH_ICU_SORT + buffer += seprintf(buffer, last, " ICU i18n: %s\n", buf); +#endif +#ifdef WITH_ICU_LAYOUT + buffer += seprintf(buffer, last, " ICU lx: %s\n", buf); +#endif +#endif /* WITH_ICU_SORT || WITH_ICU_LAYOUT */ #ifdef WITH_LZMA buffer += seprintf(buffer, last, " LZMA: %s\n", lzma_version_string()); diff --git a/src/gfx_layout.cpp b/src/gfx_layout.cpp index 2dba6a2046..f5463d4015 100644 --- a/src/gfx_layout.cpp +++ b/src/gfx_layout.cpp @@ -17,9 +17,9 @@ #include "table/control_codes.h" -#ifdef WITH_ICU +#ifdef WITH_ICU_LAYOUT #include -#endif /* WITH_ICU */ +#endif /* WITH_ICU_LAYOUT */ #include "safeguards.h" @@ -42,7 +42,7 @@ Font::Font(FontSize size, TextColour colour) : assert(size < FS_END); } -#ifdef WITH_ICU +#ifdef WITH_ICU_LAYOUT /* Implementation details of LEFontInstance */ le_int32 Font::getUnitsPerEM() const @@ -213,7 +213,7 @@ static ParagraphLayouter *GetParagraphLayout(UChar *buff, UChar *buff_end, FontM return new ICUParagraphLayout(p); } -#endif /* WITH_ICU */ +#endif /* WITH_ICU_LAYOUT */ /*** Paragraph layout ***/ /** @@ -654,7 +654,7 @@ Layouter::Layouter(const char *str, int maxw, TextColour colour, FontSize fontsi line.layout->Reflow(); } else { /* Line is new, layout it */ -#ifdef WITH_ICU +#ifdef WITH_ICU_LAYOUT FontState old_state = state; const char *old_str = str; diff --git a/src/gfx_layout.h b/src/gfx_layout.h index 7cd70ce280..0a21d9b0ca 100644 --- a/src/gfx_layout.h +++ b/src/gfx_layout.h @@ -19,12 +19,12 @@ #include #include -#ifdef WITH_ICU +#ifdef WITH_ICU_LAYOUT #include "layout/ParagraphLayout.h" #define ICU_FONTINSTANCE : public LEFontInstance -#else /* WITH_ICU */ +#else /* WITH_ICU_LAYOUT */ #define ICU_FONTINSTANCE -#endif /* WITH_ICU */ +#endif /* WITH_ICU_LAYOUT */ /** * Text drawing parameters, which can change while drawing a line, but are kept between multiple parts @@ -75,7 +75,7 @@ public: Font(FontSize size, TextColour colour); -#ifdef WITH_ICU +#ifdef WITH_ICU_LAYOUT /* Implementation details of LEFontInstance */ le_int32 getUnitsPerEM() const; @@ -91,7 +91,7 @@ public: LEGlyphID mapCharToGlyph(LEUnicode32 ch) const; void getGlyphAdvance(LEGlyphID glyph, LEPoint &advance) const; le_bool getGlyphPoint(LEGlyphID glyph, le_int32 pointNumber, LEPoint &point) const; -#endif /* WITH_ICU */ +#endif /* WITH_ICU_LAYOUT */ }; /** Mapping from index to font. */ diff --git a/src/language.h b/src/language.h index 694b0ca1bb..fed138e635 100644 --- a/src/language.h +++ b/src/language.h @@ -13,9 +13,9 @@ #define LANGUAGE_H #include "core/smallvec_type.hpp" -#ifdef WITH_ICU +#ifdef WITH_ICU_SORT #include -#endif /* WITH_ICU */ +#endif /* WITH_ICU_SORT */ static const uint8 CASE_GENDER_LEN = 16; ///< The (maximum) length of a case/gender string. static const uint8 MAX_NUM_GENDERS = 8; ///< Maximum number of supported genders. @@ -110,9 +110,9 @@ extern LanguageList _languages; /** The currently loaded language. */ extern const LanguageMetadata *_current_language; -#ifdef WITH_ICU +#ifdef WITH_ICU_SORT extern Collator *_current_collator; -#endif /* WITH_ICU */ +#endif /* WITH_ICU_SORT */ bool ReadLanguagePack(const LanguageMetadata *lang); const LanguageMetadata *GetLanguage(byte newgrflangid); diff --git a/src/string.cpp b/src/string.cpp index 6bc9319c1c..377fb7f98d 100644 --- a/src/string.cpp +++ b/src/string.cpp @@ -25,12 +25,12 @@ #include // required by vsnprintf implementation for MSVC #endif -#ifdef WITH_ICU +#ifdef WITH_ICU_SORT /* Required by strnatcmp. */ #include #include "language.h" #include "gfx_func.h" -#endif /* WITH_ICU */ +#endif /* WITH_ICU_SORT */ /* The function vsnprintf is used internally to perform the required formatting * tasks. As such this one must be allowed, and makes sure it's terminated. */ @@ -572,7 +572,7 @@ int strnatcmp(const char *s1, const char *s2, bool ignore_garbage_at_front) s1 = SkipGarbage(s1); s2 = SkipGarbage(s2); } -#ifdef WITH_ICU +#ifdef WITH_ICU_SORT if (_current_collator != NULL) { UErrorCode status = U_ZERO_ERROR; int result; @@ -592,13 +592,13 @@ int strnatcmp(const char *s1, const char *s2, bool ignore_garbage_at_front) if (U_SUCCESS(status)) return result; } -#endif /* WITH_ICU */ +#endif /* WITH_ICU_SORT */ /* Do a normal comparison if ICU is missing or if we cannot create a collator. */ return strcasecmp(s1, s2); } -#ifdef WITH_ICU +#ifdef WITH_ICU_SORT #include #include diff --git a/src/strings.cpp b/src/strings.cpp index 9c88b70c77..5d1059243c 100644 --- a/src/strings.cpp +++ b/src/strings.cpp @@ -49,9 +49,9 @@ const LanguageMetadata *_current_language = NULL; ///< The currently loaded lang TextDirection _current_text_dir; ///< Text direction of the currently selected language. -#ifdef WITH_ICU +#ifdef WITH_ICU_SORT Collator *_current_collator = NULL; ///< Collator for the language currently in use. -#endif /* WITH_ICU */ +#endif /* WITH_ICU_SORT */ static uint64 _global_string_params_data[20]; ///< Global array of string parameters. To access, use #SetDParam. static WChar _global_string_params_type[20]; ///< Type of parameters stored in #_decode_parameters @@ -1790,7 +1790,7 @@ bool ReadLanguagePack(const LanguageMetadata *lang) strecpy(_config_language_file, c_file, lastof(_config_language_file)); SetCurrentGrfLangID(_current_language->newgrflangid); -#ifdef WITH_ICU +#ifdef WITH_ICU_SORT /* Delete previous collator. */ if (_current_collator != NULL) { delete _current_collator; @@ -1807,7 +1807,7 @@ bool ReadLanguagePack(const LanguageMetadata *lang) delete _current_collator; _current_collator = NULL; } -#endif /* WITH_ICU */ +#endif /* WITH_ICU_SORT */ /* Some lists need to be sorted again after a language change. */ ReconsiderGameScriptLanguage(); @@ -2132,7 +2132,7 @@ void CheckForMissingGlyphs(bool base_font, MissingGlyphSearcher *searcher) /* Update the font with cache */ LoadStringWidthTable(searcher->Monospace()); -#if !defined(WITH_ICU) +#if !defined(WITH_ICU_LAYOUT) /* * For right-to-left languages we need the ICU library. If * we do not have support for that library we warn the user @@ -2152,5 +2152,5 @@ void CheckForMissingGlyphs(bool base_font, MissingGlyphSearcher *searcher) SetDParamStr(0, err_str); ShowErrorMessage(STR_JUST_RAW_STRING, INVALID_STRING_ID, WL_ERROR); } -#endif +#endif /* !WITH_ICU_LAYOUT */ } From 625bc2e0e716e60637efa0bd556ebbb8a7c6d12d Mon Sep 17 00:00:00 2001 From: rubidium Date: Sun, 9 Aug 2015 12:37:20 +0000 Subject: [PATCH 04/29] (svn r27368) -Cleanup: undo the special case of OSX; it works fine without it --- config.lib | 23 +++-------------------- 1 file changed, 3 insertions(+), 20 deletions(-) diff --git a/config.lib b/config.lib index 6fed7e803b..67e8704289 100644 --- a/config.lib +++ b/config.lib @@ -1708,13 +1708,7 @@ make_cflags_and_ldflags() { CFLAGS="$CFLAGS `$png_config --cflags | tr '\n\r' ' '`" if [ "$enable_static" != "0" ]; then - if [ "$os" = "OSX" ]; then - # fontconfig_config goes via pkg-config on all systems, which doesn't know --prefix - # Also, despite the reason we link to the .a file ourself (because we can't use -static), we do need to ask pkg-config about possible other deps - LIBS="$LIBS `$png_config --variable=prefix`/lib/libpng.a `$png_config --libs --static | sed s@-lpng[0-9]*@@`" - else - LIBS="$LIBS `$png_config --libs --static | tr '\n\r' ' '`" - fi + LIBS="$LIBS `$png_config --libs --static | tr '\n\r' ' '`" else LIBS="$LIBS `$png_config --libs | tr '\n\r' ' '`" fi @@ -1725,13 +1719,7 @@ make_cflags_and_ldflags() { CFLAGS="$CFLAGS `$fontconfig_config --cflags | tr '\n\r' ' '`" if [ "$enable_static" != "0" ]; then - if [ "$os" = "OSX" ]; then - # fontconfig_config goes via pkg-config on all systems, which doesn't know --prefix - # Also, despite the reason we link to the .a file ourself (because we can't use -static), we do need to ask pkg-config about possible other deps - LIBS="$LIBS `$fontconfig_config --variable=prefix`/lib/libfontconfig.a `$fontconfig_config --libs --static | sed s@-lfontconfig@@`" - else - LIBS="$LIBS `$fontconfig_config --libs --static | tr '\n\r' ' '`" - fi + LIBS="$LIBS `$fontconfig_config --libs --static | tr '\n\r' ' '`" else LIBS="$LIBS `$fontconfig_config --libs | tr '\n\r' ' '`" fi @@ -1742,12 +1730,7 @@ make_cflags_and_ldflags() { CFLAGS="$CFLAGS `$freetype_config --cflags | tr '\n\r' ' '`" if [ "$enable_static" != "0" ]; then - if [ "$os" = "OSX" ]; then - LIBS="$LIBS `$freetype_config --prefix`/lib/libfreetype.a" - else - # Is it possible to do static with freetype, if so: how? - LIBS="$LIBS `$freetype_config --libs | tr '\n\r' ' '`" - fi + LIBS="$LIBS `$freetype_config --libs --static | tr '\n\r' ' '`" else LIBS="$LIBS `$freetype_config --libs | tr '\n\r' ' '`" fi From a08d1a044f392f309ab2fcea91c49f0f7adb722e Mon Sep 17 00:00:00 2001 From: rubidium Date: Sun, 9 Aug 2015 12:39:26 +0000 Subject: [PATCH 05/29] (svn r27369) -Cleanup: there's no need to do dependency checking of libraries in OpenTTD; zlib should always be installed if libpng is because it links to zlib --- config.lib | 45 --------------------------------------------- 1 file changed, 45 deletions(-) diff --git a/config.lib b/config.lib index 67e8704289..d6181fcd78 100644 --- a/config.lib +++ b/config.lib @@ -2784,29 +2784,6 @@ detect_xdg_basedir() { } detect_png() { - # 0 means no, 1 is auto-detect, 2 is force - if [ "$with_png" = "0" ]; then - log 1 "checking libpng... disabled" - - png_config="" - return 0 - fi - - if [ "$with_zlib" = "0" ] || [ -z "$zlib" ]; then - if [ "$with_png" != "1" ]; then - log 1 "checking libpng... no zlib" - log 1 "ERROR: libpng was forced, but zlib was not detected / disabled." - log 1 "ERROR: libpng depends on zlib." - - exit 1 - fi - - log 1 "checking libpng... no zlib, skipping" - - png_config="" - return 0 - fi - detect_pkg_config "$with_png" "libpng" "png_config" "1.2" } @@ -2825,21 +2802,6 @@ detect_freetype() { return 0 fi - if [ "$with_zlib" = "0" ] || [ -z "$zlib" ]; then - if [ "$with_freetype" != "1" ]; then - log 1 "checking libfreetype... no zlib" - log 1 "ERROR: libfreetype was forced, but zlib was not detected / disabled." - log 1 "ERROR: libfreetype depends on zlib." - - exit 1 - fi - - log 1 "checking libfreetype... no zlib, skipping" - - freetype_config="" - return 0 - fi - if [ "$with_freetype" = "1" ] || [ "$with_freetype" = "" ] || [ "$with_freetype" = "2" ]; then freetype_config="freetype-config" else @@ -2883,13 +2845,6 @@ detect_fontconfig() { fontconfig_config="" return 0 fi - if [ "$with_fontconfig" != "2" ] && [ -z "$freetype_config" ]; then - log 1 "checking libfontconfig... no freetype, skipping" - - fontconfig_config="" - return 0 - fi - if [ "$os" = "MINGW" ] || [ "$os" = "CYGWIN" ] || [ "$os" = "WINCE" ]; then log 1 "checking libfontconfig... WIN32, skipping" fontconfig_config="" From 2aee2899e84fa289030c08c9ab722a708accd11c Mon Sep 17 00:00:00 2001 From: rubidium Date: Sun, 9 Aug 2015 12:40:17 +0000 Subject: [PATCH 06/29] (svn r27370) -Codechange: move the "dedicated server" check into the pkg-config check routine --- config.lib | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/config.lib b/config.lib index d6181fcd78..e50839e772 100644 --- a/config.lib +++ b/config.lib @@ -2728,6 +2728,7 @@ detect_pkg_config() { # $2 - package name ('liblzma') # $3 - config name ('lzma_config', sets $lzma_config) # $4 - minimum module version ('2.3') + # $5 - check for dedicated, 1 is "skif if dedicated" # 0 means no, 1 is auto-detect, 2 is force if [ "$1" = "0" ]; then @@ -2737,6 +2738,13 @@ detect_pkg_config() { return 0 fi + if [ "$5" = "1" ] && [ "$1" = "1" ] && [ "$enable_dedicated" != "0" ]; then + log 1 "checking $2... dedicated server, skipping" + + eval "$3=\"\"" + return 0 + fi + log 2 "detecting $2" if [ "$1" = "1" ] || [ "$1" = "" ] || [ "$1" = "2" ]; then @@ -2839,12 +2847,6 @@ detect_fontconfig() { fontconfig_config="" return 0 fi - if [ "$with_fontconfig" = "1" ] && [ "$enable_dedicated" != "0" ]; then - log 1 "checking libfontconfig... dedicated server, skipping" - - fontconfig_config="" - return 0 - fi if [ "$os" = "MINGW" ] || [ "$os" = "CYGWIN" ] || [ "$os" = "WINCE" ]; then log 1 "checking libfontconfig... WIN32, skipping" fontconfig_config="" @@ -2857,7 +2859,7 @@ detect_fontconfig() { return 0 fi - detect_pkg_config "$with_fontconfig" "fontconfig" "fontconfig_config" "2.3" + detect_pkg_config "$with_fontconfig" "fontconfig" "fontconfig_config" "2.3" "1" } detect_icu() { From f179a92007a5d05f722a53d2b6f69cb056982cb8 Mon Sep 17 00:00:00 2001 From: rubidium Date: Sun, 9 Aug 2015 12:41:12 +0000 Subject: [PATCH 07/29] (svn r27371) -Codechange: make freetype detection and configuration use pkg-config --- config.lib | 44 ++------------------------------------------ 1 file changed, 2 insertions(+), 42 deletions(-) diff --git a/config.lib b/config.lib index e50839e772..bcc1d30645 100644 --- a/config.lib +++ b/config.lib @@ -2796,47 +2796,7 @@ detect_png() { } detect_freetype() { - # 0 means no, 1 is auto-detect, 2 is force - if [ "$with_freetype" = "0" ]; then - log 1 "checking libfreetype... disabled" - - freetype_config="" - return 0 - fi - if [ "$with_freetype" = "1" ] && [ "$enable_dedicated" != "0" ]; then - log 1 "checking libfreetype... dedicated server, skipping" - - freetype_config="" - return 0 - fi - - if [ "$with_freetype" = "1" ] || [ "$with_freetype" = "" ] || [ "$with_freetype" = "2" ]; then - freetype_config="freetype-config" - else - freetype_config="$with_freetype" - fi - - version=`$freetype_config --version 2>/dev/null` - ret=$? - log 2 "executing freetype_config --version" - log 2 " returned $version" - log 2 " exit code $ret" - - if [ -z "$version" ] || [ "$ret" != "0" ]; then - log 1 "checking libfreetype... not found" - - # It was forced, so it should be found. - if [ "$with_freetype" != "1" ]; then - log 1 "configure: error: freetype-config couldn't be found" - log 1 "configure: error: you supplied '$with_freetype', but it seems invalid" - exit 1 - fi - - freetype_config="" - return 0 - fi - - log 1 "checking libfreetype... found" + detect_pkg_config "$with_freetype" "freetype2" "freetype_config" "2.2" "1" } detect_fontconfig() { @@ -3634,7 +3594,7 @@ showhelp() { echo " enables liblzma support" echo " --with-liblzo2[=liblzo2.a] enables liblzo2 support" echo " --with-png[=libpng-config] enables libpng support" - echo " --with-freetype[=freetype-config]" + echo " --with-freetype[=\"pkg-config freetype2\"]" echo " enables libfreetype support" echo " --with-fontconfig[=\"pkg-config fontconfig\"]" echo " enables fontconfig support" From f05d71a9a6ee9a8ae9518946d7c9b50b0214a46d Mon Sep 17 00:00:00 2001 From: rubidium Date: Sun, 9 Aug 2015 12:41:35 +0000 Subject: [PATCH 08/29] (svn r27372) -Codechange: make allegro detection and configuration use pkg-config --- config.lib | 32 +++----------------------------- 1 file changed, 3 insertions(+), 29 deletions(-) diff --git a/config.lib b/config.lib index bcc1d30645..52c9aaee12 100644 --- a/config.lib +++ b/config.lib @@ -2353,7 +2353,7 @@ detect_allegro() { return 0 fi - # By default on OSX we don't use SDL. The rest is auto-detect + # By default on OSX we don't use Allegro. The rest is auto-detect if [ "$with_allegro" = "1" ] && [ "$os" = "OSX" ] && [ "$with_cocoa" != "0" ]; then log 1 "checking Allegro... OSX, skipping" @@ -2361,33 +2361,7 @@ detect_allegro() { return 0 fi - if [ "$with_allegro" = "1" ] || [ "$with_allegro" = "" ] || [ "$with_allegro" = "2" ]; then - allegro_config="allegro-config" - else - allegro_config="$with_allegro" - fi - - version=`$allegro_config --version 2>/dev/null` - ret=$? - log 2 "executing $allegro_config --version" - log 2 " returned $version" - log 2 " exit code $ret" - - if [ -z "$version" ] || [ "$ret" != "0" ]; then - log 1 "checking Allegro... not found" - - # It was forced, so it should be found. - if [ "$with_allegro" != "1" ]; then - log 1 "configure: error: allegro-config couldn't be found" - log 1 "configure: error: you supplied '$with_allegro', but it seems invalid" - exit 1 - fi - - allegro_config="" - return 0 - fi - - log 1 "checking Allegro... found" + detect_pkg_config "$with_allegro" "allegro" "allegro_config" "4.4" } @@ -3585,7 +3559,7 @@ showhelp() { echo " --with-midi-arg=arg define which args to use for the" echo " midi-player" echo " --with-libtimidity enables libtimidity support" - echo " --with-allegro[=allegro-config]" + echo " --with-allegro[=\"pkg-config allegro\"]" echo " enables Allegro video driver support" echo " --with-cocoa enables COCOA video driver (OSX ONLY)" echo " --with-sdl[=sdl-config] enables SDL video driver support" From c3715a025d575d198664e4ef94f68e791126e1f8 Mon Sep 17 00:00:00 2001 From: rubidium Date: Sun, 9 Aug 2015 12:41:54 +0000 Subject: [PATCH 09/29] (svn r27373) -Codechange: make sdl detection and configuration use pkg-config --- config.lib | 30 ++---------------------------- 1 file changed, 2 insertions(+), 28 deletions(-) diff --git a/config.lib b/config.lib index 52c9aaee12..4dbf858002 100644 --- a/config.lib +++ b/config.lib @@ -2407,33 +2407,7 @@ detect_sdl() { sleep 5 fi - if [ "$with_sdl" = "1" ] || [ "$with_sdl" = "" ] || [ "$with_sdl" = "2" ]; then - sdl_config="sdl-config" - else - sdl_config="$with_sdl" - fi - - version=`$sdl_config --version 2>/dev/null` - ret=$? - log 2 "executing $sdl_config --version" - log 2 " returned $version" - log 2 " exit code $ret" - - if [ -z "$version" ] || [ "$ret" != "0" ]; then - log 1 "checking SDL... not found" - - # It was forced, so it should be found. - if [ "$with_sdl" != "1" ]; then - log 1 "configure: error: sdl-config couldn't be found" - log 1 "configure: error: you supplied '$with_sdl', but it seems invalid" - exit 1 - fi - - sdl_config="" - return 0 - fi - - log 1 "checking SDL... found" + detect_pkg_config "$with_sdl" "sdl" "sdl_config" "1.2" } detect_osx_sdk() { @@ -3562,7 +3536,7 @@ showhelp() { echo " --with-allegro[=\"pkg-config allegro\"]" echo " enables Allegro video driver support" echo " --with-cocoa enables COCOA video driver (OSX ONLY)" - echo " --with-sdl[=sdl-config] enables SDL video driver support" + echo " --with-sdl[=\"pkg-config sdl\"] enables SDL video driver support" echo " --with-zlib[=zlib.a] enables zlib support" echo " --with-liblzma[=\"pkg-config liblzma\"]" echo " enables liblzma support" From 36f77b1aa719745f19b202daab4530da2b80c985 Mon Sep 17 00:00:00 2001 From: rubidium Date: Sun, 9 Aug 2015 12:42:21 +0000 Subject: [PATCH 10/29] (svn r27374) -Codechange: make zlib detection and configuration make use of pkg-config --- config.lib | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/config.lib b/config.lib index 4dbf858002..e697bd64e3 100644 --- a/config.lib +++ b/config.lib @@ -791,7 +791,7 @@ check_params() { pre_detect_with_zlib=$with_zlib detect_zlib - if [ "$with_zlib" = "0" ] || [ -z "$zlib" ]; then + if [ "$with_zlib" = "0" ] || [ -z "$zlib-config" ]; then log 1 "WARNING: zlib was not detected or disabled" log 1 "WARNING: OpenTTD doesn't require zlib, but it does mean that many features" log 1 "WARNING: (like loading most old savegames/scenarios, loading heightmaps," @@ -1657,12 +1657,13 @@ make_cflags_and_ldflags() { fi if [ "$with_zlib" != "0" ]; then - if [ "$enable_static" != "0" ] && [ "$os" != "OSX" ]; then - LIBS="$LIBS $zlib" + CFLAGS="$CFLAGS -DWITH_ZLIB" + CFLAGS="$CFLAGS `$zlib_config --cflags | tr '\n\r' ' '`" + if [ "$enable_static" != "0" ]; then + LIBS="$LIBS `$zlib_config --libs --static | tr '\n\r' ' '`" else - LIBS="$LIBS -lz" + LIBS="$LIBS `$zlib_config --libs | tr '\n\r' ' '`" fi - CFLAGS="$CFLAGS -DWITH_ZLIB" fi if [ -n "$lzma_config" ]; then @@ -2660,7 +2661,7 @@ detect_library() { } detect_zlib() { - detect_library "$with_zlib" "zlib" "libz.a" "" "zlib.h" + detect_pkg_config "$with_zlib" "zlib" "zlib_config" "1.2" } detect_lzo2() { @@ -3537,7 +3538,8 @@ showhelp() { echo " enables Allegro video driver support" echo " --with-cocoa enables COCOA video driver (OSX ONLY)" echo " --with-sdl[=\"pkg-config sdl\"] enables SDL video driver support" - echo " --with-zlib[=zlib.a] enables zlib support" + echo " --with-zlib[=\"pkg-config zlib\"]" + echo " enables zlib support" echo " --with-liblzma[=\"pkg-config liblzma\"]" echo " enables liblzma support" echo " --with-liblzo2[=liblzo2.a] enables liblzo2 support" From 2011c24502bdefa3a349a08543354e7020f30ecf Mon Sep 17 00:00:00 2001 From: rubidium Date: Sun, 9 Aug 2015 12:42:52 +0000 Subject: [PATCH 11/29] (svn r27375) -Fix-ish: update help parameter for png configuration (it has used pkg-config for a long time) --- config.lib | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/config.lib b/config.lib index e697bd64e3..b0cd4c6df1 100644 --- a/config.lib +++ b/config.lib @@ -3543,7 +3543,8 @@ showhelp() { echo " --with-liblzma[=\"pkg-config liblzma\"]" echo " enables liblzma support" echo " --with-liblzo2[=liblzo2.a] enables liblzo2 support" - echo " --with-png[=libpng-config] enables libpng support" + echo " --with-png[=\"pkg-config libpng\"]" + echo " enables libpng support" echo " --with-freetype[=\"pkg-config freetype2\"]" echo " enables libfreetype support" echo " --with-fontconfig[=\"pkg-config fontconfig\"]" From cc5b8ea6cb679e8c9a63f55d2556820b773d604d Mon Sep 17 00:00:00 2001 From: rubidium Date: Sun, 9 Aug 2015 12:43:52 +0000 Subject: [PATCH 12/29] (svn r27376) -Codechange: let libtimidity detection and configuration make use of pkg-config --- config.lib | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/config.lib b/config.lib index b0cd4c6df1..1387d45631 100644 --- a/config.lib +++ b/config.lib @@ -1760,13 +1760,15 @@ make_cflags_and_ldflags() { fi fi - if [ -n "$libtimidity" ]; then + if [ -n "$libtimidity_config" ]; then + CFLAGS="$CFLAGS -DLIBTIMIDITY" + CFLAGS="$CFLAGS `$libtimidity_config --cflags | tr '\n\r' ' '`" + if [ "$enable_static" != "0" ]; then - LIBS="$LIBS $libtimidity" + LIBS="$LIBS `$libtimidity_config --libs --static | tr '\n\r' ' '`" else - LIBS="$LIBS -ltimidity" + LIBS="$LIBS `$libtimidity_config --libs | tr '\n\r' ' '`" fi - CFLAGS="$CFLAGS -DLIBTIMIDITY" fi if [ "$with_iconv" != "0" ]; then @@ -2669,7 +2671,7 @@ detect_lzo2() { } detect_libtimidity() { - detect_library "$with_libtimidity" "libtimidity" "libtimidity.a" "" "timidity.h" + detect_pkg_config "$with_libtimidity" "libtimidity" "libtimidity_config" "0.1" "1" } detect_pkg_config() { @@ -3533,7 +3535,8 @@ showhelp() { echo " --with-midi=midi define which midi-player to use" echo " --with-midi-arg=arg define which args to use for the" echo " midi-player" - echo " --with-libtimidity enables libtimidity support" + echo " --with-libtimidity[=\"pkg-config libtimidity\"]" + echo " enables libtimidity support" echo " --with-allegro[=\"pkg-config allegro\"]" echo " enables Allegro video driver support" echo " --with-cocoa enables COCOA video driver (OSX ONLY)" From eb4b6a08d011cddb9a6f25e4c21af2228691167d Mon Sep 17 00:00:00 2001 From: rubidium Date: Sun, 9 Aug 2015 13:54:17 +0000 Subject: [PATCH 13/29] (svn r27377) -Codechange: use the pkg-config files of ICU as well. Since they are split into separate libraries it becomes possible to split RTL support for natural sorting, although the effect will be minimal --- config.lib | 107 ++++++++++++++++++++----------------------------- src/string.cpp | 15 +------ 2 files changed, 45 insertions(+), 77 deletions(-) diff --git a/config.lib b/config.lib index 1387d45631..07985a4f83 100644 --- a/config.lib +++ b/config.lib @@ -85,7 +85,8 @@ set_default() { with_libtimidity="1" with_freetype="1" with_fontconfig="1" - with_icu="1" + with_icu_layout="1" + with_icu_sort="1" static_icu="0" with_psp_config="1" with_threads="1" @@ -161,7 +162,8 @@ set_default() { with_libtimidity with_freetype with_fontconfig - with_icu + with_icu_layout + with_icu_sort static_icu with_psp_config with_threads @@ -387,12 +389,18 @@ detect_params() { --without-libfontconfig) with_fontconfig="0";; --with-libfontconfig=*) with_fontconfig="$optarg";; - --with-icu) with_icu="2";; - --without-icu) with_icu="0";; - --with-icu=*) with_icu="$optarg";; - --with-libicu) with_icu="2";; - --without-libicu) with_icu="0";; - --with-libicu=*) with_icu="$optarg";; + --with-icu) with_icu_layout="2";with_icu_sort="2";; + --without-icu) with_icu_layout="0";with_icu_sort="0";; + --with-icu=*) with_icu_layout="$optarg";with_icu_sort="$optarg";; + --with-libicu) with_icu_layout="2";with_icu_sort="2";; + --without-libicu) with_icu_layout="0";with_icu_sort="0";; + --with-libicu=*) with_icu_layout="$optarg";with_icu_sort="$optarg";; + --with-icu-layout) with_icu_layout="2";; + --without-icu-layout) with_icu_layout="0";; + --with-icu-layout=*) with_icu_layout="$optarg";; + --with-icu-sort) with_icu_sort="2";; + --without-icu-sort) with_icu_sort="0";; + --with-icu-sort=*) with_icu_sort="$optarg";; --static-icu) static_icu="1";; --static-icu=*) static_icu="$optarg";; --static-libicu) static_icu="1";; @@ -842,7 +850,8 @@ check_params() { detect_png detect_freetype detect_fontconfig - detect_icu + detect_icu_layout + detect_icu_sort detect_pspconfig detect_libtimidity @@ -1737,15 +1746,25 @@ make_cflags_and_ldflags() { fi fi - if [ -n "$icu_config" ]; then - CFLAGS="$CFLAGS -DWITH_ICU_LAYOUT -DWITH_ICU_SORT" - CFLAGS="$CFLAGS `$icu_config --cppflags | tr '\n\r' ' '`" + if [ -n "$icu_layout_config" ]; then + CFLAGS="$CFLAGS -DWITH_ICU_LAYOUT" + CFLAGS="$CFLAGS `$icu_layout_config --cflags | tr '\n\r' ' '`" - # Some icu-configs have the 'feature' of not adding a space where others do add the space if [ "$static_icu" != "0" ]; then - LIBS="$LIBS `$icu_config --ldflags-searchpath` `($icu_config --ldflags-libsonly; $icu_config --ldflags-layout) | tr '\n\r' ' ' | sed s/licu/lsicu/g`" + LIBS="$LIBS `$icu_layout_config --libs --static | tr '\n\r' ' ' | sed s/-licu/-lsicu/g`" else - LIBS="$LIBS `$icu_config --ldflags-searchpath` `($icu_config --ldflags-libsonly; $icu_config --ldflags-layout) | tr '\n\r' ' '`" + LIBS="$LIBS `$icu_layout_config --libs | tr '\n\r' ' '`" + fi + fi + + if [ -n "$icu_sort_config" ]; then + CFLAGS="$CFLAGS -DWITH_ICU_SORT" + CFLAGS="$CFLAGS `$icu_sort_config --cflags | tr '\n\r' ' '`" + + if [ "$static_icu" != "0" ]; then + LIBS="$LIBS `$icu_sort_config --libs --static | tr '\n\r' ' ' | sed s/-licu/-lsicu/g`" + else + LIBS="$LIBS `$icu_sort_config --libs | tr '\n\r' ' '`" fi fi @@ -2773,54 +2792,12 @@ detect_fontconfig() { detect_pkg_config "$with_fontconfig" "fontconfig" "fontconfig_config" "2.3" "1" } -detect_icu() { - # 0 means no, 1 is auto-detect, 2 is force - if [ "$with_icu" = "0" ]; then - log 1 "checking libicu... disabled" - - icu_config="" - return 0 - fi - if [ "$with_icu" = "1" ] && [ "$enable_dedicated" != "0" ]; then - log 1 "checking libicu... dedicated server, skipping" - - icu_config="" - return 0 - fi - - if [ "$with_icu" = "1" ] || [ "$with_icu" = "" ] || [ "$with_icu" = "2" ]; then - icu_config="icu-config" - else - icu_config="$with_icu" - fi - - version=`$icu_config --version 2>/dev/null` - ret=$? - check_version '3.6' "$version" - version_ok=$? - log 2 "executing $icu_config --version" - log 2 " returned $version" - log 2 " exit code $ret" - - if [ -z "$version" ] || [ "$ret" != "0" ] || [ "$version_ok" != "1" ]; then - if [ -n "$version" ] && [ "$version_ok" != "1" ]; then - log 1 "checking libicu... needs at least version 3.6.0, icu NOT enabled" - else - log 1 "checking libicu... not found" - fi - - # It was forced, so it should be found. - if [ "$with_icu" != "1" ]; then - log 1 "configure: error: icu-config couldn't be found" - log 1 "configure: error: you supplied '$with_icu', but it seems invalid" - exit 1 - fi - - icu_config="" - return 0 - fi +detect_icu_layout() { + detect_pkg_config "$with_icu_layout" "icu-lx" "icu_layout_config" "4.8" "1" +} - log 1 "checking libicu... found" +detect_icu_sort() { + detect_pkg_config "$with_icu_sort" "icu-i18n" "icu_sort_config" "4.8" "1" } detect_pspconfig() { @@ -3554,7 +3531,11 @@ showhelp() { echo " enables fontconfig support" echo " --with-xdg-basedir[=\"pkg-config libxdg-basedir\"]" echo " enables XDG base directory support" - echo " --with-icu[=icu-config] enables icu (used for right-to-left support)" + echo " --with-icu enables icu components for layout and sorting" + echo " --with-icu-layout[=\"pkg-config icu-lx\"]" + echo " enables icu components for layouting (right-to-left support)" + echo " --with-icu-sort[=\"pkg-config icu-i18n\"]" + echo " enables icu components for locale specific string sorting" echo " --static-icu try to link statically (libsicu instead of" echo " libicu; can fail as the new name is guessed)" echo " --with-iconv[=iconv-path] enables iconv support" diff --git a/src/string.cpp b/src/string.cpp index 377fb7f98d..fd422ec632 100644 --- a/src/string.cpp +++ b/src/string.cpp @@ -575,20 +575,7 @@ int strnatcmp(const char *s1, const char *s2, bool ignore_garbage_at_front) #ifdef WITH_ICU_SORT if (_current_collator != NULL) { UErrorCode status = U_ZERO_ERROR; - int result; - - /* We want to use the new faster method for ICU 4.2 and higher. */ -#if U_ICU_VERSION_MAJOR_NUM > 4 || (U_ICU_VERSION_MAJOR_NUM == 4 && U_ICU_VERSION_MINOR_NUM >= 2) - /* The StringPiece parameter gets implicitly constructed from the char *. */ - result = _current_collator->compareUTF8(s1, s2, status); -#else /* The following for 4.0 and lower. */ - UChar buffer1[DRAW_STRING_BUFFER]; - u_strFromUTF8Lenient(buffer1, lengthof(buffer1), NULL, s1, -1, &status); - UChar buffer2[DRAW_STRING_BUFFER]; - u_strFromUTF8Lenient(buffer2, lengthof(buffer2), NULL, s2, -1, &status); - - result = _current_collator->compare(buffer1, buffer2, status); -#endif /* ICU version check. */ + int result = _current_collator->compareUTF8(s1, s2, status); if (U_SUCCESS(status)) return result; } From 117599ec7f80b0628223177663635b55531f2cc3 Mon Sep 17 00:00:00 2001 From: Jonathan G Rennison Date: Sun, 9 Aug 2015 23:39:55 +0100 Subject: [PATCH 14/29] Order occupancy: Add column to orders GUI to show occupancy running average. This is an exponentially weighted moving average of occupancies updated when any vehicle in the shared order set leaves the station of that order. The weighting factor is an adv setting. --- src/lang/english.txt | 8 +++++ src/order_base.h | 14 +++++++++ src/order_cmd.cpp | 1 + src/order_gui.cpp | 62 +++++++++++++++++++++++++++++++++++++- src/saveload/order_sl.cpp | 1 + src/saveload/saveload.cpp | 2 +- src/settings_gui.cpp | 1 + src/settings_type.h | 1 + src/table/settings.ini | 14 +++++++++ src/vehicle.cpp | 22 ++++++++++++++ src/widgets/order_widget.h | 3 ++ 11 files changed, 127 insertions(+), 2 deletions(-) diff --git a/src/lang/english.txt b/src/lang/english.txt index ad29b3d596..9beedeb86e 100644 --- a/src/lang/english.txt +++ b/src/lang/english.txt @@ -1703,6 +1703,9 @@ STR_CONFIG_SETTING_REVERSE_AT_SIGNALS_HELPTEXT :Allow trains to STR_CONFIG_SETTING_QUERY_CAPTION :{WHITE}Change setting value +STR_CONFIG_OCCUPANCY_SMOOTHNESS :Smoothness of order occupancy measurement: {STRING2} +STR_CONFIG_OCCUPANCY_SMOOTHNESS_HELPTEXT :0% sets the measurement to the most recent value, 100% leaves it unchanged + # Config errors STR_CONFIG_ERROR :{WHITE}Error with the configuration file... STR_CONFIG_ERROR_ARRAY :{WHITE}... error in array '{RAW_STRING}' @@ -3819,6 +3822,11 @@ STR_ORDERS_GO_TO_TOOLTIP :{BLACK}Insert a STR_ORDERS_VEH_WITH_SHARED_ORDERS_LIST_TOOLTIP :{BLACK}Show all vehicles that share this schedule +STR_ORDERS_OCCUPANCY_BUTTON :{BLACK}% +STR_ORDERS_OCCUPANCY_BUTTON_TOOLTIP :{BLACK}Show occupancy running averages +STR_ORDERS_OCCUPANCY_LIST_TOOLTIP :{BLACK}Order occupancy - this shows runnings averages of recent occupancy levels when leaving a station, for all vehicles sharing these orders +STR_ORDERS_OCCUPANCY_PERCENT :{NUM}% + # String parts to build the order string STR_ORDER_GO_TO_WAYPOINT :Go via {WAYPOINT} STR_ORDER_GO_NON_STOP_TO_WAYPOINT :Go non-stop via {WAYPOINT} diff --git a/src/order_base.h b/src/order_base.h index a67cf69bb4..506eff0497 100644 --- a/src/order_base.h +++ b/src/order_base.h @@ -43,6 +43,8 @@ private: CargoID refit_cargo; ///< Refit CargoID + uint8 occupancy; ///< Estimate of vehicle occupancy on departure, for the current order, 0 indicates invalid, 1 - 101 indicate 0 - 100% + uint16 wait_time; ///< How long in ticks to wait at the destination. uint16 travel_time; ///< How long in ticks the journey to this destination should take. uint16 max_speed; ///< How fast the vehicle may go on the way to the destination. @@ -217,6 +219,18 @@ public: */ inline void SetMaxSpeed(uint16 speed) { this->max_speed = speed; } + /** + * Get the occupancy value + * @return occupancy + */ + inline uint8 GetOccupancy() const { return this->occupancy; } + + /** + * Set the occupancy value + * @param occupancy The occupancy to set + */ + inline void SetOccupancy(uint8 occupancy) { this->occupancy = occupancy; } + bool ShouldStopAtStation(const Vehicle *v, StationID station) const; bool CanLoadOrUnload() const; bool CanLeaveWithCargo(bool has_cargo) const; diff --git a/src/order_cmd.cpp b/src/order_cmd.cpp index 57b29f3f53..a6ce476373 100644 --- a/src/order_cmd.cpp +++ b/src/order_cmd.cpp @@ -239,6 +239,7 @@ Order::Order(uint32 packed) this->dest = GB(packed, 16, 16); this->next = NULL; this->refit_cargo = CT_NO_REFIT; + this->occupancy = 0; this->wait_time = 0; this->travel_time = 0; this->max_speed = UINT16_MAX; diff --git a/src/order_gui.cpp b/src/order_gui.cpp index d4feae35ca..0f86f44689 100644 --- a/src/order_gui.cpp +++ b/src/order_gui.cpp @@ -770,6 +770,7 @@ public: this->CreateNestedTree(); this->vscroll = this->GetScrollbar(WID_O_SCROLLBAR); + this->GetWidget(WID_O_SEL_OCCUPANCY)->SetDisplayedPlane(SZSP_NONE); this->FinishInitNested(v->index); if (v->owner == _local_company) { this->DisableWidget(WID_O_EMPTY); @@ -798,6 +799,12 @@ public: virtual void UpdateWidgetSize(int widget, Dimension *size, const Dimension &padding, Dimension *fill, Dimension *resize) { switch (widget) { + case WID_O_OCCUPANCY_LIST: + SetDParamMaxValue(0, 100); + size->width = WD_FRAMERECT_LEFT + GetStringBoundingBox(STR_ORDERS_OCCUPANCY_PERCENT).width + 10 + WD_FRAMERECT_RIGHT; + /* FALL THROUGH */ + + case WID_O_SEL_OCCUPANCY: case WID_O_ORDER_LIST: resize->height = FONT_HEIGHT_NORMAL; size->height = 6 * resize->height + WD_FRAMERECT_TOP + WD_FRAMERECT_BOTTOM; @@ -1064,6 +1071,8 @@ public: /* Disable list of vehicles with the same shared orders if there is no list */ this->SetWidgetDisabledState(WID_O_SHARED_ORDER_LIST, !shared_orders); + this->GetWidget(WID_O_SEL_OCCUPANCY)->SetDisplayedPlane(IsWidgetLowered(WID_O_OCCUPANCY_TOGGLE) ? 0 : SZSP_NONE); + this->SetDirty(); } @@ -1079,8 +1088,19 @@ public: virtual void DrawWidget(const Rect &r, int widget) const { - if (widget != WID_O_ORDER_LIST) return; + switch (widget) { + case WID_O_ORDER_LIST: + DrawOrderListWidget(r); + break; + + case WID_O_OCCUPANCY_LIST: + DrawOccupancyListWidget(r); + break; + } + } + void DrawOrderListWidget(const Rect &r) const + { bool rtl = _current_text_dir == TD_RTL; SetDParamMaxValue(0, this->vehicle->GetNumOrders(), 2); int index_column_width = GetStringBoundingBox(STR_ORDER_INDEX).width + 2 * GetSpriteSize(rtl ? SPR_ARROW_RIGHT : SPR_ARROW_LEFT).width + 3; @@ -1135,6 +1155,30 @@ public: } } + void DrawOccupancyListWidget(const Rect &r) const + { + int y = r.top + WD_FRAMERECT_TOP; + int line_height = this->GetWidget(WID_O_ORDER_LIST)->resize_y; + + int i = this->vscroll->GetPosition(); + const Order *order = this->vehicle->GetOrder(i); + /* Draw the orders. */ + while (order != NULL) { + /* Don't draw anything if it extends past the end of the window. */ + if (!this->vscroll->IsVisible(i)) break; + + uint8 occupancy = order->GetOccupancy(); + if (occupancy > 0) { + SetDParam(0, occupancy - 1); + DrawString(r.left + WD_FRAMETEXT_LEFT, r.right - WD_FRAMETEXT_RIGHT, y, STR_ORDERS_OCCUPANCY_PERCENT, (i == this->selected_order) ? TC_WHITE : TC_BLACK); + } + y += line_height; + + i++; + order = order->next; + } + } + virtual void SetStringParameters(int widget) const { switch (widget) { @@ -1318,6 +1362,12 @@ public: case WID_O_SHARED_ORDER_LIST: ShowVehicleListWindow(this->vehicle); break; + + case WID_O_OCCUPANCY_TOGGLE: + ToggleWidgetLoweredState(WID_O_OCCUPANCY_TOGGLE); + this->UpdateButtonState(); + this->ReInit(); + break; } } @@ -1541,6 +1591,10 @@ static const NWidgetPart _nested_orders_train_widgets[] = { EndContainer(), NWidget(NWID_HORIZONTAL), NWidget(WWT_PANEL, COLOUR_GREY, WID_O_ORDER_LIST), SetMinimalSize(372, 62), SetDataTip(0x0, STR_ORDERS_LIST_TOOLTIP), SetResize(1, 1), SetScrollbar(WID_O_SCROLLBAR), EndContainer(), + NWidget(NWID_SELECTION, INVALID_COLOUR, WID_O_SEL_OCCUPANCY), + NWidget(WWT_PANEL, COLOUR_GREY, WID_O_OCCUPANCY_LIST), SetMinimalSize(50, 0), SetFill(0, 1), SetDataTip(STR_NULL, STR_ORDERS_OCCUPANCY_LIST_TOOLTIP), + SetScrollbar(WID_O_SCROLLBAR), EndContainer(), + EndContainer(), NWidget(NWID_VSCROLLBAR, COLOUR_GREY, WID_O_SCROLLBAR), EndContainer(), @@ -1578,6 +1632,7 @@ static const NWidgetPart _nested_orders_train_widgets[] = { SetDataTip(STR_BLACK_COMMA, STR_ORDER_CONDITIONAL_VALUE_TOOLTIP), SetResize(1, 0), EndContainer(), EndContainer(), + NWidget(WWT_TEXTBTN, COLOUR_GREY, WID_O_OCCUPANCY_TOGGLE), SetMinimalSize(12, 12), SetDataTip(STR_ORDERS_OCCUPANCY_BUTTON, STR_ORDERS_OCCUPANCY_BUTTON_TOOLTIP), NWidget(WWT_PUSHIMGBTN, COLOUR_GREY, WID_O_SHARED_ORDER_LIST), SetMinimalSize(12, 12), SetDataTip(SPR_SHARED_ORDERS_ICON, STR_ORDERS_VEH_WITH_SHARED_ORDERS_LIST_TOOLTIP), EndContainer(), @@ -1619,6 +1674,10 @@ static const NWidgetPart _nested_orders_widgets[] = { EndContainer(), NWidget(NWID_HORIZONTAL), NWidget(WWT_PANEL, COLOUR_GREY, WID_O_ORDER_LIST), SetMinimalSize(372, 62), SetDataTip(0x0, STR_ORDERS_LIST_TOOLTIP), SetResize(1, 1), SetScrollbar(WID_O_SCROLLBAR), EndContainer(), + NWidget(NWID_SELECTION, INVALID_COLOUR, WID_O_SEL_OCCUPANCY), + NWidget(WWT_PANEL, COLOUR_GREY, WID_O_OCCUPANCY_LIST), SetMinimalSize(50, 0), SetFill(0, 1), SetDataTip(STR_NULL, STR_ORDERS_OCCUPANCY_LIST_TOOLTIP), + SetScrollbar(WID_O_SCROLLBAR), EndContainer(), + EndContainer(), NWidget(NWID_VSCROLLBAR, COLOUR_GREY, WID_O_SCROLLBAR), EndContainer(), @@ -1653,6 +1712,7 @@ static const NWidgetPart _nested_orders_widgets[] = { EndContainer(), EndContainer(), + NWidget(WWT_TEXTBTN, COLOUR_GREY, WID_O_OCCUPANCY_TOGGLE), SetMinimalSize(12, 12), SetDataTip(STR_ORDERS_OCCUPANCY_BUTTON, STR_ORDERS_OCCUPANCY_BUTTON_TOOLTIP), NWidget(WWT_PUSHIMGBTN, COLOUR_GREY, WID_O_SHARED_ORDER_LIST), SetMinimalSize(12, 12), SetDataTip(SPR_SHARED_ORDERS_ICON, STR_ORDERS_VEH_WITH_SHARED_ORDERS_LIST_TOOLTIP), EndContainer(), diff --git a/src/saveload/order_sl.cpp b/src/saveload/order_sl.cpp index d55d577cb6..237a7a7ea0 100644 --- a/src/saveload/order_sl.cpp +++ b/src/saveload/order_sl.cpp @@ -110,6 +110,7 @@ const SaveLoad *GetOrderDescription() SLE_REF(Order, next, REF_ORDER), SLE_CONDVAR(Order, refit_cargo, SLE_UINT8, 36, SL_MAX_VERSION), SLE_CONDNULL(1, 36, 181), // refit_subtype + SLE_CONDVAR(Order, occupancy, SLE_UINT8, 300, SL_MAX_VERSION), SLE_CONDVAR(Order, wait_time, SLE_UINT16, 67, SL_MAX_VERSION), SLE_CONDVAR(Order, travel_time, SLE_UINT16, 67, SL_MAX_VERSION), SLE_CONDVAR(Order, max_speed, SLE_UINT16, 172, SL_MAX_VERSION), diff --git a/src/saveload/saveload.cpp b/src/saveload/saveload.cpp index bd3c83d139..d9c1dea04e 100644 --- a/src/saveload/saveload.cpp +++ b/src/saveload/saveload.cpp @@ -263,7 +263,7 @@ * 193 26802 * 194 26881 1.5.x */ -extern const uint16 SAVEGAME_VERSION = 194; ///< Current savegame version of OpenTTD. +extern const uint16 SAVEGAME_VERSION = 300; ///< Current savegame version of OpenTTD. SavegameType _savegame_type; ///< type of savegame we are loading diff --git a/src/settings_gui.cpp b/src/settings_gui.cpp index f1af4804e4..1f7e1bb56e 100644 --- a/src/settings_gui.cpp +++ b/src/settings_gui.cpp @@ -1626,6 +1626,7 @@ static SettingsContainer &GetSettingsTree() vehicles->Add(new SettingEntry("order.no_servicing_if_no_breakdowns")); vehicles->Add(new SettingEntry("order.serviceathelipad")); + vehicles->Add(new SettingEntry("order.occupancy_smoothness")); } SettingsPage *limitations = main->Add(new SettingsPage(STR_CONFIG_SETTING_LIMITATIONS)); diff --git a/src/settings_type.h b/src/settings_type.h index 41366a7719..1b2c3c05d8 100644 --- a/src/settings_type.h +++ b/src/settings_type.h @@ -439,6 +439,7 @@ struct OrderSettings { bool selectgoods; ///< only send the goods to station if a train has been there bool no_servicing_if_no_breakdowns; ///< don't send vehicles to depot when breakdowns are disabled bool serviceathelipad; ///< service helicopters at helipads automatically (no need to send to depot) + uint8 occupancy_smoothness; ///< percentage smoothness of occupancy measurement changes }; /** Settings related to vehicles. */ diff --git a/src/table/settings.ini b/src/table/settings.ini index f314f21e92..625446dbe7 100644 --- a/src/table/settings.ini +++ b/src/table/settings.ini @@ -2145,6 +2145,20 @@ min = 0 max = 1000000 cat = SC_EXPERT +[SDT_VAR] +base = GameSettings +var = order.occupancy_smoothness +type = SLE_UINT8 +from = 300 +def = 75 +min = 0 +max = 100 +interval = 10 +str = STR_CONFIG_OCCUPANCY_SMOOTHNESS +strhelp = STR_CONFIG_OCCUPANCY_SMOOTHNESS_HELPTEXT +strval = STR_CONFIG_SETTING_PERCENTAGE +cat = SC_EXPERT + ## [SDT_VAR] base = GameSettings diff --git a/src/vehicle.cpp b/src/vehicle.cpp index 46f98fe63b..5f079afb88 100644 --- a/src/vehicle.cpp +++ b/src/vehicle.cpp @@ -2115,6 +2115,28 @@ void Vehicle::LeaveStation() SetBit(Train::From(this)->flags, VRF_LEAVING_STATION); } + if (this->cur_real_order_index < this->GetNumOrders()) { + Order *real_current_order = this->GetOrder(this->cur_real_order_index); + uint current_occupancy = CalcPercentVehicleFilled(this, NULL); + uint old_occupancy = real_current_order->GetOccupancy(); + uint new_occupancy; + if (old_occupancy == 0) { + new_occupancy = current_occupancy; + } else { + // Exponential weighted moving average using occupancy_smoothness + new_occupancy = (old_occupancy - 1) * _settings_game.order.occupancy_smoothness; + new_occupancy += current_occupancy * (100 - _settings_game.order.occupancy_smoothness); + new_occupancy += 50; // round to nearest integer percent, rather than just floor + new_occupancy /= 100; + } + if (new_occupancy + 1 != old_occupancy) { + real_current_order->SetOccupancy(static_cast(new_occupancy + 1)); + for (const Vehicle *v = this->FirstShared(); v != NULL; v = v->NextShared()) { + SetWindowDirty(WC_VEHICLE_ORDERS, v->index); + } + } + } + this->MarkDirty(); } diff --git a/src/widgets/order_widget.h b/src/widgets/order_widget.h index 825f791ea8..aaf86a0ea9 100644 --- a/src/widgets/order_widget.h +++ b/src/widgets/order_widget.h @@ -39,6 +39,9 @@ enum OrderWidgets { WID_O_SEL_TOP_ROW, ///< #NWID_SELECTION widget for the top row of the 'your non-trains' order window. WID_O_SEL_BOTTOM_MIDDLE, ///< #NWID_SELECTION widget for the middle part of the bottom row of the 'your train' order window. WID_O_SHARED_ORDER_LIST, ///< Open list of shared vehicles. + WID_O_SEL_OCCUPANCY, ///< #NWID_SELECTION widget for the occupancy list panel. + WID_O_OCCUPANCY_LIST, ///< Occupancy list panel. + WID_O_OCCUPANCY_TOGGLE, ///< Toggle display of occupancy measures. }; #endif /* WIDGETS_ORDER_WIDGET_H */ From fdce64ddaef4e2347d55b0cd3a540d87176588bc Mon Sep 17 00:00:00 2001 From: Jonathan G Rennison Date: Sun, 9 Aug 2015 23:43:55 +0100 Subject: [PATCH 15/29] Save/load changes for order occupancy --- src/saveload/extended_ver_sl.cpp | 1 + src/saveload/extended_ver_sl.h | 1 + src/saveload/order_sl.cpp | 2 +- src/table/settings.ini | 3 ++- 4 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/saveload/extended_ver_sl.cpp b/src/saveload/extended_ver_sl.cpp index be40cad17b..a6dd7f0340 100644 --- a/src/saveload/extended_ver_sl.cpp +++ b/src/saveload/extended_ver_sl.cpp @@ -45,6 +45,7 @@ std::vector _sl_xv_discardable_chunk_ids; ///< list of chunks static const uint32 _sl_xv_slxi_chunk_version = 0; ///< current version os SLXI chunk const SlxiSubChunkInfo _sl_xv_sub_chunk_infos[] = { + { XSLFI_ORDER_OCCUPANCY, XSCF_NULL, 1, 1, "order_occupancy", NULL, NULL, NULL }, { XSLFI_NULL, XSCF_NULL, 0, 0, NULL, NULL, NULL, NULL },// This is the end marker }; diff --git a/src/saveload/extended_ver_sl.h b/src/saveload/extended_ver_sl.h index 39a03478c2..031b8d706e 100644 --- a/src/saveload/extended_ver_sl.h +++ b/src/saveload/extended_ver_sl.h @@ -21,6 +21,7 @@ */ enum SlXvFeatureIndex { XSLFI_NULL = 0, ///< Unused value, to indicate that no extended feature test is in use + XSLFI_ORDER_OCCUPANCY, ///< Running average of order occupancy XSLFI_SIZE, ///< Total count of features, including null feature }; diff --git a/src/saveload/order_sl.cpp b/src/saveload/order_sl.cpp index 237a7a7ea0..f3ddcb31af 100644 --- a/src/saveload/order_sl.cpp +++ b/src/saveload/order_sl.cpp @@ -110,7 +110,7 @@ const SaveLoad *GetOrderDescription() SLE_REF(Order, next, REF_ORDER), SLE_CONDVAR(Order, refit_cargo, SLE_UINT8, 36, SL_MAX_VERSION), SLE_CONDNULL(1, 36, 181), // refit_subtype - SLE_CONDVAR(Order, occupancy, SLE_UINT8, 300, SL_MAX_VERSION), + SLE_CONDVAR_X(Order, occupancy, SLE_UINT8, 0, SL_MAX_VERSION, SlXvFeatureTest(XSLFTO_AND, XSLFI_ORDER_OCCUPANCY)), SLE_CONDVAR(Order, wait_time, SLE_UINT16, 67, SL_MAX_VERSION), SLE_CONDVAR(Order, travel_time, SLE_UINT16, 67, SL_MAX_VERSION), SLE_CONDVAR(Order, max_speed, SLE_UINT16, 172, SL_MAX_VERSION), diff --git a/src/table/settings.ini b/src/table/settings.ini index c1e9e8a8ce..c71148448f 100644 --- a/src/table/settings.ini +++ b/src/table/settings.ini @@ -2151,7 +2151,6 @@ cat = SC_EXPERT base = GameSettings var = order.occupancy_smoothness type = SLE_UINT8 -from = 300 def = 75 min = 0 max = 100 @@ -2160,6 +2159,8 @@ str = STR_CONFIG_OCCUPANCY_SMOOTHNESS strhelp = STR_CONFIG_OCCUPANCY_SMOOTHNESS_HELPTEXT strval = STR_CONFIG_SETTING_PERCENTAGE cat = SC_EXPERT +extver = SlXvFeatureTest(XSLFTO_AND, XSLFI_ORDER_OCCUPANCY) +patxname = ""order_occupancy.order.occupancy_smoothness"" ## [SDT_VAR] From 15f3abf47dd9594a47b70f9b23cc116367a351f7 Mon Sep 17 00:00:00 2001 From: Jonathan G Rennison Date: Sun, 9 Aug 2015 23:58:24 +0100 Subject: [PATCH 16/29] Fix typo in save/load ext feature enum name for improved breakdown. --- src/saveload/afterload.cpp | 2 +- src/saveload/extended_ver_sl.cpp | 2 +- src/saveload/extended_ver_sl.h | 2 +- src/saveload/vehicle_sl.cpp | 4 ++-- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/saveload/afterload.cpp b/src/saveload/afterload.cpp index 57396b0a98..15e61ae5c8 100644 --- a/src/saveload/afterload.cpp +++ b/src/saveload/afterload.cpp @@ -2819,7 +2819,7 @@ bool AfterLoadGame() } /* Set some breakdown-related variables to the correct values. */ - if (SlXvIsFeatureMissing(XLSFI_IMPROVED_BREAKDOWNS)) { + if (SlXvIsFeatureMissing(XSLFI_IMPROVED_BREAKDOWNS)) { Vehicle *v; FOR_ALL_VEHICLES(v) { switch(v->type) { diff --git a/src/saveload/extended_ver_sl.cpp b/src/saveload/extended_ver_sl.cpp index 84d799836e..2d7c08c0a7 100644 --- a/src/saveload/extended_ver_sl.cpp +++ b/src/saveload/extended_ver_sl.cpp @@ -45,7 +45,7 @@ std::vector _sl_xv_discardable_chunk_ids; ///< list of chunks static const uint32 _sl_xv_slxi_chunk_version = 0; ///< current version os SLXI chunk const SlxiSubChunkInfo _sl_xv_sub_chunk_infos[] = { - { XLSFI_IMPROVED_BREAKDOWNS, XSCF_NULL, 1, 1, "improved_breakdowns", NULL, NULL, NULL }, + { XSLFI_IMPROVED_BREAKDOWNS, XSCF_NULL, 1, 1, "improved_breakdowns", NULL, NULL, NULL }, { XSLFI_NULL, XSCF_NULL, 0, 0, NULL, NULL, NULL, NULL },// This is the end marker }; diff --git a/src/saveload/extended_ver_sl.h b/src/saveload/extended_ver_sl.h index af2308ed6f..bb726e4d26 100644 --- a/src/saveload/extended_ver_sl.h +++ b/src/saveload/extended_ver_sl.h @@ -21,7 +21,7 @@ */ enum SlXvFeatureIndex { XSLFI_NULL = 0, ///< Unused value, to indicate that no extended feature test is in use - XLSFI_IMPROVED_BREAKDOWNS, ///< Improved breakdowns patch + XSLFI_IMPROVED_BREAKDOWNS, ///< Improved breakdowns patch XSLFI_SIZE, ///< Total count of features, including null feature }; diff --git a/src/saveload/vehicle_sl.cpp b/src/saveload/vehicle_sl.cpp index cc0dd2b8ab..a771598f02 100644 --- a/src/saveload/vehicle_sl.cpp +++ b/src/saveload/vehicle_sl.cpp @@ -671,8 +671,8 @@ const SaveLoad *GetVehicleDescription(VehicleType vt) SLE_VAR(Vehicle, breakdown_delay, SLE_UINT8), SLE_VAR(Vehicle, breakdowns_since_last_service, SLE_UINT8), SLE_VAR(Vehicle, breakdown_chance, SLE_UINT8), - SLE_CONDVAR_X(Vehicle, breakdown_type, SLE_UINT8, 0, SL_MAX_VERSION, SlXvFeatureTest(XSLFTO_AND, XLSFI_IMPROVED_BREAKDOWNS)), - SLE_CONDVAR_X(Vehicle, breakdown_severity, SLE_UINT8, 0, SL_MAX_VERSION, SlXvFeatureTest(XSLFTO_AND, XLSFI_IMPROVED_BREAKDOWNS)), + SLE_CONDVAR_X(Vehicle, breakdown_type, SLE_UINT8, 0, SL_MAX_VERSION, SlXvFeatureTest(XSLFTO_AND, XSLFI_IMPROVED_BREAKDOWNS)), + SLE_CONDVAR_X(Vehicle, breakdown_severity, SLE_UINT8, 0, SL_MAX_VERSION, SlXvFeatureTest(XSLFTO_AND, XSLFI_IMPROVED_BREAKDOWNS)), SLE_CONDVAR(Vehicle, build_year, SLE_FILE_U8 | SLE_VAR_I32, 0, 30), SLE_CONDVAR(Vehicle, build_year, SLE_INT32, 31, SL_MAX_VERSION), From 438d7a26ccf0f8d85829c60a58c0a008d9696b4b Mon Sep 17 00:00:00 2001 From: alberth Date: Mon, 10 Aug 2015 10:04:14 +0000 Subject: [PATCH 17/29] (svn r27378) -Codechange: Fix indentation of the table values, allow Doxygen to link to the TextColour enum. --- src/table/string_colours.h | 36 ++++++++++++++++++------------------ 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/src/table/string_colours.h b/src/table/string_colours.h index 1e3b02bd64..ae64705a57 100644 --- a/src/table/string_colours.h +++ b/src/table/string_colours.h @@ -9,23 +9,23 @@ /** @file string_colours.h The colour translation of GRF's strings. */ -/** Colour mapping for the TextColours. */ +/** Colour mapping for #TextColour. */ static const byte _string_colourmap[17] = { - 150, // TC_BLUE - 12, // TC_SILVER - 189, // TC_GOLD - 184, // TC_RED - 174, // TC_PURPLE - 30, // TC_LIGHT_BROWN - 195, // TC_ORANGE - 209, // TC_GREEN - 68, // TC_YELLOW - 95, // TC_DARK_GREEN - 79, // TC_CREAM - 116, // TC_BROWN - 15, // TC_WHITE - 152, // TC_LIGHT_BLUE - 6, // TC_GREY - 133, // TC_DARK_BLUE - 1, // TC_BLACK + 150, // TC_BLUE + 12, // TC_SILVER + 189, // TC_GOLD + 184, // TC_RED + 174, // TC_PURPLE + 30, // TC_LIGHT_BROWN + 195, // TC_ORANGE + 209, // TC_GREEN + 68, // TC_YELLOW + 95, // TC_DARK_GREEN + 79, // TC_CREAM + 116, // TC_BROWN + 15, // TC_WHITE + 152, // TC_LIGHT_BLUE + 6, // TC_GREY + 133, // TC_DARK_BLUE + 1, // TC_BLACK }; From 63aa9f4ea8931d5e5b25222d0247e4c6aa1ac1db Mon Sep 17 00:00:00 2001 From: frosch Date: Mon, 10 Aug 2015 20:04:31 +0000 Subject: [PATCH 18/29] (svn r27379) -Codechange: Do not throw in the destructors of ScriptTest/ExecMode. --- src/misc/countedobj.cpp | 7 ++++++- src/script/api/script_execmode.cpp | 6 +++++- src/script/api/script_execmode.hpp | 2 ++ src/script/api/script_testmode.cpp | 6 +++++- src/script/api/script_testmode.hpp | 2 ++ 5 files changed, 20 insertions(+), 3 deletions(-) diff --git a/src/misc/countedobj.cpp b/src/misc/countedobj.cpp index 28f614afab..837d1c1770 100644 --- a/src/misc/countedobj.cpp +++ b/src/misc/countedobj.cpp @@ -25,7 +25,12 @@ int32 SimpleCountedObject::Release() int32 res = --m_ref_cnt; assert(res >= 0); if (res == 0) { - FinalRelease(); + try { + FinalRelease(); // may throw, for example ScriptTest/ExecMode + } catch (...) { + delete this; + throw; + } delete this; } return res; diff --git a/src/script/api/script_execmode.cpp b/src/script/api/script_execmode.cpp index 4fb0cc7e29..1bbce807a4 100644 --- a/src/script/api/script_execmode.cpp +++ b/src/script/api/script_execmode.cpp @@ -30,7 +30,7 @@ ScriptExecMode::ScriptExecMode() this->SetDoCommandMode(&ScriptExecMode::ModeProc, this); } -ScriptExecMode::~ScriptExecMode() +void ScriptExecMode::FinalRelease() { if (this->GetDoCommandModeInstance() != this) { /* Ignore this error if the script already died. */ @@ -38,5 +38,9 @@ ScriptExecMode::~ScriptExecMode() throw Script_FatalError("ScriptExecMode object was removed while it was not the latest *Mode object created."); } } +} + +ScriptExecMode::~ScriptExecMode() +{ this->SetDoCommandMode(this->last_mode, this->last_instance); } diff --git a/src/script/api/script_execmode.hpp b/src/script/api/script_execmode.hpp index 6591399d3f..84eda5ce26 100644 --- a/src/script/api/script_execmode.hpp +++ b/src/script/api/script_execmode.hpp @@ -46,6 +46,8 @@ public: * in when the instance was created. */ ~ScriptExecMode(); + + virtual void FinalRelease(); }; #endif /* SCRIPT_EXECMODE_HPP */ diff --git a/src/script/api/script_testmode.cpp b/src/script/api/script_testmode.cpp index 37f296de0c..ed643c2d95 100644 --- a/src/script/api/script_testmode.cpp +++ b/src/script/api/script_testmode.cpp @@ -30,7 +30,7 @@ ScriptTestMode::ScriptTestMode() this->SetDoCommandMode(&ScriptTestMode::ModeProc, this); } -ScriptTestMode::~ScriptTestMode() +void ScriptTestMode::FinalRelease() { if (this->GetDoCommandModeInstance() != this) { /* Ignore this error if the script already died. */ @@ -38,5 +38,9 @@ ScriptTestMode::~ScriptTestMode() throw Script_FatalError("Testmode object was removed while it was not the latest *Mode object created."); } } +} + +ScriptTestMode::~ScriptTestMode() +{ this->SetDoCommandMode(this->last_mode, this->last_instance); } diff --git a/src/script/api/script_testmode.hpp b/src/script/api/script_testmode.hpp index 4ca29d5dc9..25c1ddaab0 100644 --- a/src/script/api/script_testmode.hpp +++ b/src/script/api/script_testmode.hpp @@ -48,6 +48,8 @@ public: * in when the instance was created. */ ~ScriptTestMode(); + + virtual void FinalRelease(); }; #endif /* SCRIPT_TESTMODE_HPP */ From 0cd198c798c92b8a6e7aef2466d9624b2ce92ab1 Mon Sep 17 00:00:00 2001 From: michi_cc Date: Mon, 10 Aug 2015 20:21:29 +0000 Subject: [PATCH 19/29] (svn r27380) -Fix: [Win32] Compilation with MSVC2015. --- src/music/dmusic.cpp | 1 + src/os/windows/crashlog_win.cpp | 2 ++ src/stdafx.h | 4 +++- src/strgen/strgen_base.cpp | 2 +- src/string.cpp | 2 +- 5 files changed, 8 insertions(+), 3 deletions(-) diff --git a/src/music/dmusic.cpp b/src/music/dmusic.cpp index 40ce69d1a0..de3bda843e 100644 --- a/src/music/dmusic.cpp +++ b/src/music/dmusic.cpp @@ -22,6 +22,7 @@ #include "dmusic.h" #include +#undef FACILITY_DIRECTMUSIC // Needed for newer Windows SDK version. #include #include #include diff --git a/src/os/windows/crashlog_win.cpp b/src/os/windows/crashlog_win.cpp index 6e28cdba62..1abb0e725c 100644 --- a/src/os/windows/crashlog_win.cpp +++ b/src/os/windows/crashlog_win.cpp @@ -322,7 +322,9 @@ static char *PrintModuleInfo(char *output, const char *last, HMODULE mod) } #if defined(_MSC_VER) +#pragma warning(disable:4091) #include +#pragma warning(default:4091) char *CrashLogWindows::AppendDecodedStacktrace(char *buffer, const char *last) const { diff --git a/src/stdafx.h b/src/stdafx.h index d68605c196..4616212f18 100644 --- a/src/stdafx.h +++ b/src/stdafx.h @@ -223,7 +223,9 @@ #include // alloca() #define NORETURN __declspec(noreturn) - #define inline __forceinline + #if (_MSC_VER < 1900) + #define inline __forceinline + #endif #if !defined(WINCE) #define CDECL _cdecl diff --git a/src/strgen/strgen_base.cpp b/src/strgen/strgen_base.cpp index c41f3d9b40..385ca72b2a 100644 --- a/src/strgen/strgen_base.cpp +++ b/src/strgen/strgen_base.cpp @@ -378,7 +378,7 @@ static int TranslateArgumentIdx(int arg, int offset = 0); static void EmitWordList(Buffer *buffer, const char * const *words, uint nw) { buffer->AppendByte(nw); - for (uint i = 0; i < nw; i++) buffer->AppendByte((uint)strlen(words[i]) + 1); + for (uint i = 0; i < nw; i++) buffer->AppendByte((byte)strlen(words[i]) + 1); for (uint i = 0; i < nw; i++) { for (uint j = 0; words[i][j] != '\0'; j++) buffer->AppendByte(words[i][j]); buffer->AppendByte(0); diff --git a/src/string.cpp b/src/string.cpp index fd422ec632..6306e6f75e 100644 --- a/src/string.cpp +++ b/src/string.cpp @@ -349,7 +349,7 @@ bool IsValidChar(WChar key, CharSetFilter afilter) } #ifdef WIN32 -#ifdef _MSC_VER +#if defined(_MSC_VER) && _MSC_VER < 1900 /** * Almost POSIX compliant implementation of \c vsnprintf for VC compiler. * The difference is in the value returned on output truncation. This From 44918010df8a4a0c1d79bb7a609a129086b299d6 Mon Sep 17 00:00:00 2001 From: michi_cc Date: Mon, 10 Aug 2015 20:24:13 +0000 Subject: [PATCH 20/29] (svn r27381) -Fix: Warnings due to C++11 requirements for explicit narrowing conversions in initializer lists. --- src/company_base.h | 2 +- src/core/pool_func.hpp | 2 +- src/gfx.cpp | 6 +++--- src/misc_gui.cpp | 2 +- src/newgrf_gui.cpp | 2 +- src/road_gui.cpp | 2 +- src/script/api/script_road.cpp | 4 ++-- src/signs_gui.cpp | 2 +- src/smallmap_gui.cpp | 4 ++-- src/station_gui.cpp | 4 ++-- src/strings.cpp | 22 +++++++++++----------- src/table/newgrf_debug_data.h | 2 +- src/terraform_cmd.cpp | 2 +- src/textfile_gui.cpp | 2 +- src/widget.cpp | 2 +- src/widgets/dropdown.cpp | 4 ++-- 16 files changed, 32 insertions(+), 32 deletions(-) diff --git a/src/company_base.h b/src/company_base.h index 6385d60495..0017761216 100644 --- a/src/company_base.h +++ b/src/company_base.h @@ -45,7 +45,7 @@ struct CompanyInfrastructure { } }; -typedef Pool CompanyPool; +typedef Pool CompanyPool; extern CompanyPool _company_pool; diff --git a/src/core/pool_func.hpp b/src/core/pool_func.hpp index 4648f50d18..5569addbd7 100644 --- a/src/core/pool_func.hpp +++ b/src/core/pool_func.hpp @@ -121,7 +121,7 @@ DEFINE_POOL_METHOD(inline void *)::AllocateItem(size_t size, size_t index) item = (Titem *)MallocT(size); } this->data[index] = item; - item->index = (uint)index; + item->index = (Tindex)(uint)index; return item; } diff --git a/src/gfx.cpp b/src/gfx.cpp index bc7f932441..f3a98461d6 100644 --- a/src/gfx.cpp +++ b/src/gfx.cpp @@ -186,7 +186,7 @@ static inline void GfxDoDrawLine(void *video, int x, int y, int x2, int y2, int int grade_x = x2 - x; /* Clipping rectangle. Slightly extended so we can ignore the width of the line. */ - uint extra = CeilDiv(3 * width, 4); // not less then "width * sqrt(2) / 2" + int extra = (int)CeilDiv(3 * width, 4); // not less then "width * sqrt(2) / 2" Rect clip = { -extra, -extra, screen_width - 1 + extra, screen_height - 1 + extra }; /* prevent integer overflows. */ @@ -586,7 +586,7 @@ int GetStringLineCount(StringID str, int maxw) */ Dimension GetStringMultiLineBoundingBox(StringID str, const Dimension &suggestion) { - Dimension box = {suggestion.width, GetStringHeight(str, suggestion.width)}; + Dimension box = {suggestion.width, (uint)GetStringHeight(str, suggestion.width)}; return box; } @@ -598,7 +598,7 @@ Dimension GetStringMultiLineBoundingBox(StringID str, const Dimension &suggestio */ Dimension GetStringMultiLineBoundingBox(const char *str, const Dimension &suggestion) { - Dimension box = {suggestion.width, GetStringHeight(str, suggestion.width)}; + Dimension box = {suggestion.width, (uint)GetStringHeight(str, suggestion.width)}; return box; } diff --git a/src/misc_gui.cpp b/src/misc_gui.cpp index 62da50b966..5bb8c7e319 100644 --- a/src/misc_gui.cpp +++ b/src/misc_gui.cpp @@ -825,7 +825,7 @@ Point QueryString::GetCaretPosition(const Window *w, int wid) const int delta = min(0, (right - left) - tb->pixels - 10); if (tb->caretxoffs + delta < 0) delta = -tb->caretxoffs; - Point pt = {left + WD_FRAMERECT_LEFT + tb->caretxoffs + delta, wi->pos_y + WD_FRAMERECT_TOP}; + Point pt = {left + WD_FRAMERECT_LEFT + tb->caretxoffs + delta, (int)wi->pos_y + WD_FRAMERECT_TOP}; return pt; } diff --git a/src/newgrf_gui.cpp b/src/newgrf_gui.cpp index 2945f99455..cc63f7b577 100644 --- a/src/newgrf_gui.cpp +++ b/src/newgrf_gui.cpp @@ -223,7 +223,7 @@ struct NewGRFParametersWindow : public Window { case WID_NP_DESCRIPTION: /* Minimum size of 4 lines. The 500 is the default size of the window. */ - Dimension suggestion = {500 - WD_FRAMERECT_LEFT - WD_FRAMERECT_RIGHT, FONT_HEIGHT_NORMAL * 4 + WD_TEXTPANEL_TOP + WD_TEXTPANEL_BOTTOM}; + Dimension suggestion = {500 - WD_FRAMERECT_LEFT - WD_FRAMERECT_RIGHT, (uint)FONT_HEIGHT_NORMAL * 4 + WD_TEXTPANEL_TOP + WD_TEXTPANEL_BOTTOM}; for (uint i = 0; i < this->grf_config->param_info.Length(); i++) { const GRFParameterInfo *par_info = this->grf_config->param_info[i]; if (par_info == NULL) continue; diff --git a/src/road_gui.cpp b/src/road_gui.cpp index b158482ef3..92c660e8a3 100644 --- a/src/road_gui.cpp +++ b/src/road_gui.cpp @@ -233,7 +233,7 @@ static void PlaceRoadStop(TileIndex start_tile, TileIndex end_tile, uint32 p2, u p2 |= ddir << 6; // Set the DiagDirecion into p2 bits 6 and 7. TileArea ta(start_tile, end_tile); - CommandContainer cmdcont = { ta.tile, ta.w | ta.h << 8, p2, cmd, CcRoadStop, "" }; + CommandContainer cmdcont = { ta.tile, (uint32)(ta.w | ta.h << 8), p2, cmd, CcRoadStop, "" }; ShowSelectStationIfNeeded(cmdcont, ta); } diff --git a/src/script/api/script_road.cpp b/src/script/api/script_road.cpp index 3a9a8ca3fd..3dd1453b68 100644 --- a/src/script/api/script_road.cpp +++ b/src/script/api/script_road.cpp @@ -371,8 +371,8 @@ static bool NormaliseTileOffset(int32 *tile) if (!::IsValidTile(tile) || !::IsValidTile(start) || !::IsValidTile(end)) return -1; if (::DistanceManhattan(tile, start) != 1 || ::DistanceManhattan(tile, end) != 1) return -1; - /* ROAD_NW ROAD_SW ROAD_SE ROAD_NE */ - static const TileIndex neighbours[] = {::TileDiffXY(0, -1), ::TileDiffXY(1, 0), ::TileDiffXY(0, 1), ::TileDiffXY(-1, 0)}; + /* ROAD_NW ROAD_SW ROAD_SE ROAD_NE */ + static const TileIndexDiff neighbours[] = {::TileDiffXY(0, -1), ::TileDiffXY(1, 0), ::TileDiffXY(0, 1), ::TileDiffXY(-1, 0)}; Array *existing = (Array*)alloca(sizeof(Array) + lengthof(neighbours) * sizeof(int32)); existing->size = 0; diff --git a/src/signs_gui.cpp b/src/signs_gui.cpp index a34f1db077..020ee1b6ea 100644 --- a/src/signs_gui.cpp +++ b/src/signs_gui.cpp @@ -268,7 +268,7 @@ struct SignListWindow : Window, SignList { Dimension spr_dim = GetSpriteSize(SPR_COMPANY_ICON); this->text_offset = WD_FRAMETEXT_LEFT + spr_dim.width + 2; // 2 pixels space between icon and the sign text. resize->height = max(FONT_HEIGHT_NORMAL, spr_dim.height); - Dimension d = {this->text_offset + WD_FRAMETEXT_RIGHT, WD_FRAMERECT_TOP + 5 * resize->height + WD_FRAMERECT_BOTTOM}; + Dimension d = {(uint)(this->text_offset + WD_FRAMETEXT_RIGHT), WD_FRAMERECT_TOP + 5 * resize->height + WD_FRAMERECT_BOTTOM}; *size = maxdim(*size, d); break; } diff --git a/src/smallmap_gui.cpp b/src/smallmap_gui.cpp index 80d4ae2a89..571d8d765d 100644 --- a/src/smallmap_gui.cpp +++ b/src/smallmap_gui.cpp @@ -1076,7 +1076,7 @@ void SmallMapWindow::RebuildColourIndexIfNecessary() _heightmap_schemes[n].height_colours = ReallocT(_heightmap_schemes[n].height_colours, heights); for (int z = 0; z < heights; z++) { - uint access_index = (_heightmap_schemes[n].colour_count * z) / heights; + size_t access_index = (_heightmap_schemes[n].colour_count * z) / heights; /* Choose colour by mapping the range (0..max heightlevel) on the complete colour table. */ _heightmap_schemes[n].height_colours[z] = _heightmap_schemes[n].height_colours_base[access_index]; @@ -1401,7 +1401,7 @@ int SmallMapWindow::GetPositionOnLegend(Point pt) case WID_SM_ZOOM_IN: case WID_SM_ZOOM_OUT: { const NWidgetBase *wid = this->GetWidget(WID_SM_MAP); - Point pt = {wid->current_x / 2, wid->current_y / 2}; + Point pt = { (int)wid->current_x / 2, (int)wid->current_y / 2}; this->SetZoomLevel((widget == WID_SM_ZOOM_IN) ? ZLC_ZOOM_IN : ZLC_ZOOM_OUT, &pt); if (_settings_client.sound.click_beep) SndPlayFx(SND_15_BEEP); break; diff --git a/src/station_gui.cpp b/src/station_gui.cpp index 666e66d8b5..7399fe0067 100644 --- a/src/station_gui.cpp +++ b/src/station_gui.cpp @@ -1409,7 +1409,7 @@ struct StationViewWindow : public Window { if (!this->IsShaded()) { /* Draw 'accepted cargo' or 'cargo ratings'. */ const NWidgetBase *wid = this->GetWidget(WID_SV_ACCEPT_RATING_LIST); - const Rect r = {wid->pos_x, wid->pos_y, wid->pos_x + wid->current_x - 1, wid->pos_y + wid->current_y - 1}; + const Rect r = {(int)wid->pos_x, (int)wid->pos_y, (int)(wid->pos_x + wid->current_x - 1), (int)(wid->pos_y + wid->current_y - 1)}; if (this->GetWidget(WID_SV_ACCEPTS_RATINGS)->widget_data == STR_STATION_VIEW_RATINGS_BUTTON) { int lines = this->DrawAcceptedCargo(r); if (lines > this->accepts_lines) { // Resize the widget, and perform re-initialization of the window. @@ -1437,7 +1437,7 @@ struct StationViewWindow : public Window { /* Draw waiting cargo. */ NWidgetBase *nwi = this->GetWidget(WID_SV_WAITING); - Rect waiting_rect = {nwi->pos_x, nwi->pos_y, nwi->pos_x + nwi->current_x - 1, nwi->pos_y + nwi->current_y - 1}; + Rect waiting_rect = { (int)nwi->pos_x, (int)nwi->pos_y, (int)(nwi->pos_x + nwi->current_x - 1), (int)(nwi->pos_y + nwi->current_y - 1)}; this->DrawEntries(&cargo, waiting_rect, pos, maxrows, 0); scroll_to_row = INT_MAX; } diff --git a/src/strings.cpp b/src/strings.cpp index 5d1059243c..d2ce762b70 100644 --- a/src/strings.cpp +++ b/src/strings.cpp @@ -1275,7 +1275,7 @@ static char *FormatString(char *buff, const char *str_arg, StringParameters *arg if (c == NULL) break; if (c->name != NULL) { - int64 args_array[] = {(uint64)(size_t)c->name}; + int64 args_array[] = {(int64)(size_t)c->name}; StringParameters tmp_params(args_array); buff = GetStringWithArgs(buff, STR_JUST_RAW_STRING, &tmp_params, last); } else { @@ -1301,7 +1301,7 @@ static char *FormatString(char *buff, const char *str_arg, StringParameters *arg case SCC_DEPOT_NAME: { // {DEPOT} VehicleType vt = (VehicleType)args->GetInt32(SCC_DEPOT_NAME); if (vt == VEH_AIRCRAFT) { - uint64 args_array[] = {args->GetInt32()}; + uint64 args_array[] = {(uint64)args->GetInt32()}; WChar types_array[] = {SCC_STATION_NAME}; StringParameters tmp_params(args_array, 1, types_array); buff = GetStringWithArgs(buff, STR_FORMAT_DEPOT_NAME_AIRCRAFT, &tmp_params, last); @@ -1310,7 +1310,7 @@ static char *FormatString(char *buff, const char *str_arg, StringParameters *arg const Depot *d = Depot::Get(args->GetInt32()); if (d->name != NULL) { - int64 args_array[] = {(uint64)(size_t)d->name}; + int64 args_array[] = {(int64)(size_t)d->name}; StringParameters tmp_params(args_array); buff = GetStringWithArgs(buff, STR_JUST_RAW_STRING, &tmp_params, last); } else { @@ -1326,7 +1326,7 @@ static char *FormatString(char *buff, const char *str_arg, StringParameters *arg if (e == NULL) break; if (e->name != NULL && e->IsEnabled()) { - int64 args_array[] = {(uint64)(size_t)e->name}; + int64 args_array[] = {(int64)(size_t)e->name}; StringParameters tmp_params(args_array); buff = GetStringWithArgs(buff, STR_JUST_RAW_STRING, &tmp_params, last); } else { @@ -1341,7 +1341,7 @@ static char *FormatString(char *buff, const char *str_arg, StringParameters *arg if (g == NULL) break; if (g->name != NULL) { - int64 args_array[] = {(uint64)(size_t)g->name}; + int64 args_array[] = {(int64)(size_t)g->name}; StringParameters tmp_params(args_array); buff = GetStringWithArgs(buff, STR_JUST_RAW_STRING, &tmp_params, last); } else { @@ -1378,7 +1378,7 @@ static char *FormatString(char *buff, const char *str_arg, StringParameters *arg if (c == NULL) break; if (c->president_name != NULL) { - int64 args_array[] = {(uint64)(size_t)c->president_name}; + int64 args_array[] = {(int64)(size_t)c->president_name}; StringParameters tmp_params(args_array); buff = GetStringWithArgs(buff, STR_JUST_RAW_STRING, &tmp_params, last); } else { @@ -1403,7 +1403,7 @@ static char *FormatString(char *buff, const char *str_arg, StringParameters *arg } if (st->name != NULL) { - int64 args_array[] = {(uint64)(size_t)st->name}; + int64 args_array[] = {(int64)(size_t)st->name}; StringParameters tmp_params(args_array); buff = GetStringWithArgs(buff, STR_JUST_RAW_STRING, &tmp_params, last); } else { @@ -1432,7 +1432,7 @@ static char *FormatString(char *buff, const char *str_arg, StringParameters *arg if (t == NULL) break; if (t->name != NULL) { - int64 args_array[] = {(uint64)(size_t)t->name}; + int64 args_array[] = {(int64)(size_t)t->name}; StringParameters tmp_params(args_array); buff = GetStringWithArgs(buff, STR_JUST_RAW_STRING, &tmp_params, last); } else { @@ -1446,7 +1446,7 @@ static char *FormatString(char *buff, const char *str_arg, StringParameters *arg if (wp == NULL) break; if (wp->name != NULL) { - int64 args_array[] = {(uint64)(size_t)wp->name}; + int64 args_array[] = {(int64)(size_t)wp->name}; StringParameters tmp_params(args_array); buff = GetStringWithArgs(buff, STR_JUST_RAW_STRING, &tmp_params, last); } else { @@ -1464,7 +1464,7 @@ static char *FormatString(char *buff, const char *str_arg, StringParameters *arg if (v == NULL) break; if (v->name != NULL) { - int64 args_array[] = {(uint64)(size_t)v->name}; + int64 args_array[] = {(int64)(size_t)v->name}; StringParameters tmp_params(args_array); buff = GetStringWithArgs(buff, STR_JUST_RAW_STRING, &tmp_params, last); } else { @@ -1490,7 +1490,7 @@ static char *FormatString(char *buff, const char *str_arg, StringParameters *arg if (si == NULL) break; if (si->name != NULL) { - int64 args_array[] = {(uint64)(size_t)si->name}; + int64 args_array[] = {(int64)(size_t)si->name}; StringParameters tmp_params(args_array); buff = GetStringWithArgs(buff, STR_JUST_RAW_STRING, &tmp_params, last); } else { diff --git a/src/table/newgrf_debug_data.h b/src/table/newgrf_debug_data.h index c731409341..b7d0c92024 100644 --- a/src/table/newgrf_debug_data.h +++ b/src/table/newgrf_debug_data.h @@ -13,7 +13,7 @@ #include "../newgrf_engine.h" /* Helper for filling property tables */ -#define NIP(prop, base, variable, type, name) { name, cpp_offsetof(base, variable), cpp_sizeof(base, variable), prop, type } +#define NIP(prop, base, variable, type, name) { name, (ptrdiff_t)cpp_offsetof(base, variable), cpp_sizeof(base, variable), prop, type } #define NIP_END() { NULL, 0, 0, 0, 0 } /* Helper for filling callback tables */ diff --git a/src/terraform_cmd.cpp b/src/terraform_cmd.cpp index 68ebafab94..aad9822822 100644 --- a/src/terraform_cmd.cpp +++ b/src/terraform_cmd.cpp @@ -403,7 +403,7 @@ CommandCost CmdTerraformLand(TileIndex tile, DoCommandFlag flags, uint32 p1, uin } } - if (c != NULL) c->terraform_limit -= ts.tile_to_new_height.size() << 16; + if (c != NULL) c->terraform_limit -= (uint32)ts.tile_to_new_height.size() << 16; } return total_cost; } diff --git a/src/textfile_gui.cpp b/src/textfile_gui.cpp index 3efd98497e..b0f9b1125a 100644 --- a/src/textfile_gui.cpp +++ b/src/textfile_gui.cpp @@ -227,7 +227,7 @@ static void Gunzip(byte **bufp, size_t *sizep) memset(&z, 0, sizeof(z)); z.next_in = *bufp; - z.avail_in = *sizep; + z.avail_in = (uInt)*sizep; /* window size = 15, add 32 to enable gzip or zlib header processing */ res = inflateInit2(&z, 15 + 32); diff --git a/src/widget.cpp b/src/widget.cpp index 3b50f710d4..d59ca020e0 100644 --- a/src/widget.cpp +++ b/src/widget.cpp @@ -1545,7 +1545,7 @@ void NWidgetMatrix::SetupSmallestSize(Window *w, bool init_array) SB(nw->index, 16, 16, 0); this->head->SetupSmallestSize(w, init_array); - Dimension padding = {this->pip_pre + this->pip_post, this->pip_pre + this->pip_post}; + Dimension padding = { (uint)this->pip_pre + this->pip_post, (uint)this->pip_pre + this->pip_post}; Dimension size = {this->head->smallest_x + padding.width, this->head->smallest_y + padding.height}; Dimension fill = {0, 0}; Dimension resize = {this->pip_inter + this->head->smallest_x, this->pip_inter + this->head->smallest_y}; diff --git a/src/widgets/dropdown.cpp b/src/widgets/dropdown.cpp index aecfc6b2f0..e0ad96a87a 100644 --- a/src/widgets/dropdown.cpp +++ b/src/widgets/dropdown.cpp @@ -380,8 +380,8 @@ void ShowDropDownListAt(Window *w, const DropDownList *list, int selected, int b if (auto_width) width = max(width, max_item_width); - Point dw_pos = { w->left + (_current_text_dir == TD_RTL ? wi_rect.right + 1 - width : wi_rect.left), top}; - Dimension dw_size = {width, height}; + Point dw_pos = { w->left + (_current_text_dir == TD_RTL ? wi_rect.right + 1 - (int)width : wi_rect.left), top}; + Dimension dw_size = {width, (uint)height}; new DropdownWindow(w, list, selected, button, instant_close, dw_pos, dw_size, wi_colour, scroll); } From f4cd0198f4701ce47aee77a23ce85c81376a2a30 Mon Sep 17 00:00:00 2001 From: michi_cc Date: Mon, 10 Aug 2015 20:36:57 +0000 Subject: [PATCH 21/29] (svn r27382) -Add: [Win32] Project files for Visual Studio 2015. --- projects/generate | 15 + projects/generate.vbs | 15 + projects/generate_vs140.vcxproj | 40 + projects/langs_vs140.vcxproj | 384 +++ projects/langs_vs140.vcxproj.filters | 173 ++ projects/langs_vs140.vcxproj.filters.in | 12 + projects/langs_vs140.vcxproj.in | 61 + projects/openttd_vs140.sln | 94 + projects/openttd_vs140.vcxproj | 1311 +++++++++ projects/openttd_vs140.vcxproj.filters | 3050 ++++++++++++++++++++ projects/openttd_vs140.vcxproj.filters.in | 13 + projects/openttd_vs140.vcxproj.in | 332 +++ projects/settings_vs140.vcxproj | 54 + projects/settings_vs140.vcxproj.filters | 35 + projects/settings_vs140.vcxproj.filters.in | 15 + projects/settings_vs140.vcxproj.in | 48 + projects/settingsgen_vs140.vcxproj | 83 + projects/settingsgen_vs140.vcxproj.filters | 32 + projects/strgen_vs140.vcxproj | 95 + projects/strgen_vs140.vcxproj.filters | 35 + projects/version_vs140.vcxproj | 42 + 21 files changed, 5939 insertions(+) create mode 100644 projects/generate_vs140.vcxproj create mode 100644 projects/langs_vs140.vcxproj create mode 100644 projects/langs_vs140.vcxproj.filters create mode 100644 projects/langs_vs140.vcxproj.filters.in create mode 100644 projects/langs_vs140.vcxproj.in create mode 100644 projects/openttd_vs140.sln create mode 100644 projects/openttd_vs140.vcxproj create mode 100644 projects/openttd_vs140.vcxproj.filters create mode 100644 projects/openttd_vs140.vcxproj.filters.in create mode 100644 projects/openttd_vs140.vcxproj.in create mode 100644 projects/settings_vs140.vcxproj create mode 100644 projects/settings_vs140.vcxproj.filters create mode 100644 projects/settings_vs140.vcxproj.filters.in create mode 100644 projects/settings_vs140.vcxproj.in create mode 100644 projects/settingsgen_vs140.vcxproj create mode 100644 projects/settingsgen_vs140.vcxproj.filters create mode 100644 projects/strgen_vs140.vcxproj create mode 100644 projects/strgen_vs140.vcxproj.filters create mode 100644 projects/version_vs140.vcxproj diff --git a/projects/generate b/projects/generate index 42b684d2af..bd177bf71b 100755 --- a/projects/generate +++ b/projects/generate @@ -22,6 +22,15 @@ then exit 1 fi +# openttd_vs140.sln is for MSVC 2015 +# openttd_vs140.vcxproj is for MSVC 2015 +# openttd_vs140.vcxproj.filters is for MSVC 2015 +# langs_vs140.vcxproj is for MSVC 2015 +# strgen_vs140.vcxproj is for MSVC 2015 +# strgen_vs140.vcxproj.filters is for MSVC 2015 +# generate_vs140.vcxproj is for MSVC 2015 +# version_vs140.vcxproj is for MSVC 2015 + # openttd_vs100.sln is for MSVC 2010 # openttd_vs100.vcxproj is for MSVC 2010 # openttd_vs100.vcxproj.filters is for MSVC 2010 @@ -306,11 +315,17 @@ generate "$openttd" "openttd_vs80.vcproj" generate "$openttd" "openttd_vs90.vcproj" generate "$openttdvcxproj" "openttd_vs100.vcxproj" generate "$openttdfiles" "openttd_vs100.vcxproj.filters" "$openttdfilters" +generate "$openttdvcxproj" "openttd_vs140.vcxproj" +generate "$openttdfiles" "openttd_vs140.vcxproj.filters" "$openttdfilters" generate "$lang" "langs_vs80.vcproj" generate "$lang" "langs_vs90.vcproj" generate "$langvcxproj" "langs_vs100.vcxproj" generate "$langfiles" "langs_vs100.vcxproj.filters" +generate "$langvcxproj" "langs_vs140.vcxproj" +generate "$langfiles" "langs_vs140.vcxproj.filters" generate "$settings" "settings_vs80.vcproj" "$settingscommand" generate "$settings" "settings_vs90.vcproj" "$settingscommand" generate "$settingsvcxproj" "settings_vs100.vcxproj" "$settingscommand" generate "$settingsfiles" "settings_vs100.vcxproj.filters" +generate "$settingsvcxproj" "settings_vs140.vcxproj" "$settingscommand" +generate "$settingsfiles" "settings_vs140.vcxproj.filters" diff --git a/projects/generate.vbs b/projects/generate.vbs index 4e1e886873..6692b45e7f 100755 --- a/projects/generate.vbs +++ b/projects/generate.vbs @@ -10,6 +10,15 @@ Option Explicit Dim FSO Set FSO = CreateObject("Scripting.FileSystemObject") +' openttd_vs140.sln is for MSVC 2015 +' openttd_vs140.vcxproj is for MSVC 2015 +' openttd_vs140.vcxproj.filters is for MSVC 2015 +' langs_vs140.vcxproj is for MSVC 2015 +' strgen_vs140.vcxproj is for MSVC 2015 +' strgen_vs140.vcxproj.filters is for MSVC 2015 +' generate_vs140.vcxproj is for MSVC 2015 +' version_vs140.vcxproj is for MSVC 2015 + ' openttd_vs100.sln is for MSVC 2010 ' openttd_vs100.vcxproj is for MSVC 2010 ' openttd_vs100.vcxproj.filters is for MSVC 2010 @@ -369,6 +378,8 @@ generate openttd, ROOT_DIR & "/projects/openttd_vs80.vcproj", Null generate openttd, ROOT_DIR & "/projects/openttd_vs90.vcproj", Null generate openttdvcxproj, ROOT_DIR & "/projects/openttd_vs100.vcxproj", Null generate openttdfiles, ROOT_DIR & "/projects/openttd_vs100.vcxproj.filters", openttdfilters +generate openttdvcxproj, ROOT_DIR & "/projects/openttd_vs140.vcxproj", Null +generate openttdfiles, ROOT_DIR & "/projects/openttd_vs140.vcxproj.filters", openttdfilters Dim lang, langvcxproj, langfiles lang = load_lang_data(ROOT_DIR & "/src/lang", langvcxproj, langfiles) @@ -376,6 +387,8 @@ generate lang, ROOT_DIR & "/projects/langs_vs80.vcproj", Null generate lang, ROOT_DIR & "/projects/langs_vs90.vcproj", Null generate langvcxproj, ROOT_DIR & "/projects/langs_vs100.vcxproj", Null generate langfiles, ROOT_DIR & "/projects/langs_vs100.vcxproj.filters", Null +generate langvcxproj, ROOT_DIR & "/projects/langs_vs140.vcxproj", Null +generate langfiles, ROOT_DIR & "/projects/langs_vs140.vcxproj.filters", Null Dim settings, settingsvcxproj, settingscommand, settingsfiles settings = load_settings_data(ROOT_DIR & "/src/table", settingsvcxproj, settingscommand, settingsfiles) @@ -383,3 +396,5 @@ generate settings, ROOT_DIR & "/projects/settings_vs80.vcproj", settingscommand generate settings, ROOT_DIR & "/projects/settings_vs90.vcproj", settingscommand generate settingsvcxproj, ROOT_DIR & "/projects/settings_vs100.vcxproj", settingscommand generate settingsfiles, ROOT_DIR & "/projects/settings_vs100.vcxproj.filters", Null +generate settingsvcxproj, ROOT_DIR & "/projects/settings_vs140.vcxproj", settingscommand +generate settingsfiles, ROOT_DIR & "/projects/settings_vs140.vcxproj.filters", Null diff --git a/projects/generate_vs140.vcxproj b/projects/generate_vs140.vcxproj new file mode 100644 index 0000000000..67b1b7712c --- /dev/null +++ b/projects/generate_vs140.vcxproj @@ -0,0 +1,40 @@ + + + + + Debug + Win32 + + + + generate + {2F31FD79-D1AC-43C4-89F3-B0D5E4E53E34} + generate + + + + Utility + v140 + + + + + + + + + + + + + Document + Running %27generate.vbs%27 ... + cscript "$(ProjectDir)generate.vbs" + %(FullPath);%(AdditionalInputs) + $(SolutionDir)openttd_vs80.vcproj;$(SolutionDir)openttd_vs90.vcproj;$(SolutionDir)openttd_vs100.vcxproj;$(SolutionDir)openttd_vs100.vcxproj.filters;$(SolutionDir)langs_vs80.vcproj;$(SolutionDir)langs_vs90.vcproj;$(SolutionDir)langs_vs100.vcxproj;%(Outputs) + + + + + + \ No newline at end of file diff --git a/projects/langs_vs140.vcxproj b/projects/langs_vs140.vcxproj new file mode 100644 index 0000000000..0907bfa6f5 --- /dev/null +++ b/projects/langs_vs140.vcxproj @@ -0,0 +1,384 @@ + + + + + Debug + Win32 + + + + langs + {0F066B23-18DF-4284-8265-F4A5E7E3B966} + langs + MakeFileProj + + + + Utility + false + v140 + + + + + + + + + + ..\bin\lang\ + ..\objs\langs\ + + + + Generating strings.h + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\objs\langs\table + + + ./langs.tlb + + + + + + + Generating english language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\english.lng;%(Outputs) + + + Generating afrikaans language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\afrikaans.lng;%(Outputs) + + + Generating arabic_egypt language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\arabic_egypt.lng;%(Outputs) + + + Generating basque language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\basque.lng;%(Outputs) + + + Generating belarusian language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\belarusian.lng;%(Outputs) + + + Generating brazilian_portuguese language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\brazilian_portuguese.lng;%(Outputs) + + + Generating bulgarian language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\bulgarian.lng;%(Outputs) + + + Generating catalan language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\catalan.lng;%(Outputs) + + + Generating croatian language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\croatian.lng;%(Outputs) + + + Generating czech language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\czech.lng;%(Outputs) + + + Generating danish language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\danish.lng;%(Outputs) + + + Generating dutch language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\dutch.lng;%(Outputs) + + + Generating english_AU language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\english_AU.lng;%(Outputs) + + + Generating english_US language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\english_US.lng;%(Outputs) + + + Generating esperanto language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\esperanto.lng;%(Outputs) + + + Generating estonian language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\estonian.lng;%(Outputs) + + + Generating faroese language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\faroese.lng;%(Outputs) + + + Generating finnish language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\finnish.lng;%(Outputs) + + + Generating french language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\french.lng;%(Outputs) + + + Generating gaelic language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\gaelic.lng;%(Outputs) + + + Generating galician language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\galician.lng;%(Outputs) + + + Generating german language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\german.lng;%(Outputs) + + + Generating greek language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\greek.lng;%(Outputs) + + + Generating hebrew language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\hebrew.lng;%(Outputs) + + + Generating hungarian language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\hungarian.lng;%(Outputs) + + + Generating icelandic language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\icelandic.lng;%(Outputs) + + + Generating indonesian language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\indonesian.lng;%(Outputs) + + + Generating irish language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\irish.lng;%(Outputs) + + + Generating italian language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\italian.lng;%(Outputs) + + + Generating japanese language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\japanese.lng;%(Outputs) + + + Generating korean language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\korean.lng;%(Outputs) + + + Generating latin language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\latin.lng;%(Outputs) + + + Generating latvian language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\latvian.lng;%(Outputs) + + + Generating lithuanian language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\lithuanian.lng;%(Outputs) + + + Generating luxembourgish language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\luxembourgish.lng;%(Outputs) + + + Generating malay language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\malay.lng;%(Outputs) + + + Generating norwegian_bokmal language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\norwegian_bokmal.lng;%(Outputs) + + + Generating norwegian_nynorsk language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\norwegian_nynorsk.lng;%(Outputs) + + + Generating polish language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\polish.lng;%(Outputs) + + + Generating portuguese language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\portuguese.lng;%(Outputs) + + + Generating romanian language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\romanian.lng;%(Outputs) + + + Generating russian language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\russian.lng;%(Outputs) + + + Generating serbian language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\serbian.lng;%(Outputs) + + + Generating simplified_chinese language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\simplified_chinese.lng;%(Outputs) + + + Generating slovak language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\slovak.lng;%(Outputs) + + + Generating slovenian language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\slovenian.lng;%(Outputs) + + + Generating spanish language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\spanish.lng;%(Outputs) + + + Generating swedish language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\swedish.lng;%(Outputs) + + + Generating tamil language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\tamil.lng;%(Outputs) + + + Generating thai language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\thai.lng;%(Outputs) + + + Generating traditional_chinese language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\traditional_chinese.lng;%(Outputs) + + + Generating turkish language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\turkish.lng;%(Outputs) + + + Generating ukrainian language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\ukrainian.lng;%(Outputs) + + + Generating vietnamese language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\vietnamese.lng;%(Outputs) + + + Generating welsh language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\welsh.lng;%(Outputs) + + + + + {a133a442-bd0a-4ade-b117-ad7545e4bdd1} + false + + + + + + diff --git a/projects/langs_vs140.vcxproj.filters b/projects/langs_vs140.vcxproj.filters new file mode 100644 index 0000000000..fb16aa64e0 --- /dev/null +++ b/projects/langs_vs140.vcxproj.filters @@ -0,0 +1,173 @@ + + + + + {2a164580-9033-4a01-974b-b21da507efda} + + + + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + Translations + + + diff --git a/projects/langs_vs140.vcxproj.filters.in b/projects/langs_vs140.vcxproj.filters.in new file mode 100644 index 0000000000..0d60ee9595 --- /dev/null +++ b/projects/langs_vs140.vcxproj.filters.in @@ -0,0 +1,12 @@ + + + + + {2a164580-9033-4a01-974b-b21da507efda} + + + + +!!FILES!! + + diff --git a/projects/langs_vs140.vcxproj.in b/projects/langs_vs140.vcxproj.in new file mode 100644 index 0000000000..f75ef9d6b5 --- /dev/null +++ b/projects/langs_vs140.vcxproj.in @@ -0,0 +1,61 @@ + + + + + Debug + Win32 + + + + langs + {0F066B23-18DF-4284-8265-F4A5E7E3B966} + langs + MakeFileProj + + + + Utility + false + v140 + + + + + + + + + + ..\bin\lang\ + ..\objs\langs\ + + + + Generating strings.h + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\objs\langs\table + + + ./langs.tlb + + + + + + + Generating english language file + ..\objs\strgen\strgen.exe -s ..\src\lang -d ..\bin\lang "%(FullPath)" + ..\src\lang\english.txt;..\objs\strgen\strgen.exe;%(AdditionalInputs) + ..\bin\lang\english.lng;%(Outputs) + +!!FILES!! + + + + {a133a442-bd0a-4ade-b117-ad7545e4bdd1} + false + + + + + + diff --git a/projects/openttd_vs140.sln b/projects/openttd_vs140.sln new file mode 100644 index 0000000000..d256cfa495 --- /dev/null +++ b/projects/openttd_vs140.sln @@ -0,0 +1,94 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio 14 +VisualStudioVersion = 14.0.23107.0 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "openttd", "openttd_vs140.vcxproj", "{668328A0-B40E-4CDB-BD72-D0064424414A}" + ProjectSection(ProjectDependencies) = postProject + {0817F629-589E-4A3B-B81A-8647BC571E35} = {0817F629-589E-4A3B-B81A-8647BC571E35} + {E9548DE9-F089-49B7-93A6-30BE2CC311C7} = {E9548DE9-F089-49B7-93A6-30BE2CC311C7} + EndProjectSection +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "strgen", "strgen_vs140.vcxproj", "{A133A442-BD0A-4ADE-B117-AD7545E4BDD1}" +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "langs", "langs_vs140.vcxproj", "{0F066B23-18DF-4284-8265-F4A5E7E3B966}" +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "version", "version_vs140.vcxproj", "{1A2B3C5E-1C23-41A5-9C9B-ACBA2AA75FEC}" +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "generate", "generate_vs140.vcxproj", "{2F31FD79-D1AC-43C4-89F3-B0D5E4E53E34}" +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "settings", "settings_vs140.vcxproj", "{0817F629-589E-4A3B-B81A-8647BC571E35}" + ProjectSection(ProjectDependencies) = postProject + {E9548DE9-F089-49B7-93A6-30BE2CC311C7} = {E9548DE9-F089-49B7-93A6-30BE2CC311C7} + EndProjectSection +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "settingsgen", "settingsgen_vs140.vcxproj", "{E9548DE9-F089-49B7-93A6-30BE2CC311C7}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Win32 = Debug|Win32 + Debug|x64 = Debug|x64 + Release|Win32 = Release|Win32 + Release|x64 = Release|x64 + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {668328A0-B40E-4CDB-BD72-D0064424414A}.Debug|Win32.ActiveCfg = Debug|Win32 + {668328A0-B40E-4CDB-BD72-D0064424414A}.Debug|Win32.Build.0 = Debug|Win32 + {668328A0-B40E-4CDB-BD72-D0064424414A}.Debug|x64.ActiveCfg = Debug|x64 + {668328A0-B40E-4CDB-BD72-D0064424414A}.Debug|x64.Build.0 = Debug|x64 + {668328A0-B40E-4CDB-BD72-D0064424414A}.Release|Win32.ActiveCfg = Release|Win32 + {668328A0-B40E-4CDB-BD72-D0064424414A}.Release|Win32.Build.0 = Release|Win32 + {668328A0-B40E-4CDB-BD72-D0064424414A}.Release|x64.ActiveCfg = Release|x64 + {668328A0-B40E-4CDB-BD72-D0064424414A}.Release|x64.Build.0 = Release|x64 + {A133A442-BD0A-4ADE-B117-AD7545E4BDD1}.Debug|Win32.ActiveCfg = Debug|Win32 + {A133A442-BD0A-4ADE-B117-AD7545E4BDD1}.Debug|Win32.Build.0 = Debug|Win32 + {A133A442-BD0A-4ADE-B117-AD7545E4BDD1}.Debug|x64.ActiveCfg = Debug|Win32 + {A133A442-BD0A-4ADE-B117-AD7545E4BDD1}.Debug|x64.Build.0 = Debug|Win32 + {A133A442-BD0A-4ADE-B117-AD7545E4BDD1}.Release|Win32.ActiveCfg = Debug|Win32 + {A133A442-BD0A-4ADE-B117-AD7545E4BDD1}.Release|Win32.Build.0 = Debug|Win32 + {A133A442-BD0A-4ADE-B117-AD7545E4BDD1}.Release|x64.ActiveCfg = Debug|Win32 + {A133A442-BD0A-4ADE-B117-AD7545E4BDD1}.Release|x64.Build.0 = Debug|Win32 + {0F066B23-18DF-4284-8265-F4A5E7E3B966}.Debug|Win32.ActiveCfg = Debug|Win32 + {0F066B23-18DF-4284-8265-F4A5E7E3B966}.Debug|Win32.Build.0 = Debug|Win32 + {0F066B23-18DF-4284-8265-F4A5E7E3B966}.Debug|x64.ActiveCfg = Debug|Win32 + {0F066B23-18DF-4284-8265-F4A5E7E3B966}.Debug|x64.Build.0 = Debug|Win32 + {0F066B23-18DF-4284-8265-F4A5E7E3B966}.Release|Win32.ActiveCfg = Debug|Win32 + {0F066B23-18DF-4284-8265-F4A5E7E3B966}.Release|Win32.Build.0 = Debug|Win32 + {0F066B23-18DF-4284-8265-F4A5E7E3B966}.Release|x64.ActiveCfg = Debug|Win32 + {0F066B23-18DF-4284-8265-F4A5E7E3B966}.Release|x64.Build.0 = Debug|Win32 + {1A2B3C5E-1C23-41A5-9C9B-ACBA2AA75FEC}.Debug|Win32.ActiveCfg = Debug|Win32 + {1A2B3C5E-1C23-41A5-9C9B-ACBA2AA75FEC}.Debug|Win32.Build.0 = Debug|Win32 + {1A2B3C5E-1C23-41A5-9C9B-ACBA2AA75FEC}.Debug|x64.ActiveCfg = Debug|Win32 + {1A2B3C5E-1C23-41A5-9C9B-ACBA2AA75FEC}.Debug|x64.Build.0 = Debug|Win32 + {1A2B3C5E-1C23-41A5-9C9B-ACBA2AA75FEC}.Release|Win32.ActiveCfg = Debug|Win32 + {1A2B3C5E-1C23-41A5-9C9B-ACBA2AA75FEC}.Release|Win32.Build.0 = Debug|Win32 + {1A2B3C5E-1C23-41A5-9C9B-ACBA2AA75FEC}.Release|x64.ActiveCfg = Debug|Win32 + {1A2B3C5E-1C23-41A5-9C9B-ACBA2AA75FEC}.Release|x64.Build.0 = Debug|Win32 + {2F31FD79-D1AC-43C4-89F3-B0D5E4E53E34}.Debug|Win32.ActiveCfg = Debug|Win32 + {2F31FD79-D1AC-43C4-89F3-B0D5E4E53E34}.Debug|x64.ActiveCfg = Debug|Win32 + {2F31FD79-D1AC-43C4-89F3-B0D5E4E53E34}.Release|Win32.ActiveCfg = Debug|Win32 + {2F31FD79-D1AC-43C4-89F3-B0D5E4E53E34}.Release|x64.ActiveCfg = Debug|Win32 + {0817F629-589E-4A3B-B81A-8647BC571E35}.Debug|Win32.ActiveCfg = Debug|Win32 + {0817F629-589E-4A3B-B81A-8647BC571E35}.Debug|Win32.Build.0 = Debug|Win32 + {0817F629-589E-4A3B-B81A-8647BC571E35}.Debug|x64.ActiveCfg = Debug|Win32 + {0817F629-589E-4A3B-B81A-8647BC571E35}.Debug|x64.Build.0 = Debug|Win32 + {0817F629-589E-4A3B-B81A-8647BC571E35}.Release|Win32.ActiveCfg = Debug|Win32 + {0817F629-589E-4A3B-B81A-8647BC571E35}.Release|Win32.Build.0 = Debug|Win32 + {0817F629-589E-4A3B-B81A-8647BC571E35}.Release|x64.ActiveCfg = Debug|Win32 + {0817F629-589E-4A3B-B81A-8647BC571E35}.Release|x64.Build.0 = Debug|Win32 + {E9548DE9-F089-49B7-93A6-30BE2CC311C7}.Debug|Win32.ActiveCfg = Debug|Win32 + {E9548DE9-F089-49B7-93A6-30BE2CC311C7}.Debug|Win32.Build.0 = Debug|Win32 + {E9548DE9-F089-49B7-93A6-30BE2CC311C7}.Debug|x64.ActiveCfg = Debug|Win32 + {E9548DE9-F089-49B7-93A6-30BE2CC311C7}.Debug|x64.Build.0 = Debug|Win32 + {E9548DE9-F089-49B7-93A6-30BE2CC311C7}.Release|Win32.ActiveCfg = Debug|Win32 + {E9548DE9-F089-49B7-93A6-30BE2CC311C7}.Release|Win32.Build.0 = Debug|Win32 + {E9548DE9-F089-49B7-93A6-30BE2CC311C7}.Release|x64.ActiveCfg = Debug|Win32 + {E9548DE9-F089-49B7-93A6-30BE2CC311C7}.Release|x64.Build.0 = Debug|Win32 + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection + GlobalSection(DPCodeReviewSolutionGUID) = preSolution + DPCodeReviewSolutionGUID = {00000000-0000-0000-0000-000000000000} + EndGlobalSection +EndGlobal diff --git a/projects/openttd_vs140.vcxproj b/projects/openttd_vs140.vcxproj new file mode 100644 index 0000000000..88f7b44ddd --- /dev/null +++ b/projects/openttd_vs140.vcxproj @@ -0,0 +1,1311 @@ + + + + + Debug + Win32 + + + Debug + x64 + + + Release + Win32 + + + Release + x64 + + + + openttd + {668328A0-B40E-4CDB-BD72-D0064424414A} + openttd + + + + Application + false + Unicode + v140 + + + Application + false + Unicode + true + v140 + + + Application + false + Unicode + v140 + + + Application + false + Unicode + true + v140 + + + + + + + + + + + + + + + + + $(SolutionDir)..\objs\$(Platform)\$(Configuration)\ + $(SolutionDir)..\objs\$(Platform)\$(Configuration)\ + false + $(SolutionDir)..\objs\$(Platform)\$(Configuration)\ + $(SolutionDir)..\objs\$(Platform)\$(Configuration)\ + + $(SolutionDir)..\objs\$(Platform)\$(Configuration)\ + false + $(SolutionDir)..\objs\$(Platform)\$(Configuration)\ + $(SolutionDir)..\objs\$(Platform)\$(Configuration)\ + + AllRules.ruleset + + + AllRules.ruleset + + + AllRules.ruleset + + + AllRules.ruleset + + + $(SolutionDir)..\objs\$(Platform)\$(Configuration)\ + $(ProjectDir)..\bin + + + + .\Release/openttd.tlb + + + + + /J /Zc:throwingNew %(AdditionalOptions) + Full + AnySuitable + true + Size + true + ..\objs\langs;..\objs\settings;..\src\3rdparty\squirrel\include;%(AdditionalIncludeDirectories) + WIN32;NDEBUG;_CONSOLE;WIN32_ENABLE_DIRECTMUSIC_SUPPORT;WITH_SSE;WITH_ZLIB;WITH_LZO;WITH_LZMA;LZMA_API_STATIC;WITH_PNG;WITH_FREETYPE;WITH_ICU;U_STATIC_IMPLEMENTATION;ENABLE_NETWORK;WITH_PERSONAL_DIR;PERSONAL_DIR="OpenTTD";WITH_ASSERT;%(PreprocessorDefinitions) + true + Sync + MultiThreaded + 4Bytes + false + true + + + + + + + All + $(IntDir) + $(IntDir) + $(IntDir)$(TargetName).pdb + Level3 + false + true + ProgramDatabase + FastCall + Default + true + true + + + NDEBUG;%(PreprocessorDefinitions) + 0x0809 + + + winmm.lib;ws2_32.lib;imm32.lib;libpng.lib;zlibstat.lib;lzo2.lib;liblzma.lib;libfreetype2.lib;icuuc.lib;icuin.lib;icudt.lib;icule.lib;iculx.lib;%(AdditionalDependencies) + true + %(IgnoreSpecificDefaultLibraries) + true + Windows + 1048576 + 1048576 + true + false + + + MachineX86 + true + 5.01 + + + + + .\Debug/openttd.tlb + + + + + /J /Zc:throwingNew %(AdditionalOptions) + Disabled + true + ..\objs\langs;..\objs\settings;..\src\3rdparty\squirrel\include;%(AdditionalIncludeDirectories) + WIN32;_DEBUG;_CONSOLE;WIN32_ENABLE_DIRECTMUSIC_SUPPORT;WITH_SSE;WITH_ZLIB;WITH_LZO;WITH_LZMA;LZMA_API_STATIC;WITH_PNG;WITH_FREETYPE;WITH_ICU;U_STATIC_IMPLEMENTATION;ENABLE_NETWORK;WITH_PERSONAL_DIR;PERSONAL_DIR="OpenTTD";%(PreprocessorDefinitions) + EnableFastChecks + MultiThreadedDebug + + + $(IntDir) + $(IntDir) + $(IntDir)$(TargetName).pdb + Level3 + false + true + ProgramDatabase + FastCall + Default + true + true + + + _DEBUG;%(PreprocessorDefinitions) + 0x0809 + + + winmm.lib;ws2_32.lib;imm32.lib;libpng.lib;zlibstat.lib;lzo2.lib;liblzma.lib;libfreetype2.lib;icuuc.lib;icuin.lib;icudt.lib;icule.lib;iculx.lib;%(AdditionalDependencies) + true + LIBCMT.lib;%(IgnoreSpecificDefaultLibraries) + true + Windows + 1048576 + 1048576 + false + + + MachineX86 + 5.01 + + + + + X64 + .\Release/openttd.tlb + + + + + /J /Zc:throwingNew %(AdditionalOptions) + Full + AnySuitable + true + Size + true + ..\objs\langs;..\objs\settings;..\src\3rdparty\squirrel\include;%(AdditionalIncludeDirectories) + WIN32;NDEBUG;_CONSOLE;WITH_SSE;WITH_ZLIB;WITH_LZO;WITH_LZMA;LZMA_API_STATIC;WITH_PNG;WITH_FREETYPE;WITH_ICU;U_STATIC_IMPLEMENTATION;ENABLE_NETWORK;WITH_PERSONAL_DIR;PERSONAL_DIR="OpenTTD";_SQ64;WITH_ASSERT;%(PreprocessorDefinitions) + true + Sync + MultiThreaded + Default + false + true + + + + + + + All + $(IntDir) + $(IntDir) + $(IntDir)$(TargetName).pdb + Level3 + false + true + ProgramDatabase + FastCall + Default + true + true + + + NDEBUG;%(PreprocessorDefinitions) + 0x0809 + + + winmm.lib;ws2_32.lib;imm32.lib;libpng.lib;zlibstat.lib;lzo2.lib;liblzma.lib;libfreetype2.lib;icuuc.lib;icuin.lib;icudt.lib;icule.lib;iculx.lib;%(AdditionalDependencies) + true + %(IgnoreSpecificDefaultLibraries) + true + Windows + 1048576 + 1048576 + true + MachineX64 + true + 5.02 + + + + + X64 + .\Debug/openttd.tlb + + + + + /J /Zc:throwingNew %(AdditionalOptions) + Disabled + true + ..\objs\langs;..\objs\settings;..\src\3rdparty\squirrel\include;%(AdditionalIncludeDirectories) + WIN32;_DEBUG;_CONSOLE;WITH_SSE;WITH_ZLIB;WITH_LZO;WITH_LZMA;LZMA_API_STATIC;WITH_PNG;WITH_FREETYPE;WITH_ICU;U_STATIC_IMPLEMENTATION;ENABLE_NETWORK;WITH_PERSONAL_DIR;PERSONAL_DIR="OpenTTD";_SQ64;%(PreprocessorDefinitions) + EnableFastChecks + MultiThreadedDebug + + + + + + + $(IntDir) + $(IntDir) + $(IntDir)$(TargetName).pdb + Level3 + false + true + ProgramDatabase + Cdecl + Default + true + true + + + _DEBUG;%(PreprocessorDefinitions) + 0x0809 + + + winmm.lib;ws2_32.lib;imm32.lib;libpng.lib;zlibstat.lib;lzo2.lib;liblzma.lib;libfreetype2.lib;icuuc.lib;icuin.lib;icudt.lib;icule.lib;iculx.lib;%(AdditionalDependencies) + true + LIBCMT.lib;%(IgnoreSpecificDefaultLibraries) + true + Windows + 1048576 + 1048576 + MachineX64 + 5.02 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + {0f066b23-18df-4284-8265-f4a5e7e3b966} + false + + + {a133a442-bd0a-4ade-b117-ad7545e4bdd1} + false + + + {1a2b3c5e-1c23-41a5-9c9b-acba2aa75fec} + false + + + + diff --git a/projects/openttd_vs140.vcxproj.filters b/projects/openttd_vs140.vcxproj.filters new file mode 100644 index 0000000000..06800ffdaf --- /dev/null +++ b/projects/openttd_vs140.vcxproj.filters @@ -0,0 +1,3050 @@ + + + + + {c76ff9f1-1e62-46d8-8d55-000000000000} + + + {c76ff9f1-1e62-46d8-8d55-000000000001} + + + {c76ff9f1-1e62-46d8-8d55-000000000002} + + + {c76ff9f1-1e62-46d8-8d55-000000000003} + + + {c76ff9f1-1e62-46d8-8d55-000000000004} + + + {c76ff9f1-1e62-46d8-8d55-000000000005} + + + {c76ff9f1-1e62-46d8-8d55-000000000006} + + + {c76ff9f1-1e62-46d8-8d55-000000000007} + + + {c76ff9f1-1e62-46d8-8d55-000000000008} + + + {c76ff9f1-1e62-46d8-8d55-000000000009} + + + {c76ff9f1-1e62-46d8-8d55-000000000010} + + + {c76ff9f1-1e62-46d8-8d55-000000000011} + + + {c76ff9f1-1e62-46d8-8d55-000000000012} + + + {c76ff9f1-1e62-46d8-8d55-000000000013} + + + {c76ff9f1-1e62-46d8-8d55-000000000014} + + + {c76ff9f1-1e62-46d8-8d55-000000000015} + + + {c76ff9f1-1e62-46d8-8d55-000000000016} + + + {c76ff9f1-1e62-46d8-8d55-000000000017} + + + {c76ff9f1-1e62-46d8-8d55-000000000018} + + + {c76ff9f1-1e62-46d8-8d55-000000000019} + + + {c76ff9f1-1e62-46d8-8d55-000000000020} + + + {c76ff9f1-1e62-46d8-8d55-000000000021} + + + {c76ff9f1-1e62-46d8-8d55-000000000022} + + + {c76ff9f1-1e62-46d8-8d55-000000000023} + + + {c76ff9f1-1e62-46d8-8d55-000000000024} + + + {c76ff9f1-1e62-46d8-8d55-000000000025} + + + {c76ff9f1-1e62-46d8-8d55-000000000026} + + + {c76ff9f1-1e62-46d8-8d55-000000000027} + + + {c76ff9f1-1e62-46d8-8d55-000000000028} + + + {c76ff9f1-1e62-46d8-8d55-000000000029} + + + {c76ff9f1-1e62-46d8-8d55-000000000030} + + + {c76ff9f1-1e62-46d8-8d55-000000000031} + + + {c76ff9f1-1e62-46d8-8d55-000000000032} + + + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Header Files + + + Core Source Code + + + Core Source Code + + + Core Source Code + + + Core Source Code + + + Core Source Code + + + Core Source Code + + + Core Source Code + + + Core Source Code + + + Core Source Code + + + Core Source Code + + + Core Source Code + + + Core Source Code + + + Core Source Code + + + Core Source Code + + + Core Source Code + + + Core Source Code + + + Core Source Code + + + Core Source Code + + + Core Source Code + + + Core Source Code + + + Core Source Code + + + Core Source Code + + + Core Source Code + + + Core Source Code + + + Core Source Code + + + Core Source Code + + + Core Source Code + + + Core Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + GUI Source Code + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Widgets + + + Command handlers + + + Command handlers + + + Command handlers + + + Command handlers + + + Command handlers + + + Command handlers + + + Command handlers + + + Command handlers + + + Command handlers + + + Command handlers + + + Command handlers + + + Command handlers + + + Command handlers + + + Command handlers + + + Command handlers + + + Command handlers + + + Command handlers + + + Command handlers + + + Command handlers + + + Command handlers + + + Command handlers + + + Command handlers + + + Command handlers + + + Command handlers + + + Command handlers + + + Command handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Save/Load handlers + + + Tables + + + Tables + + + Tables + + + Tables + + + Tables + + + Tables + + + Tables + + + Tables + + + Tables + + + Tables + + + Tables + + + Tables + + + Tables + + + Tables + + + Tables + + + Tables + + + Tables + + + Tables + + + Tables + + + Tables + + + Tables + + + Tables + + + Tables + + + Tables + + + Tables + + + Tables + + + Tables + + + Tables + + + Tables + + + Tables + + + Tables + + + Tables + + + Tables + + + Tables + + + Tables + + + Tables + + + Tables + + + Tables + + + MD5 + + + MD5 + + + Script + + + Script + + + Script + + + Script + + + Script + + + Script + + + Script + + + Script + + + Script + + + Script + + + Script + + + Script + + + Script + + + Script + + + Script + + + Script + + + Script + + + Script + + + Script + + + Squirrel + + + Squirrel + + + Squirrel + + + Squirrel + + + Squirrel + + + Squirrel + + + Squirrel + + + Squirrel + + + Squirrel + + + Squirrel + + + Squirrel + + + Squirrel + + + Squirrel + + + Squirrel + + + Squirrel headers + + + Squirrel headers + + + Squirrel headers + + + Squirrel headers + + + Squirrel headers + + + Squirrel headers + + + Squirrel headers + + + Squirrel headers + + + Squirrel headers + + + Squirrel headers + + + Squirrel headers + + + Squirrel headers + + + Squirrel headers + + + Squirrel headers + + + Squirrel headers + + + Squirrel headers + + + Squirrel headers + + + Squirrel headers + + + Squirrel headers + + + Squirrel headers + + + AI Core + + + AI Core + + + AI Core + + + AI Core + + + AI Core + + + AI Core + + + AI Core + + + AI Core + + + AI Core + + + AI Core + + + AI Core + + + AI Core + + + AI API + + + Game API + + + Game Core + + + Game Core + + + Game Core + + + Game Core + + + Game Core + + + Game Core + + + Game Core + + + Game Core + + + Game Core + + + Game Core + + + Game Core + + + Game Core + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Script API Implementation + + + Blitters + + + Blitters + + + Blitters + + + Blitters + + + Blitters + + + Blitters + + + Blitters + + + Blitters + + + Blitters + + + Blitters + + + Blitters + + + Blitters + + + Blitters + + + Blitters + + + Blitters + + + Blitters + + + Blitters + + + Blitters + + + Blitters + + + Blitters + + + Blitters + + + Blitters + + + Blitters + + + Blitters + + + Blitters + + + Blitters + + + Blitters + + + Blitters + + + Blitters + + + Drivers + + + Drivers + + + Drivers + + + Sprite loaders + + + Sprite loaders + + + Sprite loaders + + + NewGRF + + + NewGRF + + + NewGRF + + + NewGRF + + + NewGRF + + + NewGRF + + + NewGRF + + + NewGRF + + + NewGRF + + + NewGRF + + + NewGRF + + + NewGRF + + + NewGRF + + + NewGRF + + + NewGRF + + + NewGRF + + + NewGRF + + + NewGRF + + + NewGRF + + + NewGRF + + + NewGRF + + + Map Accessors + + + Map Accessors + + + Map Accessors + + + Map Accessors + + + Map Accessors + + + Map Accessors + + + Map Accessors + + + Map Accessors + + + Map Accessors + + + Map Accessors + + + Map Accessors + + + Map Accessors + + + Map Accessors + + + Map Accessors + + + Map Accessors + + + Map Accessors + + + Map Accessors + + + Misc + + + Misc + + + Misc + + + Misc + + + Misc + + + Misc + + + Misc + + + Misc + + + Misc + + + Misc + + + Misc + + + Misc + + + Network Core + + + Network Core + + + Network Core + + + Network Core + + + Network Core + + + Network Core + + + Network Core + + + Network Core + + + Network Core + + + Network Core + + + Network Core + + + Network Core + + + Network Core + + + Network Core + + + Network Core + + + Network Core + + + Network Core + + + Network Core + + + Network Core + + + Network Core + + + Network Core + + + Network Core + + + Network Core + + + Network Core + + + Network Core + + + Pathfinder + + + Pathfinder + + + Pathfinder + + + Pathfinder + + + Pathfinder + + + Pathfinder + + + NPF + + + NPF + + + NPF + + + NPF + + + NPF + + + NPF + + + YAPF + + + YAPF + + + YAPF + + + YAPF + + + YAPF + + + YAPF + + + YAPF + + + YAPF + + + YAPF + + + YAPF + + + YAPF + + + YAPF + + + YAPF + + + YAPF + + + YAPF + + + YAPF + + + YAPF + + + YAPF + + + Video + + + Video + + + Video + + + Video + + + Music + + + Music + + + Music + + + Sound + + + Sound + + + Sound + + + Windows files + + + Windows files + + + Windows files + + + Threading + + + Threading + + + + + + + diff --git a/projects/openttd_vs140.vcxproj.filters.in b/projects/openttd_vs140.vcxproj.filters.in new file mode 100644 index 0000000000..cda491072c --- /dev/null +++ b/projects/openttd_vs140.vcxproj.filters.in @@ -0,0 +1,13 @@ + + + +!!FILTERS!! + + +!!FILES!! + + + + + + diff --git a/projects/openttd_vs140.vcxproj.in b/projects/openttd_vs140.vcxproj.in new file mode 100644 index 0000000000..8089278bff --- /dev/null +++ b/projects/openttd_vs140.vcxproj.in @@ -0,0 +1,332 @@ + + + + + Debug + Win32 + + + Debug + x64 + + + Release + Win32 + + + Release + x64 + + + + openttd + {668328A0-B40E-4CDB-BD72-D0064424414A} + openttd + + + + Application + false + Unicode + v140 + + + Application + false + Unicode + true + v140 + + + Application + false + Unicode + v140 + + + Application + false + Unicode + true + v140 + + + + + + + + + + + + + + + + + $(SolutionDir)..\objs\$(Platform)\$(Configuration)\ + $(SolutionDir)..\objs\$(Platform)\$(Configuration)\ + false + $(SolutionDir)..\objs\$(Platform)\$(Configuration)\ + $(SolutionDir)..\objs\$(Platform)\$(Configuration)\ + + $(SolutionDir)..\objs\$(Platform)\$(Configuration)\ + false + $(SolutionDir)..\objs\$(Platform)\$(Configuration)\ + $(SolutionDir)..\objs\$(Platform)\$(Configuration)\ + + AllRules.ruleset + + + AllRules.ruleset + + + AllRules.ruleset + + + AllRules.ruleset + + + $(SolutionDir)..\objs\$(Platform)\$(Configuration)\ + $(ProjectDir)..\bin + + + + .\Release/openttd.tlb + + + + + /J /Zc:throwingNew %(AdditionalOptions) + Full + AnySuitable + true + Size + true + ..\objs\langs;..\objs\settings;..\src\3rdparty\squirrel\include;%(AdditionalIncludeDirectories) + WIN32;NDEBUG;_CONSOLE;WIN32_ENABLE_DIRECTMUSIC_SUPPORT;WITH_SSE;WITH_ZLIB;WITH_LZO;WITH_LZMA;LZMA_API_STATIC;WITH_PNG;WITH_FREETYPE;WITH_ICU;U_STATIC_IMPLEMENTATION;ENABLE_NETWORK;WITH_PERSONAL_DIR;PERSONAL_DIR="OpenTTD";WITH_ASSERT;%(PreprocessorDefinitions) + true + Sync + MultiThreaded + 4Bytes + false + true + + + + + + + All + $(IntDir) + $(IntDir) + $(IntDir)$(TargetName).pdb + Level3 + false + true + ProgramDatabase + FastCall + Default + true + true + + + NDEBUG;%(PreprocessorDefinitions) + 0x0809 + + + winmm.lib;ws2_32.lib;imm32.lib;libpng.lib;zlibstat.lib;lzo2.lib;liblzma.lib;libfreetype2.lib;icuuc.lib;icuin.lib;icudt.lib;icule.lib;iculx.lib;%(AdditionalDependencies) + true + %(IgnoreSpecificDefaultLibraries) + true + Windows + 1048576 + 1048576 + true + false + + + MachineX86 + true + 5.01 + + + + + .\Debug/openttd.tlb + + + + + /J /Zc:throwingNew %(AdditionalOptions) + Disabled + true + ..\objs\langs;..\objs\settings;..\src\3rdparty\squirrel\include;%(AdditionalIncludeDirectories) + WIN32;_DEBUG;_CONSOLE;WIN32_ENABLE_DIRECTMUSIC_SUPPORT;WITH_SSE;WITH_ZLIB;WITH_LZO;WITH_LZMA;LZMA_API_STATIC;WITH_PNG;WITH_FREETYPE;WITH_ICU;U_STATIC_IMPLEMENTATION;ENABLE_NETWORK;WITH_PERSONAL_DIR;PERSONAL_DIR="OpenTTD";%(PreprocessorDefinitions) + EnableFastChecks + MultiThreadedDebug + + + $(IntDir) + $(IntDir) + $(IntDir)$(TargetName).pdb + Level3 + false + true + ProgramDatabase + FastCall + Default + true + true + + + _DEBUG;%(PreprocessorDefinitions) + 0x0809 + + + winmm.lib;ws2_32.lib;imm32.lib;libpng.lib;zlibstat.lib;lzo2.lib;liblzma.lib;libfreetype2.lib;icuuc.lib;icuin.lib;icudt.lib;icule.lib;iculx.lib;%(AdditionalDependencies) + true + LIBCMT.lib;%(IgnoreSpecificDefaultLibraries) + true + Windows + 1048576 + 1048576 + false + + + MachineX86 + 5.01 + + + + + X64 + .\Release/openttd.tlb + + + + + /J /Zc:throwingNew %(AdditionalOptions) + Full + AnySuitable + true + Size + true + ..\objs\langs;..\objs\settings;..\src\3rdparty\squirrel\include;%(AdditionalIncludeDirectories) + WIN32;NDEBUG;_CONSOLE;WITH_SSE;WITH_ZLIB;WITH_LZO;WITH_LZMA;LZMA_API_STATIC;WITH_PNG;WITH_FREETYPE;WITH_ICU;U_STATIC_IMPLEMENTATION;ENABLE_NETWORK;WITH_PERSONAL_DIR;PERSONAL_DIR="OpenTTD";_SQ64;WITH_ASSERT;%(PreprocessorDefinitions) + true + Sync + MultiThreaded + Default + false + true + + + + + + + All + $(IntDir) + $(IntDir) + $(IntDir)$(TargetName).pdb + Level3 + false + true + ProgramDatabase + FastCall + Default + true + true + + + NDEBUG;%(PreprocessorDefinitions) + 0x0809 + + + winmm.lib;ws2_32.lib;imm32.lib;libpng.lib;zlibstat.lib;lzo2.lib;liblzma.lib;libfreetype2.lib;icuuc.lib;icuin.lib;icudt.lib;icule.lib;iculx.lib;%(AdditionalDependencies) + true + %(IgnoreSpecificDefaultLibraries) + true + Windows + 1048576 + 1048576 + true + MachineX64 + true + 5.02 + + + + + X64 + .\Debug/openttd.tlb + + + + + /J /Zc:throwingNew %(AdditionalOptions) + Disabled + true + ..\objs\langs;..\objs\settings;..\src\3rdparty\squirrel\include;%(AdditionalIncludeDirectories) + WIN32;_DEBUG;_CONSOLE;WITH_SSE;WITH_ZLIB;WITH_LZO;WITH_LZMA;LZMA_API_STATIC;WITH_PNG;WITH_FREETYPE;WITH_ICU;U_STATIC_IMPLEMENTATION;ENABLE_NETWORK;WITH_PERSONAL_DIR;PERSONAL_DIR="OpenTTD";_SQ64;%(PreprocessorDefinitions) + EnableFastChecks + MultiThreadedDebug + + + + + + + $(IntDir) + $(IntDir) + $(IntDir)$(TargetName).pdb + Level3 + false + true + ProgramDatabase + Cdecl + Default + true + true + + + _DEBUG;%(PreprocessorDefinitions) + 0x0809 + + + winmm.lib;ws2_32.lib;imm32.lib;libpng.lib;zlibstat.lib;lzo2.lib;liblzma.lib;libfreetype2.lib;icuuc.lib;icuin.lib;icudt.lib;icule.lib;iculx.lib;%(AdditionalDependencies) + true + LIBCMT.lib;%(IgnoreSpecificDefaultLibraries) + true + Windows + 1048576 + 1048576 + MachineX64 + 5.02 + + + +!!FILES!! + + + + + + + + {0f066b23-18df-4284-8265-f4a5e7e3b966} + false + + + {a133a442-bd0a-4ade-b117-ad7545e4bdd1} + false + + + {1a2b3c5e-1c23-41a5-9c9b-acba2aa75fec} + false + + + + diff --git a/projects/settings_vs140.vcxproj b/projects/settings_vs140.vcxproj new file mode 100644 index 0000000000..4fe07dbd64 --- /dev/null +++ b/projects/settings_vs140.vcxproj @@ -0,0 +1,54 @@ + + + + + Debug + Win32 + + + + settings + {0817F629-589E-4A3B-B81A-8647BC571E35} + settings + + + + Makefile + v140 + + + + + + + + + +..\objs\settings\settings_gen.exe -o ..\objs\settings\table\settings.h -b ..\src\table\settings.h.preamble -a ..\src\table\settings.h.postamble ..\src\table\company_settings.ini ..\src\table\currency_settings.ini ..\src\table\gameopt_settings.ini ..\src\table\misc_settings.ini ..\src\table\settings.ini ..\src\table\win32_settings.ini ..\src\table\window_settings.ini + + + + ..\objs\settings\table\ + ..\objs\settings\table\ + $(SettingsCommandLine) + $(SettingsCommandLine) + del ..\objs\settings\table\settings.h + ..\objs\settings\table\settings.h + + + + + + + + + + + + + + + + + + diff --git a/projects/settings_vs140.vcxproj.filters b/projects/settings_vs140.vcxproj.filters new file mode 100644 index 0000000000..8caf9fa0a6 --- /dev/null +++ b/projects/settings_vs140.vcxproj.filters @@ -0,0 +1,35 @@ + + + + + {21deca6c-8df4-4f34-9dad-17d7781cd5a0} + + + + + INI + + + INI + + + INI + + + INI + + + INI + + + INI + + + INI + + + + + + + diff --git a/projects/settings_vs140.vcxproj.filters.in b/projects/settings_vs140.vcxproj.filters.in new file mode 100644 index 0000000000..08f90670d2 --- /dev/null +++ b/projects/settings_vs140.vcxproj.filters.in @@ -0,0 +1,15 @@ + + + + + {21deca6c-8df4-4f34-9dad-17d7781cd5a0} + + + +!!FILES!! + + + + + + diff --git a/projects/settings_vs140.vcxproj.in b/projects/settings_vs140.vcxproj.in new file mode 100644 index 0000000000..71ea738dcf --- /dev/null +++ b/projects/settings_vs140.vcxproj.in @@ -0,0 +1,48 @@ + + + + + Debug + Win32 + + + + settings + {0817F629-589E-4A3B-B81A-8647BC571E35} + settings + + + + Makefile + v140 + + + + + + + + + +!!FILTERS!! + + + + ..\objs\settings\table\ + ..\objs\settings\table\ + $(SettingsCommandLine) + $(SettingsCommandLine) + del ..\objs\settings\table\settings.h + ..\objs\settings\table\settings.h + + +!!FILES!! + + + + + + + + + diff --git a/projects/settingsgen_vs140.vcxproj b/projects/settingsgen_vs140.vcxproj new file mode 100644 index 0000000000..fc6d079e8e --- /dev/null +++ b/projects/settingsgen_vs140.vcxproj @@ -0,0 +1,83 @@ + + + + + Debug + Win32 + + + + settingsgen + {E9548DE9-F089-49B7-93A6-30BE2CC311C7} + settings + + + + Application + MultiByte + v140 + + + + + + + + + + <_ProjectFileVersion>10.0.30319.1 + ..\objs\settings\ + ..\objs\settings\ + settings_gen + + + + + + + + %(Inputs) + + + MinSpace + Size + SETTINGSGEN;WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions) + All + $(IntDir)$(TargetName).pdb + Level3 + true + ProgramDatabase + MultiThreadedDebug + + + $(OutDir)settings_gen.exe + true + false + + + Console + 5.01 + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/projects/settingsgen_vs140.vcxproj.filters b/projects/settingsgen_vs140.vcxproj.filters new file mode 100644 index 0000000000..c8afe0c8ed --- /dev/null +++ b/projects/settingsgen_vs140.vcxproj.filters @@ -0,0 +1,32 @@ + + + + + {a4678737-b3b3-4be5-9db1-fa6ccd164c59} + + + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + + + + + + + + diff --git a/projects/strgen_vs140.vcxproj b/projects/strgen_vs140.vcxproj new file mode 100644 index 0000000000..ebf56a4daf --- /dev/null +++ b/projects/strgen_vs140.vcxproj @@ -0,0 +1,95 @@ + + + + + Debug + Win32 + + + + strgen + {A133A442-BD0A-4ADE-B117-AD7545E4BDD1} + strgen + + + + Application + false + MultiByte + v140 + + + + + + + + + + $(SolutionDir)..\objs\strgen\ + $(SolutionDir)..\objs\strgen\ + false + AllRules.ruleset + + + + + + .\Debug/strgen.tlb + + + + + /MP %(AdditionalOptions) + MinSpace + Size + STRGEN;WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions) + Default + MultiThreadedDebug + + + All + $(IntDir) + $(IntDir) + $(IntDir)$(TargetName).pdb + Level3 + true + true + ProgramDatabase + + + _DEBUG;%(PreprocessorDefinitions) + 0x041d + + + true + true + $(IntDir)strgen.pdb + Console + false + + + MachineX86 + 5.01 + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/projects/strgen_vs140.vcxproj.filters b/projects/strgen_vs140.vcxproj.filters new file mode 100644 index 0000000000..58864ee691 --- /dev/null +++ b/projects/strgen_vs140.vcxproj.filters @@ -0,0 +1,35 @@ + + + + + {5894294c-d4dc-41f0-be31-e56cff4e0405} + cpp;c;cxx;rc;def;r;odl;idl;hpj;bat + + + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + Source Files + + + + + + + + + + + + diff --git a/projects/version_vs140.vcxproj b/projects/version_vs140.vcxproj new file mode 100644 index 0000000000..baf374bca0 --- /dev/null +++ b/projects/version_vs140.vcxproj @@ -0,0 +1,42 @@ + + + + + Debug + Win32 + + + + version + {1A2B3C5E-1C23-41A5-9C9B-ACBA2AA75FEC} + version + + + + Makefile + MultiByte + v140 + + + + + + + + + + $(SolutionDir)..\objs\version\ + $(SolutionDir)..\objs\version\ + cscript "$(ProjectDir)/determineversion.vbs" + cscript "$(ProjectDir)/determineversion.vbs" + ..\src\rev.cpp + del ..\src\rev.cpp + + + + + + + + + \ No newline at end of file From cca6495d1e6c6a4c76487bd05c77fe74b8f1a109 Mon Sep 17 00:00:00 2001 From: Jonathan G Rennison Date: Tue, 11 Aug 2015 21:06:21 +0100 Subject: [PATCH 22/29] Auto timetabling: bias timetable adjustment to favour negative adjustments. This is to prevent positive feedback where timetable times are increased due to congestion, which creates more congestion due to trains waiting for extended periods at stations and/or due to timetable auto separation going overboard due to overly long timetables. * Double rate of negative adjustments. * Half rate of positive adjustments. * Only do step changes for large negative adjustments. * Reduce jam detection threshold. --- src/timetable_cmd.cpp | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/src/timetable_cmd.cpp b/src/timetable_cmd.cpp index c26b4e73b2..809a4149b0 100644 --- a/src/timetable_cmd.cpp +++ b/src/timetable_cmd.cpp @@ -668,15 +668,7 @@ void UpdateVehicleTimetable(Vehicle *v, bool travelling) new_time = time_loading; } - /* Check for too large a difference from expected time, and if so don't average. */ - if (!(new_time > (int32)timetabled * 2 || new_time < (int32)timetabled / 2)) { - int arrival_error = timetabled - new_time; - /* Compute running average, with sign conversion to avoid negative overflow. */ - new_time = ((int32)timetabled * 4 + new_time + 2) / 5; - /* Use arrival_error to finetune order ticks. */ - if (arrival_error < 0) new_time++; - if (arrival_error > 0) new_time--; - } else if (new_time > (int32)timetabled * 10 && travelling) { + if (new_time > (int32)timetabled * 4 && travelling) { /* Possible jam, clear time and restart timetable for all vehicles. * Otherwise we risk trains blocking 1-lane stations for long times. */ ChangeTimetable(v, v->cur_real_order_index, 0, travelling ? MTF_TRAVEL_TIME : MTF_WAIT_TIME, true); @@ -686,6 +678,15 @@ void UpdateVehicleTimetable(Vehicle *v, bool travelling) SetWindowDirty(WC_VEHICLE_TIMETABLE, v2->index); } return; + } else if (new_time >= (int32)timetabled / 2) { + /* Compute running average, with sign conversion to avoid negative overflow. */ + if (new_time < (int32)timetabled) { + new_time = ((int32)timetabled * 3 + new_time * 2 + 2) / 5; + } else { + new_time = ((int32)timetabled * 9 + new_time + 5) / 10; + } + } else { + /* new time is less than hald old time, set value directly */ } if (new_time < 1) new_time = 1; From 40ad3dea020de15e2c25788eef15ca7270e41f23 Mon Sep 17 00:00:00 2001 From: Jonathan G Rennison Date: Tue, 11 Aug 2015 21:20:01 +0100 Subject: [PATCH 23/29] Auto separation: Add setting to scale vehicle lateness adjustments. No longer set vehicle lateness to 0 if separation fails, instead leave it as it was. The setting defaults to 100% (full abruptness, old behaviour). Reduce the setting if auto separation is too disruptive, e.g. causes excessive waiting in stations. Note that this is not savegame compatible. --- src/lang/english.txt | 2 ++ src/settings_gui.cpp | 1 + src/settings_type.h | 1 + src/table/settings.ini | 14 ++++++++++++++ src/timetable_cmd.cpp | 7 +++++-- 5 files changed, 23 insertions(+), 2 deletions(-) diff --git a/src/lang/english.txt b/src/lang/english.txt index 3a4de4156c..04181e382c 100644 --- a/src/lang/english.txt +++ b/src/lang/english.txt @@ -1400,6 +1400,8 @@ STR_CONFIG_SETTING_TIMETABLE_IN_TICKS :Show timetable STR_CONFIG_SETTING_TIMETABLE_IN_TICKS_HELPTEXT :Show travel times in time tables in game ticks instead of days STR_CONFIG_SETTING_TIMETABLE_SEPARATION :Use timetable to ensure vehicle separation: {STRING2} STR_CONFIG_SETTING_TIMETABLE_SEPARATION_HELPTEXT :Select whether to ensure separation of vehicles when using automatic timetables +STR_CONFIG_SETTING_TIMETABLE_SEPARATION_RATE :Vehicle separation factor: {STRING2} +STR_CONFIG_SETTING_TIMETABLE_SEPARATION_RATE_HELPTEXT :How much of the vehicle separation timetable change to apply at each step STR_CONFIG_SETTING_TIMETABLE_SHOW_ARRIVAL_DEPARTURE :Show arrival and departure in timetables: {STRING2} STR_CONFIG_SETTING_TIMETABLE_SHOW_ARRIVAL_DEPARTURE_HELPTEXT :Display anticipated arrival and departure times in timetables STR_CONFIG_SETTING_QUICKGOTO :Quick creation of vehicle orders: {STRING2} diff --git a/src/settings_gui.cpp b/src/settings_gui.cpp index 452f6b6fd2..1c3da570a7 100644 --- a/src/settings_gui.cpp +++ b/src/settings_gui.cpp @@ -1628,6 +1628,7 @@ static SettingsContainer &GetSettingsTree() vehicles->Add(new SettingEntry("order.serviceathelipad")); vehicles->Add(new SettingEntry("order.timetable_automated")); vehicles->Add(new SettingEntry("order.timetable_separation")); + vehicles->Add(new SettingEntry("order.timetable_separation_rate")); } SettingsPage *limitations = main->Add(new SettingsPage(STR_CONFIG_SETTING_LIMITATIONS)); diff --git a/src/settings_type.h b/src/settings_type.h index b3eeae407f..7c3b34478d 100644 --- a/src/settings_type.h +++ b/src/settings_type.h @@ -440,6 +440,7 @@ struct OrderSettings { bool no_servicing_if_no_breakdowns; ///< don't send vehicles to depot when breakdowns are disabled bool timetable_automated; ///< whether to automatically manage timetables bool timetable_separation; ///< whether to perform automatic separation based on timetable + uint8 timetable_separation_rate; ///< percentage of timetable separation change to apply bool serviceathelipad; ///< service helicopters at helipads automatically (no need to send to depot) }; diff --git a/src/table/settings.ini b/src/table/settings.ini index d7c6d692a9..53efed2fe6 100644 --- a/src/table/settings.ini +++ b/src/table/settings.ini @@ -347,6 +347,20 @@ str = STR_CONFIG_SETTING_TIMETABLE_SEPARATION strhelp = STR_CONFIG_SETTING_TIMETABLE_SEPARATION_HELPTEXT cat = SC_EXPERT +[SDT_VAR] +base = GameSettings +var = order.timetable_separation_rate +type = SLE_UINT8 +from = TIMESEP_SV +def = 100 +min = 0 +max = 100 +interval = 10 +str = STR_CONFIG_SETTING_TIMETABLE_SEPARATION_RATE +strhelp = STR_CONFIG_SETTING_TIMETABLE_SEPARATION_RATE_HELPTEXT +strval = STR_CONFIG_SETTING_PERCENTAGE +cat = SC_EXPERT + ; There are only 21 predefined town_name values (0-20), but you can have more with newgrf action F so allow ; these bigger values (21-255). Invalid values will fallback to english on use and (undefined string) in GUI. [SDT_OMANY] diff --git a/src/timetable_cmd.cpp b/src/timetable_cmd.cpp index 809a4149b0..3fddfbe6ac 100644 --- a/src/timetable_cmd.cpp +++ b/src/timetable_cmd.cpp @@ -548,8 +548,11 @@ void UpdateSeparationOrder(Vehicle *v_start) } int separation_ahead = SeparationBetween(v, v->AheadSeparation()); int separation_behind = SeparationBetween(v->BehindSeparation(), v); - v->lateness_counter = (separation_ahead - separation_behind) / 2; - if (separation_ahead == -1 || separation_behind == -1) v->lateness_counter = 0; + if (separation_ahead != -1 && separation_behind != -1) { + int new_lateness = (separation_ahead - separation_behind) / 2; + v->lateness_counter = (new_lateness * _settings_game.order.timetable_separation_rate + + v->lateness_counter * (100 - _settings_game.order.timetable_separation_rate)) / 100; + } v = v->AheadSeparation(); } while (v != v_start); } From 25bc8eb1e2019a5482b1ec49e606672eea383304 Mon Sep 17 00:00:00 2001 From: Jonathan G Rennison Date: Tue, 11 Aug 2015 21:24:56 +0100 Subject: [PATCH 24/29] Save/load changes for timetable_separation_rate setting. --- src/table/settings.ini | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/table/settings.ini b/src/table/settings.ini index 345c575a31..af0754bbd1 100644 --- a/src/table/settings.ini +++ b/src/table/settings.ini @@ -355,7 +355,6 @@ patxname = ""auto_timetables.order.timetable_separation"" base = GameSettings var = order.timetable_separation_rate type = SLE_UINT8 -from = TIMESEP_SV def = 100 min = 0 max = 100 @@ -364,6 +363,8 @@ str = STR_CONFIG_SETTING_TIMETABLE_SEPARATION_RATE strhelp = STR_CONFIG_SETTING_TIMETABLE_SEPARATION_RATE_HELPTEXT strval = STR_CONFIG_SETTING_PERCENTAGE cat = SC_EXPERT +extver = SlXvFeatureTest(XSLFTO_AND, XSLFI_AUTO_TIMETABLE) +patxname = ""auto_timetables.order.timetable_separation_rate"" ; There are only 21 predefined town_name values (0-20), but you can have more with newgrf action F so allow ; these bigger values (21-255). Invalid values will fallback to english on use and (undefined string) in GUI. From dd2805da8ce968f85dd78463c66d0b788c8e7c8d Mon Sep 17 00:00:00 2001 From: Jonathan G Rennison Date: Tue, 11 Aug 2015 20:57:32 +0100 Subject: [PATCH 25/29] Servicing: send vehicles which need auto-renewing due to age for servicing, even if breakdowns are off and no servicing if no breakdowns is on. --- src/vehicle.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/vehicle.cpp b/src/vehicle.cpp index 46f98fe63b..792912911e 100644 --- a/src/vehicle.cpp +++ b/src/vehicle.cpp @@ -138,6 +138,11 @@ bool Vehicle::NeedsServicing() const return true; } + /* Is vehicle old and renewing is enabled */ + if (this->NeedsAutorenewing(c, true)) { + return true; + } + /* Test whether there is some pending autoreplace. * Note: We do this after the service-interval test. * There are a lot more reasons for autoreplace to fail than we can test here reasonably. */ From 8f711aca5349a20a5d17cc051ad4421945114dd4 Mon Sep 17 00:00:00 2001 From: rubidium Date: Wed, 12 Aug 2015 20:50:10 +0000 Subject: [PATCH 26/29] (svn r27383) -Fix: win32 sound driver would not catch the exception due to constness difference --- src/sound/win32_s.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/sound/win32_s.cpp b/src/sound/win32_s.cpp index 0cd632714c..45f88172a9 100644 --- a/src/sound/win32_s.cpp +++ b/src/sound/win32_s.cpp @@ -81,7 +81,7 @@ const char *SoundDriver_Win32::Start(const char * const *parm) PrepareHeader(&_wave_hdr[1]); if (NULL == (_thread = CreateThread(NULL, 8192, SoundThread, 0, 0, &_threadId))) throw "Failed to create thread"; - } catch (char *error) { + } catch (const char *error) { this->Stop(); return error; } From 70322bce595b1608ff8b00dd353700ce7b5f4119 Mon Sep 17 00:00:00 2001 From: translators Date: Thu, 13 Aug 2015 17:45:15 +0000 Subject: [PATCH 27/29] (svn r27384) -Update from WebTranslator v3.0: catalan - 35 changes by juanjo --- src/lang/catalan.txt | 70 ++++++++++++++++++++++---------------------- 1 file changed, 35 insertions(+), 35 deletions(-) diff --git a/src/lang/catalan.txt b/src/lang/catalan.txt index b9de63180f..2e8ecf97c0 100644 --- a/src/lang/catalan.txt +++ b/src/lang/catalan.txt @@ -1181,64 +1181,64 @@ STR_CONFIG_SETTING_TRAIN_ACCELERATION_MODEL :Model d'acceler STR_CONFIG_SETTING_TRAIN_ACCELERATION_MODEL_HELPTEXT :Seleccioneu el model físic per l'acceleració de trens. El model «original» penalitza les pujades per igual a tots els vehicles. El model «realista» penalitza les pujades i les corbes en funció de diverses propietats del tren, com ara la longitud i la força de tracció STR_CONFIG_SETTING_ROAD_VEHICLE_ACCELERATION_MODEL :Model d'acceleració per als vehicles: {STRING} STR_CONFIG_SETTING_ROAD_VEHICLE_ACCELERATION_MODEL_HELPTEXT :Seleccioneu el model físic per l'acceleració d'automòbils. El model «original» penalitza les pujades per igual a tots els vehicles. El model «realista» penalitza els pendents en funció de les diferents propietats de la màquina, com per exemple l'esforç de tracció. -STR_CONFIG_SETTING_TRAIN_SLOPE_STEEPNESS :Pendent d'inclinació per als trens: {STRING} -STR_CONFIG_SETTING_TRAIN_SLOPE_STEEPNESS_HELPTEXT :La inclinació d'una cel·la en pendent per a un tren. Els valors més alts fan que sigui més difícil escalar un turó +STR_CONFIG_SETTING_TRAIN_SLOPE_STEEPNESS :Pendent de les costes per als trens: {STRING} +STR_CONFIG_SETTING_TRAIN_SLOPE_STEEPNESS_HELPTEXT :El pendent de les caselles amb costes per als trens. Els valors alts fan que sigui més difícil pujar els turons. STR_CONFIG_SETTING_PERCENTAGE :{COMMA}% -STR_CONFIG_SETTING_ROAD_VEHICLE_SLOPE_STEEPNESS :Pendent d'inclinació per als automòbils: {STRING} -STR_CONFIG_SETTING_ROAD_VEHICLE_SLOPE_STEEPNESS_HELPTEXT :La inclinació d'una cel·la amb pendent per a automòbils. Els valors més alts fan que sigui més difícil escalar un turó +STR_CONFIG_SETTING_ROAD_VEHICLE_SLOPE_STEEPNESS :Pendent de les costes per als vehicles de carretera: {STRING} +STR_CONFIG_SETTING_ROAD_VEHICLE_SLOPE_STEEPNESS_HELPTEXT :El pendent de les caselles amb costes per a vehicles de carretera. Els valors alts fan que sigui més difícil pujar els turons. STR_CONFIG_SETTING_FORBID_90_DEG :Prohibeix fer girs de 90 graus als trens i vaixells: {STRING} -STR_CONFIG_SETTING_FORBID_90_DEG_HELPTEXT :Els girs de 90 graus succeeixen quan una via horitzontal està seguida d'una vertical a la cel·la annexa, provocant que el tren giri 90 graus quan travessi la vora de la cel·la en lloc dels 45 graus usuals en les altres combinacions. Això també s'aplica al radi de gir dels vaixells +STR_CONFIG_SETTING_FORBID_90_DEG_HELPTEXT :Els girs de 90 graus succeeixen quan hi ha una via horitzontal seguida d'una de vertical a la cel·la annexa, provocant que el tren giri 90 graus quan travessi la vora de la cel·la en lloc dels 45 graus usuals en les altres combinacions. Això també s'aplica al gir dels vaixells. STR_CONFIG_SETTING_DISTANT_JOIN_STATIONS :Permet ajuntar estacions no annexes: {STRING} -STR_CONFIG_SETTING_DISTANT_JOIN_STATIONS_HELPTEXT :Permetre afegir parts a una estació sense contacte directe amb les parts existents. Fa falta Ctrl + Clic, mentre és col·loquen les peces noves +STR_CONFIG_SETTING_DISTANT_JOIN_STATIONS_HELPTEXT :Aquesta opció permet afegir parts noves a una estació existent sense estar les parts noves en contacte directe amb les existents. Cal clicar Ctrl+Clic mentre es col·loquen les parts noves. STR_CONFIG_SETTING_INFLATION :Inflació: {STRING} -STR_CONFIG_SETTING_INFLATION_HELPTEXT :Habilita la inflació a l'economia, on l'augment dels costos són una mica més ràpids que els dels pagaments -STR_CONFIG_SETTING_MAX_BRIDGE_LENGTH :Màxima longitud dels ponts: {STRING} +STR_CONFIG_SETTING_INFLATION_HELPTEXT :Habilita la inflació a l'economia, on l'augment dels costos són una mica més ràpids que els dels pagaments. +STR_CONFIG_SETTING_MAX_BRIDGE_LENGTH :Longitud màxima dels ponts: {STRING} STR_CONFIG_SETTING_MAX_BRIDGE_LENGTH_HELPTEXT :Longitud màxima per a la construcció de ponts STR_CONFIG_SETTING_MAX_BRIDGE_HEIGHT :Alçada màxima dels ponts: {STRING} STR_CONFIG_SETTING_MAX_BRIDGE_HEIGHT_HELPTEXT :Alçada màxima de construcció dels ponts STR_CONFIG_SETTING_MAX_TUNNEL_LENGTH :Màxima longitud dels túnels: {STRING} STR_CONFIG_SETTING_MAX_TUNNEL_LENGTH_HELPTEXT :Longitud màxima per a la construcció de túnels -STR_CONFIG_SETTING_RAW_INDUSTRY_CONSTRUCTION_METHOD :Mètode de construcció de la indústria primària manual: {STRING} -STR_CONFIG_SETTING_RAW_INDUSTRY_CONSTRUCTION_METHOD_HELPTEXT :Mètode de finançament d'indústria primària. 'cap' significa que no serà possible fundar-ne cap, 'prospecció' significa que serà possible fundar-ne, però la construcció succeirà en un lloc aleatori del mapa i també podria passar que fracassi, 'com les altre indústries' significa que les indústries de matèries primeres poden ser construides a qualsevol lloc per les companyies igual que les indústries manufactureres -STR_CONFIG_SETTING_RAW_INDUSTRY_CONSTRUCTION_METHOD_NONE :Cap +STR_CONFIG_SETTING_RAW_INDUSTRY_CONSTRUCTION_METHOD :Fundació de noves indústries primàries: {STRING} +STR_CONFIG_SETTING_RAW_INDUSTRY_CONSTRUCTION_METHOD_HELPTEXT :Mètode de fundació de noves indústries primàries. «Fundació desactivada» significa que no serà possible fundar-ne cap, «Amb prospeccions» significa que serà possible fundar-ne, però la construcció succeirà en un lloc aleatori del mapa i podria fracassar. «Com les altres indústries» significa que les indústries de matèries primeres poden ser construïdes en qualsevol lloc per les companyies igual que les indústries manufactureres. +STR_CONFIG_SETTING_RAW_INDUSTRY_CONSTRUCTION_METHOD_NONE :Fundació desactivada STR_CONFIG_SETTING_RAW_INDUSTRY_CONSTRUCTION_METHOD_NORMAL :Com les altres indústries -STR_CONFIG_SETTING_RAW_INDUSTRY_CONSTRUCTION_METHOD_PROSPECTING :Prospeccionant -STR_CONFIG_SETTING_INDUSTRY_PLATFORM :Àrea plana al voltant de les indústries: {STRING} -STR_CONFIG_SETTING_INDUSTRY_PLATFORM_HELPTEXT :Quantitat d'espai pla al voltant d'una indústira. Això assegura que quedarà espai buit al voltant de la indústria per a construir vies, etc. +STR_CONFIG_SETTING_RAW_INDUSTRY_CONSTRUCTION_METHOD_PROSPECTING :Amb prospeccions +STR_CONFIG_SETTING_INDUSTRY_PLATFORM :Àrea anivellada al voltant de les indústries: {STRING} +STR_CONFIG_SETTING_INDUSTRY_PLATFORM_HELPTEXT :Quantitat d'espai pla al voltant d'una indústria. Això assegura que quedarà espai buit al voltant de la indústria per construir vies o altres infraestructures. STR_CONFIG_SETTING_MULTIPINDTOWN :Permet vàries indústries similars a cada població: {STRING} -STR_CONFIG_SETTING_MULTIPINDTOWN_HELPTEXT :Normalment, una població no vol més d'un tipus d'indústria de cada tipus. Amb aquest paràmetre es permetrà diverses indústries del mateix tipus a la mateixa població +STR_CONFIG_SETTING_MULTIPINDTOWN_HELPTEXT :Normalment, una població no vol tenir més d'una indústria de cada tipus. Amb aquest paràmetre es permet la construcció de diverses indústries del mateix tipus a la mateixa població. STR_CONFIG_SETTING_SIGNALSIDE :Mostra els senyals: {STRING} -STR_CONFIG_SETTING_SIGNALSIDE_HELPTEXT :Selecciona a quin costat de la via s'han de posar els senyals +STR_CONFIG_SETTING_SIGNALSIDE_HELPTEXT :Seleccioneu a quin costat de la via s'han de posar els senyals STR_CONFIG_SETTING_SIGNALSIDE_LEFT :A l'esquerra STR_CONFIG_SETTING_SIGNALSIDE_DRIVING_SIDE :Al costat de conducció STR_CONFIG_SETTING_SIGNALSIDE_RIGHT :A la dreta STR_CONFIG_SETTING_SHOWFINANCES :Mostra la finestra de balanç al finalitzar cada any: {STRING} -STR_CONFIG_SETTING_SHOWFINANCES_HELPTEXT :Si està activat, la finestra de finances apareix al final de cada any per permetre una inspecció fàcil de l'estat financer de la companyia -STR_CONFIG_SETTING_NONSTOP_BY_DEFAULT :Les noves ordres predeterminades són 'sense parada': {STRING} -STR_CONFIG_SETTING_NONSTOP_BY_DEFAULT_HELPTEXT :Normalment, un vehicle pararà a cada estació que passi. Activant aquest paràmetre no pararà a cap estació fins arribar a la seu destí. Nota, aquest paràmetre només defineix el valor predeterminat per les noves ordres. De totes maneres les ordres individuals poden establir explícitament qualsevol dels comportaments -STR_CONFIG_SETTING_STOP_LOCATION :Noves ordres del tren: parar per defecte {STRING} de la plataforma -STR_CONFIG_SETTING_STOP_LOCATION_HELPTEXT :Situa en quin lloc de la plataforma el tren pararà per defecte. 'Extrem més proper' significa a prop del punt d'entrada, 'al mig' significa al mig de la plataforma, i 'extrem més llunyà' significa lluny del punt d'entrada. Nota, aquest paràmetre només defineix el valor predeterminat per les noves ordres. De totes maneres les ordres individuals poden establir explícitament qualsevol dels comportaments -STR_CONFIG_SETTING_STOP_LOCATION_NEAR_END :a l'extrem més proper -STR_CONFIG_SETTING_STOP_LOCATION_MIDDLE :a la meitat -STR_CONFIG_SETTING_STOP_LOCATION_FAR_END :a l'extrem més llunyà -STR_CONFIG_SETTING_AUTOSCROLL :Finestra d'avís quan el ratolí és al marc del programa: {STRING} -STR_CONFIG_SETTING_AUTOSCROLL_HELPTEXT :Quan està activat, les vistes començaran a desplaçar-se quan el ratolí sigui a prop la vora de la finestra +STR_CONFIG_SETTING_SHOWFINANCES_HELPTEXT :Si el paràmetre està activat, la finestra de finances apareix al final de cada any per permetre una inspecció fàcil de l'estat financer de la companyia. +STR_CONFIG_SETTING_NONSTOP_BY_DEFAULT :«Sense parada» per defecte a les noves ordres : {STRING} +STR_CONFIG_SETTING_NONSTOP_BY_DEFAULT_HELPTEXT :Normalment, un vehicle para a cada estació per la que passa. Activant aquest paràmetre, no pararà a cap estació fins arribar al seu destí. Nota: aquest paràmetre només defineix el valor predeterminat per a les noves ordres. Un cop creada una ordre, aquesta es pot establir manualment al comportament desitjat. +STR_CONFIG_SETTING_STOP_LOCATION :Noves ordres de trens: parar per defecte {STRING} de la plataforma +STR_CONFIG_SETTING_STOP_LOCATION_HELPTEXT :Estableix en quin lloc de la plataforma els trens pararan per defecte. «Extrem més proper» significa a prop del punt d'entrada, «Al mig» significa al mig de la plataforma, i «Extrem més llunyà» significa lluny del punt d'entrada. Nota: aquest paràmetre només defineix el valor predeterminat per les noves ordres. Un cop creada una ordre, es pot modificar el comportament de forma manual. +STR_CONFIG_SETTING_STOP_LOCATION_NEAR_END :A l'extrem més proper +STR_CONFIG_SETTING_STOP_LOCATION_MIDDLE :Al mig +STR_CONFIG_SETTING_STOP_LOCATION_FAR_END :A l'extrem més llunyà +STR_CONFIG_SETTING_AUTOSCROLL :Desplaça la finestra quan el ratolí sigui prop de la vora: {STRING} +STR_CONFIG_SETTING_AUTOSCROLL_HELPTEXT :Quan està activat, l'àrea de visualització començarà a desplaçar-se quan el ratolí sigui prop de la vora de la finestra. STR_CONFIG_SETTING_AUTOSCROLL_DISABLED :Desactivat -STR_CONFIG_SETTING_AUTOSCROLL_MAIN_VIEWPORT_FULLSCREEN :Vista principal, només pantalla completa +STR_CONFIG_SETTING_AUTOSCROLL_MAIN_VIEWPORT_FULLSCREEN :Vista principal (només pantalla completa) STR_CONFIG_SETTING_AUTOSCROLL_MAIN_VIEWPORT :Vista principal -STR_CONFIG_SETTING_AUTOSCROLL_EVERY_VIEWPORT :Cada vista -STR_CONFIG_SETTING_BRIBE :Permet subornar a les autoritats locals: {STRING} -STR_CONFIG_SETTING_BRIBE_HELPTEXT :Permet a les companyies intentar subornar a l'autoritat local. Si el suborn és detectat per un inspector, la companyia no podrà actuar a la població durant sis mesos +STR_CONFIG_SETTING_AUTOSCROLL_EVERY_VIEWPORT :Qualsevol vista +STR_CONFIG_SETTING_BRIBE :Permet subornar les autoritats locals: {STRING} +STR_CONFIG_SETTING_BRIBE_HELPTEXT :Permet a les companyies intentar subornar l'autoritat local. Si el suborn és detectat per un inspector, la companyia no podrà actuar a la població durant sis mesos. STR_CONFIG_SETTING_ALLOW_EXCLUSIVE :Permet comprar els drets del transport en exclusiva: {STRING} -STR_CONFIG_SETTING_ALLOW_EXCLUSIVE_HELPTEXT :Si una companyia compra els drets de transport en exclusiva en una població, les estacions dels oponents (passatgers i càrrega) no rebran cap càrrega durant tot l'any +STR_CONFIG_SETTING_ALLOW_EXCLUSIVE_HELPTEXT :Si una companyia compra els drets de transport en exclusiva d'una població, les estacions dels oponents (passatgers i càrrega) no rebran cap càrrega durant un any sencer. STR_CONFIG_SETTING_ALLOW_FUND_BUILDINGS :Permet finançar edificis: {STRING} -STR_CONFIG_SETTING_ALLOW_FUND_BUILDINGS_HELPTEXT :Permet a les companyies donar diners a les poblacions per a finançar nous edificis +STR_CONFIG_SETTING_ALLOW_FUND_BUILDINGS_HELPTEXT :Permet a les companyies donar diners a les poblacions per finançar nous edificis STR_CONFIG_SETTING_ALLOW_FUND_ROAD :Permet finançar la reconstrucció dels carrers locals: {STRING} -STR_CONFIG_SETTING_ALLOW_FUND_ROAD_HELPTEXT :Permet a les companyies donar diners a les poblacions per a la reconstrucció de carrers i sabotejar-hi la circulació de vehicles +STR_CONFIG_SETTING_ALLOW_FUND_ROAD_HELPTEXT :Permet a les companyies donar diners a les poblacions per la reconstrucció de carrers i sabotejar la circulació de vehicles. STR_CONFIG_SETTING_ALLOW_GIVE_MONEY :Permet enviar diners a altres companyies: {STRING} STR_CONFIG_SETTING_ALLOW_GIVE_MONEY_HELPTEXT :Permet transferir diners entre companyies en el mode multijugador -STR_CONFIG_SETTING_FREIGHT_TRAINS :Multiplicador de pes per contenidor per simular trens pesats: {STRING} -STR_CONFIG_SETTING_FREIGHT_TRAINS_HELPTEXT :Estableix l'impacte de transportar contenidors en trens. Un valor més alt fa que transportar contenidors sigui més exigent amb els trens, especialment als turons +STR_CONFIG_SETTING_FREIGHT_TRAINS :Multiplicador de pes per simular trens pesats: {STRING} +STR_CONFIG_SETTING_FREIGHT_TRAINS_HELPTEXT :Estableix l'impacte de transportar contenidors en trens. Els valors alts fan que transportar contenidors sigui més exigent amb els trens, especialment als turons. STR_CONFIG_SETTING_PLANE_SPEED :Factor de velocitat dels avions: {STRING} STR_CONFIG_SETTING_PLANE_SPEED_HELPTEXT :Estableix la velocitat relativa dels avions en comparació amb els altres tipus de vehicles, per reduir la quantitat de guanys de transport dels avions STR_CONFIG_SETTING_PLANE_SPEED_VALUE :1 / {COMMA} From 3b8aabdd9eaa13586b557812d22cad0e4ab95f85 Mon Sep 17 00:00:00 2001 From: rubidium Date: Thu, 13 Aug 2015 18:13:24 +0000 Subject: [PATCH 28/29] (svn r27385) -Fix: compilation failure due #define-ing enum name of a system library before including the system library --- src/os/windows/win32.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/os/windows/win32.cpp b/src/os/windows/win32.cpp index f69f01f6cb..2682fa1433 100644 --- a/src/os/windows/win32.cpp +++ b/src/os/windows/win32.cpp @@ -14,13 +14,13 @@ #include "../../gfx_func.h" #include "../../textbuf_gui.h" #include "../../fileio_func.h" -#include "../../fios.h" #include #include #include #include /* SHGetFolderPath */ #include #include "win32.h" +#include "../../fios.h" #include "../../core/alloc_func.hpp" #include "../../openttd.h" #include "../../core/random_func.hpp" From 8cfc1e9d2392097538580fc7728e4b55b962d1e3 Mon Sep 17 00:00:00 2001 From: translators Date: Fri, 14 Aug 2015 17:45:16 +0000 Subject: [PATCH 29/29] (svn r27386) -Update from WebTranslator v3.0: dutch - 3 changes by TheTycoonist --- src/lang/dutch.txt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/lang/dutch.txt b/src/lang/dutch.txt index 83a67773c5..c051f4fdba 100644 --- a/src/lang/dutch.txt +++ b/src/lang/dutch.txt @@ -3185,7 +3185,7 @@ STR_FINANCES_YEAR :{WHITE}{NUM} STR_FINANCES_SECTION_CONSTRUCTION :{GOLD}Bouwkosten STR_FINANCES_SECTION_NEW_VEHICLES :{GOLD}Nieuwe voertuigen STR_FINANCES_SECTION_TRAIN_RUNNING_COSTS :{GOLD}Treinonderhoudskosten -STR_FINANCES_SECTION_ROAD_VEHICLE_RUNNING_COSTS :{GOLD}Wegvoertuigbrandstofkosten +STR_FINANCES_SECTION_ROAD_VEHICLE_RUNNING_COSTS :{GOLD}Wegvoertuigonderhoudskosten STR_FINANCES_SECTION_AIRCRAFT_RUNNING_COSTS :{GOLD}Vliegtuigonderhoudskosten STR_FINANCES_SECTION_SHIP_RUNNING_COSTS :{GOLD}Schiponderhoudskosten STR_FINANCES_SECTION_PROPERTY_MAINTENANCE :{GOLD}Eigendomsonderhoud @@ -3268,7 +3268,7 @@ STR_COMPANY_INFRASTRUCTURE_VIEW_TRAMWAY :{WHITE}Tramrail STR_COMPANY_INFRASTRUCTURE_VIEW_WATER_SECT :{GOLD}Water tegels: STR_COMPANY_INFRASTRUCTURE_VIEW_CANALS :{WHITE}Kanalen STR_COMPANY_INFRASTRUCTURE_VIEW_STATION_SECT :{GOLD}Stations: -STR_COMPANY_INFRASTRUCTURE_VIEW_STATIONS :{WHITE}Station tegels +STR_COMPANY_INFRASTRUCTURE_VIEW_STATIONS :{WHITE}Stationtegels STR_COMPANY_INFRASTRUCTURE_VIEW_AIRPORTS :{WHITE}Vliegvelden STR_COMPANY_INFRASTRUCTURE_VIEW_TOTAL :{WHITE}{CURRENCY_LONG}/jr @@ -3350,7 +3350,7 @@ STR_GROUP_DEFAULT_SHIPS :Niet gegroepeer STR_GROUP_DEFAULT_AIRCRAFTS :Niet gegroepeerde vliegtuigen STR_GROUPS_CLICK_ON_GROUP_FOR_TOOLTIP :{BLACK}Groepen - Klik op een groep voor een lijst van alle voertuigen in deze groep. Klik en sleep om hiërarchie te beheren -STR_GROUP_CREATE_TOOLTIP :{BLACK}Klik om een groep te maken +STR_GROUP_CREATE_TOOLTIP :{BLACK}Klik om een groep te creëren STR_GROUP_DELETE_TOOLTIP :{BLACK}Verwijder de geselecteerde groep STR_GROUP_RENAME_TOOLTIP :{BLACK}Hernoem de geselecteerde groep STR_GROUP_REPLACE_PROTECTION_TOOLTIP :{BLACK}Klik om deze groep te beschermen tegen globaal automatisch vervangen