Commit Graph

24264 Commits

Author SHA1 Message Date
frosch
252376ce3e Codechange: Rename DrawRoadAsSnowDesert to DrawRoadAsSnowOrDesert to be consistent with other functions. 2025-04-18 16:33:26 +02:00
frosch
26db4ccf09
Codechange: Turn bit-stuffed FiosType enum into a struct. (#14019) 2025-04-18 15:20:55 +02:00
frosch
b862d4937f
Codechange: Turn custom vehicle spritenums into enum, and use them consistently. (#14022) 2025-04-18 15:19:28 +02:00
Peter Nelson
2c59838acb
Codechange: (re)set multiple bitset flags in one call. (#14017) 2025-04-18 14:07:57 +01:00
frosch
31e716449d
Codechange: Change StationNameInformation to not use macros. (#14020) 2025-04-18 15:06:46 +02:00
frosch
5aed046d11
Fix: [NewGRF] Strange things happened, when using the synchronised tile loop animation trigger for houses. (#14011) 2025-04-17 12:15:49 +02:00
translators
421f202539 Update: Translations from eints
luxembourgish: 103 changes by phreeze83
latvian: 1 change by lexuslatvia
2025-04-17 04:45:26 +00:00
Peter Nelson
1f83ea41fc
Fix: [NewGRF] PrepareLayout worked on a copy of the data resulting in bad sprite layouts. (#14013) 2025-04-16 21:27:36 +00:00
Peter Nelson
378ea52ac6 Codechange: Use EnumBitSet for CzechChooseFlags. 2025-04-16 19:44:28 +01:00
Peter Nelson
ea0817390f Codechange: Use EnumBitSet for CzechAllowFlags. 2025-04-16 19:44:28 +01:00
Peter Nelson
6ea10edef8
Codechange: Use std::unique_ptrs for handling station cargo display. (#14009)
Replaces manual management of raw pointers.
2025-04-16 19:43:45 +01:00
Peter Nelson
a281ac4674 Codefix: Information for NewGRF specs remained duplicated after loading.
After loading airports+tiles, industries+tiles, houses and objects, their specs are copied from the NewGRF's loading storage to the final global storage.

Instead, move the specs to the their new storage, and clear the NewGRF's storage once done. (Stations and RoadStops are different, and the NewGRF's storage is the final storage location.)
2025-04-16 19:43:07 +01:00
Peter Nelson
f9ab492e64 Codechange: Pass HouseSpec by reference to IsHouseSpecValid(). 2025-04-16 19:43:07 +01:00
translators
b57f3262ec Update: Translations from eints
spanish: 101 changes by MontyMontana
2025-04-16 04:44:48 +00:00
Peter Nelson
fa0814e257
Codefix: Codestyle consistency fixes. (#14008) 2025-04-15 20:57:13 +00:00
frosch
03ed59a004 Codechange: Turn AnimationStatus into an enum class. 2025-04-15 20:42:44 +02:00
frosch
47f0f4dd9e Fix: [NewGRF] Animation speed properties of houses and stations had wrong default. 2025-04-15 20:42:44 +02:00
frosch
301b209b87
Fix: [NewGRF] Roadstop animation/randomisation was not triggered on vehicle arrival. (#14003) 2025-04-15 14:53:29 +02:00
translators
5fad689782 Update: Translations from eints
norwegian (bokmal): 1 change by eriksorngard
2025-04-15 04:44:48 +00:00
Peter Nelson
5008568dfc
Codechange: Rename CenterBounds to CentreBounds and move to geometry header. (#14002) 2025-04-14 23:55:40 +01:00
frosch
d2c9828b4c Codechange: Move IsUtf8Part to only file using it. 2025-04-14 18:56:23 +02:00
frosch
588fedb5db Codechange: Remove unused Utf8Consume, Utf8Decode, Utf8EncodedCharLen. 2025-04-14 18:56:23 +02:00
frosch
bf8a241f69 Codechange: Parse translation files using StringConsumer. 2025-04-14 18:10:14 +02:00
frosch
b27fd83ff1 Codechange: Parse translation strings using StringConsumer. 2025-04-14 18:10:14 +02:00
frosch
b81a35ea89 Codechange: Use StringConsumer and Builder in StrMakeValid and StrValid. 2025-04-14 18:07:23 +02:00
frosch
dc21fae18e Codechange: Add InPlaceReplacement to couple StringConsumer and Builder on the same buffer. 2025-04-14 18:07:23 +02:00
frosch
f5ffd4789b Codechange: Use StringConsumer in FormatString. 2025-04-14 16:57:41 +02:00
frosch
15a17d832f Codechange: Use StringConsumer in HandleNewGRFStringControlCodes. 2025-04-14 16:57:41 +02:00
frosch
98efd3c96e Codefix #13872: Use StringConsumer in TranslateTTDPatchCodes. 2025-04-14 16:57:41 +02:00
John Taylor
069edc1a4b
Fix #13954: Plotting graphs with limited data to the right. (#13956) 2025-04-14 16:57:07 +02:00
translators
3dacf46870 Update: Translations from eints
vietnamese: 7 changes by KhoiCanDev
2025-04-14 04:44:46 +00:00
Peter Nelson
d48bc18721
Codechange: Rename badge_class to class_index and badge_classes to gui_classes internally. (#13995)
These names are already used in some places, so this brings a bit of consistency.
2025-04-13 21:06:09 +01:00
frosch
131b7c7122 Codechange: Replace Utf8Decode usages with StringConsumer. 2025-04-13 21:59:10 +02:00
frosch
9bcd3feb17 Codechange: Make SQFile a buffered reader, based on StringConsumer. 2025-04-13 21:59:10 +02:00
frosch
3964d053b5 Codechange: Replace BufState with StringConsumer. 2025-04-13 21:59:10 +02:00
frosch
96eee0e8e4 Codechange: Base ByteReader on StringConsumer. 2025-04-13 21:59:10 +02:00
frosch
800d6e339d Codechange: Add StringConsumer. 2025-04-13 21:59:10 +02:00
Peter Nelson
4721a1f93e
Fix: Don't display badges if the class has no name. (#13994)
Unnamed badges are intended to be for internal-use, not for player information.

Additionally if there is no name to the class, then is causes problems when user configuration comes.
2025-04-13 18:00:41 +01:00
frosch
7157e96664
Remove: Drop support for UCS2/UTF-16 encoded scripts. (#13992) 2025-04-13 15:52:01 +02:00
frosch
7f82b181da
Add #12939: [NewGRF] Add road-/tram-/rail-type variable 0x45 to get mutual road-/tram-/rail-type on same tile. (#13934) 2025-04-13 13:23:10 +02:00
translators
04c41bf731 Update: Translations from eints
galician: 63 changes by pvillaverde
2025-04-13 05:04:53 +00:00
Richard Wheeler
a93087ec5c
Fix #13980: Allow diagonal selection for road convert (#13983)
Fixes #13980
2025-04-12 18:50:11 +01:00
Kuhnovic
319a657454
Fix 42fbcec76f: Fixed accidental changes to autorail/road AI behavior (#13968)
* Revert 4bd72e4a78, Fix #11528: Starting autorail dragging from existing track tiles resulted in adding non-continuous tracks.

* Fix 4bd72e4a78: Fixed accidental changes to autorail/road AI behavior
2025-04-12 16:09:10 +02:00
Peter Nelson
34b1f7a992
Fix: Make GrfMsg() behave like Debug() when not loading NewGRFs. (#13991)
GrfMsg() outputs the currently loading NewGRF and current line/sprite number. This is invalid when not NewGRFs are not actually being loaded.
2025-04-12 13:05:33 +01:00
Peter Nelson
1744156149
Change: Queue content ID information requests. (#13990)
Instead of requesting content one ID at a time, queue them up to be requested in one go.

* Avoids sending many small requests.
* Avoids sending requests for content which is likely to be arriving anyway.
2025-04-12 12:50:36 +01:00
translators
c29ef5cfc2 Update: Translations from eints
english (us): 1 change by 2TallTyler
2025-04-12 04:44:34 +00:00
Peter Nelson
3347919fb2 Codechange: Remove empty destructor and use member init for ClientNetworkContentSocketHandler. 2025-04-11 23:08:59 +01:00
Peter Nelson
20d83677eb Codechange: Use unique_ptr to manage ContentInfo lifetime.
Removes manually managed new/delete.
2025-04-11 23:08:59 +01:00
Peter Nelson
7b31f26611 Codechange: Pass ContentInfo by reference.
Many functions take a ContentInfo pointer, but do not check for nullptr.
Pass by reference instead to assure it is present.
2025-04-11 23:08:59 +01:00
frosch
1cfad1474a Codechange: Rename _cur to _cur_gps. 2025-04-11 22:11:28 +02:00
frosch
e89be12ebb Codechange: Rename _library to _ft_library. 2025-04-11 22:11:28 +02:00
frosch
b0d678e375 Codechange: Rename _ignore_restrictions to _ignore_industry_restrictions. 2025-04-11 22:11:28 +02:00
frosch
c9c9973884 Codechange: Rename _circle_size to _setting_circle_size. 2025-04-11 22:11:28 +02:00
frosch
35cd05b27d Codechange: Rename _current_data to _current_gamestrings_data. 2025-04-11 22:11:28 +02:00
frosch
ae51308615 Codechange: Remove unused extern declarations. 2025-04-11 22:11:28 +02:00
frosch
e2ebf3a0f3 Codechange: Move global strgen state into a single struct. 2025-04-11 22:11:28 +02:00
Peter Nelson
786893a844
Fix: NewGRF Global variables 0D, 0E and 1E refer to wrong GRFFile. (#13986)
These variables used GrfProcessingState, which is only valid while loading GRFs, after which they always point to the last loaded GRFFile.
2025-04-11 19:53:05 +02:00
translators
eaa2afda5e Update: Translations from eints
dutch: 1 change by Afoklala
2025-04-11 13:06:07 +00:00
translators
cbbbf6cccc Update: Translations from eints
french: 7 changes by Athozus
2025-04-11 04:46:01 +00:00
Peter Nelson
413087df9d
Codechange: Use small function to get check handler for content type. (#13988)
This reduces a long switch block with (multiple) breaks with the power of early return.
2025-04-10 20:45:43 +00:00
Peter Nelson
936d78fefc
Codefix: Avoid uppercase characters in variable names. (#13985) 2025-04-10 07:19:27 +01:00
translators
59aceee887 Update: Translations from eints
chinese (simplified): 6 changes by WenSimEHRP
catalan: 1 change by J0anJosep
portuguese: 2 changes by azulcosta
2025-04-10 04:47:16 +00:00
Peter Nelson
c982816c0e Codechange: Manage window viewport via unique_ptr. 2025-04-09 22:03:23 +01:00
Peter Nelson
8275bbfb87 Codechange: Pass Viewport by reference.
This means we do not have to care what type of pointer is used.
2025-04-09 22:03:23 +01:00
Peter Nelson
70b4beb8e7 Codechange: Return screenshot viewport instead of using out parameter. 2025-04-09 22:03:23 +01:00
Peter Nelson
f57065dd41 Codefix: Avoid using override keyword as variable names.
Rename variables named `override`.
2025-04-09 22:02:35 +01:00
Peter Nelson
91ab7f10cd Codefix: Avoid using override keyword as member name.
Rename `GRFFileProps` `override` member to `override_id`.
2025-04-09 22:02:35 +01:00
frosch
294f826364 Codechange: Replace last usage of Utf8CharLen with Utf8View. 2025-04-09 17:19:11 +02:00
frosch
9229956f04 Codechange: Replace strcasestr with StrContainsIgnoreCase. 2025-04-09 17:19:11 +02:00
frosch
14bab7d76b Codechange: Remove unused Utf8TrimString, Utf8PrevChar. 2025-04-09 17:19:11 +02:00
translators
b1582b815c Update: Translations from eints
english (au): 1 change by krysclarke
chinese (simplified): 1 change by WenSimEHRP
greek: 1 change by gh658804
russian: 1 change by Ln-Wolf
finnish: 1 change by hpiirai
portuguese (brazilian): 1 change by pasantoro
polish: 4 changes by pAter-exe
2025-04-09 04:46:50 +00:00
frosch
9dc751ed8a Codechange: Remove now unused Utf8Encode. 2025-04-08 23:10:58 +02:00
frosch
fa284af263 Codechange: Replace remaining Utf8Encode usages with StringBuilder. 2025-04-08 23:10:58 +02:00
frosch
5878db1d02 Codechange: Replace strgen Buffer with StringBuilder. 2025-04-08 23:10:58 +02:00
frosch
9b87f306ca Fix: StringFilter included quotes in the search and failed. 2025-04-08 23:10:58 +02:00
frosch
1d879f3043 Codechange: Use StringBuilder to create the gender-scan-string. 2025-04-08 23:10:58 +02:00
frosch
dd073eb38d Codechange: Use StringBuilder to create encoded strings. 2025-04-08 23:10:58 +02:00
frosch
128e0fcde2 Codechange: Use StringBuilder in TranslateTTDPatchCodes. 2025-04-08 23:10:58 +02:00
frosch
ad8e9634ec Codechange: Generalize StringBuilder. 2025-04-08 23:10:58 +02:00
frosch
f306f9726c Codechange: If modifying already written data in a StringBuilder, do this via the underlying std::string. 2025-04-08 23:10:58 +02:00
frosch
c5a43e705c Codechange: Simplify Original English townname generator. 2025-04-08 23:10:58 +02:00
frosch
04246c530f
Codechange: Use fmt::format instead of stringstream with iomanip flags. (#13964) 2025-04-08 20:57:50 +00:00
Peter Nelson
5b9d171e63
Codechange: Use EnumBitSet for StringValidationSettings. (#13974) 2025-04-08 21:19:17 +01:00
Richard Wheeler
4e4f413913
Fix: Capitalise "Disabled" for the "maximum non-sticky open windows" setting. (#13975) 2025-04-07 19:33:09 +02:00
frosch
3f2b58d6e1
Fix: Validate raw strings from game-scripts, and strip invalid and control characters. (#13976) 2025-04-07 19:30:36 +02:00
frosch
2cdf2bedfa
Codechange: Add a std::string overload for StrMakeValidInPlace() and a moving std::string&& overload for StrMakeValid(). (#13962) 2025-04-07 18:22:47 +02:00
Peter Nelson
981b2a94db
Codechange: Store loaded GRFFiles in vector directly. (#13940)
Removes pointer management.
2025-04-06 20:16:57 +01:00
Loïc Guilloux
49ce7fe169
Fix 8846f347f2: Check bridge/tunnel transport type before querying road type (#13969) 2025-04-06 15:01:23 +02:00
translators
bc78efeec1 Update: Translations from eints
catalan: 9 changes by J0anJosep
2025-04-06 04:48:09 +00:00
Peter Nelson
2a47afad89
Fix d94d421772: Frame widget with label had incorrect spacing. (#13967)
Caused by the frame widget not testing GetStringForWidget properly.
2025-04-05 19:12:42 +01:00
translators
5e1dc081ee Update: Translations from eints
chinese (simplified): 3 changes by WenSimEHRP
hindi: 1 change by NisheshTyagi
2025-04-05 04:43:45 +00:00
Peter Nelson
68fd949a52
Fix 44984f8410: Changing ownership of a tunnel/bridge did not check for road transport type. (#13963)
Changing ownership changed ownership of road components without checking if the tunnel/bridge is actually a road tunnel/bridge.
2025-04-04 17:11:19 +00:00
SamuXarick
4310d7c7f5
Fix: [Script] Only run the Game::GameLoop() in-game (#13896) 2025-04-04 17:29:48 +02:00
Kuhnovic
4bd72e4a78
Fix #11528: Starting autorail dragging from existing track tiles resulted in adding non-continuous tracks. (#13885) 2025-04-04 15:21:04 +00:00
Loïc Guilloux
f35fa6679b
Change: [Script] Start GS (but don't run it) when generating world in scenario editor (#13961) 2025-04-04 12:52:02 +02:00
frosch
8846f347f2
Fix: MayHaveRoad claimed rail station tiles had road, so the custom stationspec index would be read as roadtype. (#13949) 2025-04-04 11:49:10 +02:00
frosch
cedc511324
Fix: Numbers were left-aligned for RTL languages in several windows. (#13959) 2025-04-04 11:48:50 +02:00
frosch
44984f8410
Codechange: Remove broken and unused StrMakeValidInPlace overload. (#13960)
If an otherwise valid string without NUL termination was passed, a NUL was appended out of bounds.
2025-04-04 11:48:32 +02:00
translators
1befa1ccb0 Update: Translations from eints
chinese (simplified): 119 changes by WenSimEHRP
2025-04-04 04:46:26 +00:00
John Taylor
7c1649d524
Fix #13955: Make graphs respect RTL (#13957)
Co-authored-by: John Taylor <gitea@johntaylor.hu>
Co-authored-by: frosch <frosch@openttd.org>
2025-04-03 21:17:34 +02:00
Loïc Guilloux
b25daba561
Fix: [Script] Reset instance when changing running scripts in scenario editor (#13906) 2025-04-03 21:14:45 +02:00
frosch
20805ba84b Codechange: Use EncodeUtf8 and DecodeUtf8 directly, when dealing with a single character. 2025-04-03 18:43:41 +02:00
frosch
f640daee4c Codechange: No need for Utf8Consume and Utf8Encode, if only ASCII characters are checked. 2025-04-03 18:43:41 +02:00
frosch
f06bfc0dad Codechange: Use Utf8View to const-iterate over strings, if no particular error handling is needed. 2025-04-03 18:43:41 +02:00
frosch
22ab0244d8 Codechange: Use Utf8View in Textbuf. 2025-04-03 18:43:41 +02:00
frosch
f19e75b606 Codechange: Use Utf8View in Utf8StringLength. 2025-04-03 18:43:41 +02:00
frosch
83401ad5e2 Codechange: Use Utf8View::iterator in StringIterator. 2025-04-03 18:43:41 +02:00
frosch
b19e43ae99 Add: Utf8View and iterator. 2025-04-03 18:43:41 +02:00
frosch
e6a0cf75a9 Codechange: Shift suffixes between _name_czech_adj and _name_czech_patmod to simplify code. 2025-04-03 13:58:07 +02:00
frosch
d8333fe3d7 Codechange: Czech town names unconditionally removed the last codepoint in _name_czech_adj; already do this in the source table. 2025-04-03 13:58:07 +02:00
frosch
86bb30acbe
Codefix dccc6185: Incorrect encoding of empty parameters in ScriptText. (#13951) 2025-04-03 13:57:30 +02:00
frosch
061b5630ee
Codefix: Conversion from char to char32_t requires cast to unsigned first. (#13950) 2025-04-03 13:56:50 +02:00
stormcone
ced8fd9936
Fix: Reference to the correct section of the README, if a graphics or a sound set is incomplete. (#13946) 2025-04-03 13:40:16 +02:00
Peter Nelson
33a8c1c6fc
Codechange: Use default operator<=> to compare Linkgraph Hop. (#13944) 2025-04-02 23:00:06 +01:00
John Taylor
2f36e3e3a1
Fix #13075, #13893: Reversed all x-axis labels for company related and industry production graphs in wallclock mode. (#13894) 2025-04-02 19:04:49 +02:00
Loïc Guilloux
827b03a32c
Fix: [Script] Prevent cloning of API instances (#13947) 2025-04-02 12:30:57 +02:00
Peter Nelson
2ae84f3c9e
Codechange: CargoSpec::Iterate already tests cargo validity. (#13941) 2025-04-01 18:23:26 +01:00
stormcone
8d0ba5649a
Fix 667d0137: NewGRF details view does not show the "No information available", if the NewGRF sets an empty description. (#13939) 2025-04-01 16:10:59 +02:00
stormcone
f8f76eb9f3
Fix 089c7a2: SDL2 application name hint was not effective. (#13926) 2025-04-01 16:07:38 +02:00
Rubidium
3c15e0c889 Codefix: return right type to prevent casting 2025-03-31 21:44:53 +02:00
Rubidium
023bf38338 Codefix: std::string_view does not accept nullptr 2025-03-31 21:44:44 +02:00
Peter Nelson
e200e9b401
Codechange: Use EnumBitSet for Linkgraph RefreshFlags. (#13930) 2025-03-31 20:33:32 +01:00
Peter Nelson
047497734b
Cleanup: Remove redundant NewGRF clean up functions. (#13927)
These functions no longer clean up manually managed memory, they simply clear GRFFile's vectors of unique_ptrs. This will happen anyway when the GRFFile is deleted.
2025-03-31 20:33:09 +01:00
Peter Nelson
6a3d17923b
Codechange: Use range filter to simplify picking a random AI. (#13897) 2025-03-31 20:32:16 +01:00
frosch
dc956a758d
Fix: Draw the bevel around the music track name as inset. (#13935) 2025-03-31 18:54:02 +02:00
frosch
fe50f061a9
Fix #13923: Padding in music GUI was asymmetric, so it looked different for LTR and RTL languages. (#13933) 2025-03-31 18:53:51 +02:00
frosch
6c569f36e6
Fix #13925, 667d0137: Ancient NewGRF have empty name and description, show the filename instead. (#13932) 2025-03-31 14:25:47 +02:00
translators
0055e168f0 Update: Translations from eints
chinese (traditional): 7 changes by KogentaSan
vietnamese: 1 change by KhoiCanDev
2025-03-31 04:46:08 +00:00
Loïc Guilloux
dc3e8a07e6
Fix #13928, 35e58f6: BuildOilRig did not properly set airport rotation (#13929) 2025-03-30 22:33:01 +00:00
Peter Nelson
99c6e85356
Codefix: Timetable display rows are not related to OrderID. (#13909) 2025-03-30 20:25:55 +01:00
Michael Lutz
68ff7e5209 Fix #13921, d95422561b: [Win32] Don't try close an already closed event handle during destruction. 2025-03-30 19:01:45 +02:00
Michael Lutz
56af0b29f5 Fix #13921, a908c7bed0: Don't reject MIDI files with a valid file magic value. 2025-03-30 19:01:45 +02:00
translators
cc18f586f9 Update: Translations from eints
chinese (traditional): 1 change by KogentaSan
vietnamese: 11 changes by KhoiCanDev
chinese (simplified): 10 changes by WenSimEHRP
french: 2 changes by ottdfevr
2025-03-29 04:46:36 +00:00
Peter Nelson
319caef58f
Fix #13912: Multitile buildings break apart in house picker. (#13914)
As this is drawing sprites, use sprite-based scaling instead of interface-based scaling.
2025-03-28 20:30:52 +00:00
Peter Nelson
0829604b4f
Fix #13908: Require double click on order to change stop location. (#13913) 2025-03-28 20:23:18 +00:00
Peter Nelson
e49150f9ca
Fix #13910: Invalidate content of house picker window if language is changed. (#13911) 2025-03-28 19:57:43 +00:00
Peter Nelson
a361841848
Codechange: Store GameStrings as shared_ptr. (#13905)
Uses shared_ptr/weak_ptr as LanguageScanner needs access without ownership.
2025-03-28 17:44:43 +00:00
Peter Nelson
d95422561b Codechange: Use unique_ptr to manage drivers. 2025-03-28 17:44:07 +00:00
translators
c3457cd4c0 Update: Translations from eints
hungarian: 3 changes by vargaviktor
ukrainian: 10 changes by imlystyi
2025-03-28 04:44:47 +00:00
Peter Nelson
529fb88325 Codechange: Use template specialisation and instantiation for BaseMedia methods.
Specialisations seem to be the correct way to specialise, rather than redefining the base template.

This removes a macro which instantiated methods individually.
2025-03-27 18:57:53 +00:00
Peter Nelson
3375dc3095 Codechange: Use traits to define BaseSet parameters. 2025-03-27 18:57:53 +00:00
Peter Nelson
6914d99778 Codechange: Split baseset type definitions into separate files. 2025-03-27 18:57:53 +00:00
Peter Nelson
9feaa6b7bc
Codechange: Use vector/unique_ptr to manage network game information. (#13902)
Replaces linked list with manual memory management.
2025-03-27 18:48:41 +00:00
Peter Nelson
0b3619ea35
Codechange: Use unique_ptr to manage blitters. (#13904) 2025-03-27 08:38:58 +00:00
translators
65cabf4c87 Update: Translations from eints
ukrainian: 39 changes by imlystyi
2025-03-27 04:46:01 +00:00
Loïc Guilloux
6bf405eb18
Codechange: Remove Game::GetGameInstance() (duplicate of Game::GetInstance()) (#13901) 2025-03-26 22:41:41 +00:00
Peter Nelson
ff08a22aa4
Codechange: Simplify AI/GameConfig::GetConfig. (#13900)
Reorganise these methods to reduce nesting and remove a raw pointer to a unique_ptr.
2025-03-26 21:53:05 +00:00
Peter Nelson
325f7f9767
Codechange: Use EnumBitSet for GoodsEntry status. (#13899) 2025-03-26 21:22:33 +00:00
Peter Nelson
5331389765
Codechange: Pass NewsItem by reference. (#13898) 2025-03-26 18:56:33 +00:00
Peter Nelson
422ff9dbd8 Codechange: Use std::unique_ptr for ai/game config. 2025-03-26 10:54:11 +00:00
Peter Nelson
7f3820fa7e Codechange: Load check data is only interested in landscape and starting_year. 2025-03-26 10:54:11 +00:00
translators
df750d44fd Update: Translations from eints
latvian: 53 changes by lexuslatvia
2025-03-26 04:44:20 +00:00
Björn Wärmedal
d009bfc47b
Codechange: Add vehicle owner to crash event (#13878)
Co-authored-by: Björn Wärmedal <bjorn.warmedal@lumera.com>
2025-03-25 22:53:44 +01:00
Peter Nelson
fb008436b8
Codechange: Use std::unique_ptr for script info/library instances. (#13892) 2025-03-25 21:07:02 +00:00
Peter Nelson
47d078c033 Codechange: Use EnumBitSet for RailTypes. 2025-03-25 20:15:48 +00:00
Peter Nelson
732109e444 Codechange: Use EnumBitSet for RoadTypes. 2025-03-25 20:15:48 +00:00
Peter Nelson
819e097d6e Codechange: Use separate RoadTypes mask to list road or tram roadtypes.
This simplifies logic reduces ambiguity.
2025-03-25 20:15:48 +00:00
frosch
c105adcd96
Codechange: Encode case/gender/plural choice lists without null termination, only length prefix. (#13876) 2025-03-25 20:32:40 +01:00
frosch
25005cff16
Codefix: std::string_view::data() is not necessarily null terminated. (#13891) 2025-03-25 20:32:19 +01:00
Peter Nelson
93016b9a92
Fix #13842: Close industry production graph if industry is removed. (#13890) 2025-03-25 17:58:59 +00:00
Peter Nelson
9f94cadd68
Codefix: GRF-local cargo id is not a CargoType. (#13888) 2025-03-25 17:12:43 +00:00
Peter Nelson
adb20f99ea
Fix: Autoreplace rail/road list only listed buildable types. (#13887)
Instead list all possible types which includes hidden types compatible with buildable types.
2025-03-25 08:22:30 +00:00
translators
1fb4c44bc7 Update: Translations from eints
chinese (traditional): 20 changes by KogentaSan
hungarian: 61 changes by vargaviktor
2025-03-25 04:47:17 +00:00
Peter Nelson
79ef4e98fe
Codechange: Use std::swap() instead of Swap() (#13883) 2025-03-24 23:47:34 +00:00
Peter Nelson
8a53ccf8f1
Fix: Not enough parameters supplied for Autoreplace window caption. (#13886) 2025-03-24 23:01:04 +00:00
frosch
488cda728d Codechange: Use std::string and std::string_view instead of C strings. 2025-03-24 23:10:13 +01:00
frosch
d7768f5f51 Codechange: Use more specific integer types than 'int'. 2025-03-24 23:10:13 +01:00
frosch
b10433715d Codechange: Turn out parameters into return values. 2025-03-24 23:10:13 +01:00
frosch
77af1c89c8 Codechange: Split _show_todos into individual bool flags. 2025-03-24 23:10:13 +01:00
frosch
f8292a8d11 Codechange: Remove unused/obscure strgen feature for relative offsets in plural/gender choice lists. 2025-03-24 23:10:13 +01:00
frosch
4fc0900865 Codechange: Reorder functions in strgen and reduce external symbols. 2025-03-24 23:10:13 +01:00
Peter Nelson
b96b26ef15
Codechange: Rename short CargoType parameters cargo. (#13848)
Rename CargoType variables and parameters using short or meaningless names.
2025-03-24 18:18:21 +00:00
Loïc Guilloux
bdea29c414
Fix #13875: [Script] be less strict about empty constructor format for doxygen (#13882) 2025-03-24 13:38:10 +01:00
translators
997f8abaec Update: Translations from eints
chinese (traditional): 23 changes by KogentaSan
2025-03-24 04:46:50 +00:00
Peter Nelson
fc7b6c6cbb
Codechange: Use .fill() to clear an array instead of assigning a new array. (#13880)
Avoids allocating a temporary on the stack.
2025-03-23 22:09:45 +00:00
frosch
ca801d55d5
Fix: [NewGRF] Display an error, if NewGRF reference out-of-bounds string parameters in gender/plural choices. (#13881) 2025-03-23 20:43:12 +01:00
Peter Nelson
42eb513897
Codechange: Make use of emplace_back's return value. (#13879) 2025-03-23 18:34:04 +00:00
frosch
5aa4ad5135
Codechange: Pass unformatted strings from GetStringPtr as std::string_view. (#13871) 2025-03-23 19:23:31 +01:00
Peter Nelson
234c9fb3bd Codechange: Use EnumBitSet for SpriteFlags. 2025-03-23 18:01:02 +00:00
Peter Nelson
5abe7c1386 Codechange: Use default initialisation for 32bpp_sse2's SpriteData.
Avoids using memset.
2025-03-23 18:01:02 +00:00
Peter Nelson
828e808444 Codechange: Split NewGRF loader into separate Action handlers. 2025-03-23 16:59:36 +00:00
Peter Nelson
0b7fa11a5b Codechange: Move NewGRF string mapping to own file. 2025-03-23 16:59:36 +00:00
Peter Nelson
2cb389946d Codechange: Move GrfProcessingState to separate file.
Allows reuse by other files.
2025-03-23 16:59:36 +00:00
Peter Nelson
fe9dfa2b08 Codechange: Move NewGRF ByteReader to own file. 2025-03-23 16:59:36 +00:00
frosch
84f785b06b
Codechange: Pass GRF name as std::string to UpdateNewGRFScanStatus. (#13870) 2025-03-23 16:58:43 +01:00
Peter Nelson
8b4114d709
Fix #13849: Settings in old saves could be overridden by defaults. (#13874)
Resolved by resetting settings to default values before the OPTS and PATS chunks are loaded.
2025-03-23 15:55:55 +00:00
Peter Nelson
21d2a94809
Codechange: Use EnumBitSet for GrfMiscBits. (#13873) 2025-03-22 21:07:59 +00:00
frosch
af49320637
Fix: [NewGRF] Plurals and genders did not work in strings with cases. (#13853) 2025-03-22 21:41:27 +01:00
frosch
d4ae0f70da
Codechange: StringFilter now uses std::string_view entirely (#13869) 2025-03-22 20:35:31 +01:00
frosch
667d013726
Codechange: Return name, description and URL as std::string from GRFConfig. (#13868) 2025-03-22 20:30:40 +01:00
John Taylor
ae2d7947d7 Fix #13562: Removed cost estimation message from money cheat 2025-03-22 20:28:55 +01:00
Jonathan G Rennison
be79099a6f
Codechange: Use a std::span as input for GfxFillPolygon (#13866)
Instead of a std::vector const reference.
2025-03-22 15:16:14 +00:00
frosch
5764eaaacf
Fix: [NewGRF] Plurals and genders did not work in NewGRF substrings, and cases in substrings could mess up cases in the parent string. (#13852) 2025-03-22 13:40:43 +01:00
translators
7abca5bb25 Update: Translations from eints
hungarian: 77 changes by vargaviktor
2025-03-22 04:46:31 +00:00
Peter Nelson
e47082bf7b
Codefix: Don't look up NewGRF Action 6-modified data twice. (#13863) 2025-03-21 18:13:31 +00:00
frosch
a4f3ddae5f
Fix: [NewGRF] String parameter stack and case selection were not processed for control code 0x81. (#13851) 2025-03-21 18:13:08 +01:00
Peter Nelson
a4f9977d18
Codechange: Don't reimplement DistanceManhattan. (#13850) 2025-03-21 17:06:39 +00:00
Peter Nelson
6297b49a00 Codechange: Remove table/strings include from header files.
This was accidentally providing coverage to basically all source files...
2025-03-21 12:53:40 +00:00
Peter Nelson
3503082f19 Codechange: Move template class implementation includes.
These are now placed at the bottom of the including files include list.
2025-03-21 12:53:40 +00:00
Peter Nelson
2909a14374 Codechange: Include table/strings.h in files that use StringIDs.
Be consistent with how and where the file is incldued.
2025-03-21 12:53:40 +00:00
Peter Nelson
edb101d12f Codechange: Use free function get BaseSet list label.
This avoids using StringIDs in a header file.
2025-03-21 12:53:40 +00:00
Peter Nelson
762e2f76a3 Codechange: Avoid STR_NULL in header file. 2025-03-21 12:53:40 +00:00
Peter Nelson
4ffbf97770 Codechange: Move RawText::GetEncodedText() out of header.
This allows it to use StringID without polluting includes.
2025-03-21 12:53:40 +00:00
frosch
3b178bf58d Fix: NewGRF string interpolation did not process all string parameters, if certain string control codes were present.
String control codes with inline data may contain null characters, in particular plural/gender/case choice lists.
2025-03-21 11:03:24 +01:00
frosch
5d291317e7 Codechange: Two very different functions were named RemapNewGRFStringControlCode. 2025-03-21 11:03:24 +01:00
translators
a678bb263d Update: Translations from eints
hungarian: 32 changes by vargaviktor
2025-03-21 04:45:21 +00:00
Peter Nelson
89948b941b
Codechange: Use emplace_back instead of push_back. (#13855) 2025-03-20 17:39:10 +00:00
Peter Nelson
b98a7ff303
Fix f214c81e97: Signed overflow in collision test on large map when road vehicles are at just the right coordinates. (#13847)
If road vehicles are -32768 subtiles apart, the distance check will break.
2025-03-18 22:53:01 +00:00
Richard Wheeler
4ba69765be
Update: Developer credits (#13846)
<3
2025-03-18 20:57:25 +00:00
Rubidium
a908c7bed0 Codechange: remove uses of MemCmpT (and MemMoveT) 2025-03-18 21:18:37 +01:00
Loïc Guilloux
e55f54ce08
Fix #13843, 015c081c: Don't discard GetString() result (#13844) 2025-03-18 17:15:40 +00:00
Peter Nelson
17f7d0950e
Fix #13838: Formatted error message of sub-errors may be lost. (#13840) 2025-03-18 08:39:40 +00:00
Peter Nelson
5255aabe4d
Fix #13839: Incorrect colour of first company legend in smallmap window. (#13841)
Use the proper command to set the initial company colour.
2025-03-17 20:28:02 +00:00
translators
ff275b805b Update: Translations from eints
welsh: 144 changes by Ansbaradigeidfran
catalan: 6 changes by J0anJosep
2025-03-17 04:46:50 +00:00
Rubidium
5ea5855677 Codechange: use std::move over copying where applicable 2025-03-16 17:33:06 +01:00
Rubidium
f214c81e97 Codechange: simplify some complicated logic 2025-03-16 15:12:02 +01:00
Rubidium
d6a1a0b058 Codechange: simplify logic and prevent invalid bit 2025-03-16 14:14:21 +01:00
Rubidium
b4e5b12047 Codechange: remove unneeded locking from SmallStack 2025-03-16 14:13:51 +01:00
Rubidium
ec647975ad Cleanup: remove ancient FIXME comments 2025-03-16 05:42:29 +01:00
Rubidium
2b9c94f55a Fix: don't show owner of non-existent road 2025-03-16 05:42:29 +01:00
Peter Nelson
3b004c57bc
Codechange: Use EnumBitSet for AdminUpdateFrequency. (#13819) 2025-03-15 21:18:20 +00:00
Koen Bussemaker
8d4639e525 Fix: Error message window timeout doesn't match setting 2025-03-15 22:08:19 +01:00
Rubidium
ccca7fc2b4 Codechange: remove unused INVALID_TRACK_BIT 2025-03-15 22:03:17 +01:00
enveeed
b0cc56a8b5
Fix: NewGRF vehicles display loading sprites when not actually loading or unloading (#13554) 2025-03-15 16:58:47 -04:00
rubidium42
2fed4b0059
Codechange: simplify code (#13822) 2025-03-15 21:49:07 +01:00
Rubidium
c13226cdf8 Codefix: do not leave pointers to stack allocations in globals 2025-03-15 21:46:43 +01:00
Rubidium
dae788e2e3 Codefix: do not trust allocation sizes coming from a file 2025-03-15 21:44:40 +01:00
Rubidium
f794ee028b Codefix: potential division by zero in midi reader 2025-03-15 21:44:18 +01:00
Rubidium
6d0ba270d2 Codefix: do not use an invalid iterator 2025-03-15 21:43:56 +01:00
Rubidium
24f79d2ab7 Codefix: wrong type for choice list mapping 2025-03-15 21:43:18 +01:00
Rubidium
cf96a97e95 Codefix: remove unneeded looping logic 2025-03-15 21:42:28 +01:00
Peter Nelson
62b8b93476 Codechange: Add default initialisation for Rect to remove MemSetT. 2025-03-15 20:09:38 +00:00
Peter Nelson
c905472650 Codechange: Use std::array for vehicle sorting/grouping options to remove MemSetT. 2025-03-15 20:09:38 +00:00
Peter Nelson
653e886d26 Codechange: Use std::array in OpenGLSprite to remove MemSetT. 2025-03-15 20:09:38 +00:00
Peter Nelson
a87b804386
Fix #13760: Store encoded error message inside CommandCost. (#13764)
Encoded error message was previously static to avoid memmory allocation, however this causes complications.
2025-03-15 20:09:11 +00:00
frosch
0cd87bc8c1
Fix: Don't add chars with unspecified signedness to pointers. (#13828) 2025-03-15 18:48:26 +01:00
frosch
4f63340f8d
Codechange: Replace a raw pointer with std::optional. (#13809) 2025-03-15 16:52:12 +01:00
SamuXarick
f6b0f7848b
Add: [Script] Newer Cargo Classes (#13779) 2025-03-15 16:51:56 +01:00
Loïc Guilloux
c5ec8fb05f
Fix #13814, 2824e790: A Set() became Reset() preventing initial sorting of lists (#13816) 2025-03-14 21:15:42 +01:00
Rubidium
ac2087a3eb Codefix: remove some logically dead code 2025-03-14 16:26:21 +01:00
frosch
dbea968f4f
Codefix 20e57a02a2: String parameters were off by one. (#13810) 2025-03-14 15:22:30 +01:00
Peter Nelson
bd5d47836d
Codechange: Use EnumBitSet for EdgeUpdateMode. (#13808) 2025-03-14 09:01:10 +00:00
translators
8191f39649 Update: Translations from eints
chinese (traditional): 11 changes by KogentaSan
spanish (mexican): 5 changes by absay
2025-03-14 04:43:31 +00:00
Charles Pigott
bcabc3b780
Codechange: Upgrade fmt to 11.1.4 (#13807) 2025-03-13 21:52:47 +00:00
Rubidium
18e1440947 Codefix: move or pass by reference instead of copy 2025-03-13 21:16:16 +01:00
Rubidium
754311a779 Codechange: use std::move when appropriate 2025-03-13 13:00:24 +01:00
SamuXarick
05ce0828c0
Change: Use max of calculated and minimal heights in ScriptLeagueWindow (#13720) 2025-03-13 08:39:26 +00:00
Peter Nelson
8b39b23d2b
Codechange: Use EnumBitSet for VehicleFlags. (#13793) 2025-03-13 08:38:54 +00:00
Björn Wärmedal
dc343ca141
Fix: GenerateCompanyName sends incorrect renaming event (#13794) 2025-03-13 08:24:35 +00:00
translators
70c2a666bc Update: Translations from eints
spanish (mexican): 7 changes by absay
czech: 39 changes by adamek0202
2025-03-13 04:45:10 +00:00
Rubidium
2b88f58384 Codefix: add move operators to SQObjectPtr 2025-03-12 22:05:02 +01:00
Rubidium
35ef197be4 Codefix: potential integer overflow before widening integer 2025-03-12 22:00:44 +01:00
Rubidium
02f1bc0880 Codefix: remove some logically dead code 2025-03-12 22:00:33 +01:00
Rubidium
8f3bfb61bd Codefix: remove structurally dead code 2025-03-12 21:03:55 +01:00
Rubidium
d96f359b3c Codefix: potential dangling pointer in strgen 2025-03-12 20:59:47 +01:00
Rubidium
0fde979b21 Codefix: check for errors in the function getting the socket error 2025-03-12 17:55:34 +01:00
Rubidium
486ad7d416 Codefix: check curl_easy_setopt executes properly, or show a debug message 2025-03-12 17:55:34 +01:00
Rubidium
32b2de36ef Codefix: check the table header is actually being read 2025-03-12 17:55:34 +01:00
Rubidium
649ed702cc Codefix: potential unintended sign extension 2025-03-12 17:03:35 +01:00
translators
cdcc6b491d Update: Translations from eints
spanish (mexican): 9 changes by absay
2025-03-12 04:46:00 +00:00
Peter Nelson
3336f13a63
Fix #13795: size_t mayn't be the same size as uint64_t. (#13796) 2025-03-11 17:55:33 +00:00
translators
40ddc03423 Update: Translations from eints
spanish (mexican): 62 changes by absay
2025-03-11 04:44:39 +00:00
Peter Nelson
3eb89f04b5
Codechange: Use EnumBitSet for QueryStringFlags. (#13792) 2025-03-10 18:59:35 +00:00
Peter Nelson
1a53b48422
Codechange: Use EnumBitSet for PartsOfSubsidy. (#13791) 2025-03-10 18:59:21 +00:00
Peter Nelson
8ba86c54b1
Add: Show hyperlink destination tooltips in text window. (#13742) 2025-03-10 18:12:42 +00:00
Loïc Guilloux
c6cd1a4bca
Fix #13740: [Script] Handle implicit orders for jump orders (#13753) 2025-03-10 15:12:26 +01:00
Loïc Guilloux
59904e5f9b
Fix #13749: Apply callback when automatically changing timekeeping unit (#13751) 2025-03-10 14:55:19 +01:00
Rubidium
5721030bd2 Codefix: use Pool::Get if you know it's valid, especially if you don't check GetIfValid for nullptr 2025-03-10 12:46:29 +01:00
Rubidium
3c7506e07d Codefix: TrackdirCrossesTrackdirs does not work for turning RV TrackDirs 2025-03-10 12:46:03 +01:00
Rubidium
0d902c9f5c Codefix: possible out-of-bounds array indexing 2025-03-10 07:09:49 +01:00
translators
cb3d3878fa Update: Translations from eints
swedish: 6 changes by joeax910
spanish (mexican): 5 changes by absay
greek: 17 changes by gh658804
2025-03-10 04:40:22 +00:00
Rubidium
2926dd2c2f Codefix: do not dereference the std::end() iterator 2025-03-09 23:33:25 +01:00
Rubidium
afe66c7df4 Codefix: std::move string leaves the old one in an undefined state 2025-03-09 22:19:54 +01:00
Peter Nelson
7c97460080
Codechange: Use EnumBitSet for ConsistChangeFlags. (#13788) 2025-03-09 21:13:57 +00:00
Peter Nelson
de45f5418b
Fix 0de7fd3c24: widget_lookup may contain non-NWidgetCore widgets. (#13787) 2025-03-09 19:49:26 +00:00
Rubidium
2000cea235 Codechange: initialise instance members 2025-03-09 20:41:03 +01:00
Rubidium
0de7fd3c24 Codefix: check the result of dynamic_cast for nullptr 2025-03-09 19:35:14 +01:00
Rubidium
d07d75229b Codefix: data race in case of a spurious wake up 2025-03-09 19:34:47 +01:00
Richard Wheeler
1eddd7fed0 Fix: Improve manager face randomisation 2025-03-09 19:22:25 +01:00
Rubidium
ee45c8ec1d Codefix: do not pass invalid file descriptor to fdatasync 2025-03-09 19:10:33 +01:00
Jonathan G Rennison
61e8dcfca7
Cleanup: Remove unused DepotCommandFlag::LocateHangar flag (#13775) 2025-03-09 18:07:47 +00:00
Peter Nelson
52bada216c Codechange: Use std::array for vehicle hashes.
This allows initialisation without memset.
2025-03-09 18:03:50 +00:00
Peter Nelson
ec71f7a216 Codechange: Use std::array for temporary NewGRF loading data.
This allows initialisation without memset.
2025-03-09 18:03:50 +00:00
Peter Nelson
761c587940 Codechange: Use std::array to store most-used railtype.
This allows initialisation without memset.
2025-03-09 18:03:50 +00:00
Peter Nelson
61aa45071a
Codechange: Use EnumBitSet for SigFlags. (#13784) 2025-03-09 18:01:52 +00:00
Peter Nelson
572f2801ac
Codechange: Use emplace_back instead of back_inserter. (#13781)
This silences a warning produced by gcc.
2025-03-09 17:42:00 +00:00
translators
62a571c892 Update: Translations from eints
swedish: 89 changes by joeax910
norwegian (bokmal): 51 changes by eriksorngard
chinese (traditional): 1 change by KogentaSan
spanish (mexican): 195 changes by absay
chinese (simplified): 1 change by WenSimEHRP
finnish: 1 change by hpiirai
2025-03-09 04:38:41 +00:00
Rubidium
a23dda7ffe Codechange: use const auto & instead of making a copy 2025-03-08 21:33:17 +01:00
Peter Nelson
91d22f7617
Codechange: Use EnumBitSet for VehStates. (#13755)
Renamed from VehStatus because pluralising that is weird.
2025-03-08 18:24:21 +00:00
Rubidium
0b102db421 Codefix: initialise a few uninitialised variables 2025-03-08 18:01:25 +01:00
Rubidium
8a243f7391 Fix: [Script] Getting expiry date could cause out of bounds access 2025-03-08 16:14:18 +01:00
Rubidium
cfa31849be Fix: company livery window's instance variables were not set 2025-03-08 16:14:08 +01:00
Peter Nelson
f8478cdee4
Fix 51fd2853cb: Different news widget layouts require different font sizes. (#13752) 2025-03-08 12:00:56 +00:00
translators
a154df6549 Update: Translations from eints
norwegian (bokmal): 18 changes by eriksorngard
spanish (mexican): 48 changes by absay
czech: 1 change by LubosKolouch
danish: 15 changes by bscargo
dutch: 22 changes by Afoklala
portuguese: 1 change by azulcosta
2025-03-08 04:38:53 +00:00
Peter Nelson
794317e870
Fix #13758: Owned by error message consumed too many parameters. (#13762) 2025-03-07 23:36:18 +00:00
Peter Nelson
2c211630cb
Fix #13759: Really don't set error owner to OWNER_TOWN. (#13761) 2025-03-07 23:35:28 +00:00
translators
49c760a472 Update: Translations from eints
spanish (mexican): 41 changes by absay
korean: 21 changes by telk5093
italian: 1 change by quasimagia
latvian: 11 changes by lexuslatvia
2025-03-07 04:44:48 +00:00
Peter Nelson
3fde611012
Codechange: Use EnumBitSet for AirportMovingDataFlags. (#13754) 2025-03-06 19:03:41 +00:00
translators
84f093fc72 Update: Translations from eints
english (au): 8 changes by krysclarke
chinese (traditional): 5 changes by KogentaSan
spanish (mexican): 14 changes by absay
english (us): 2 changes by 2TallTyler
chinese (simplified): 4 changes by WenSimEHRP
greek: 2 changes by gh658804
russian: 14 changes by Ln-Wolf
finnish: 2 changes by hpiirai
portuguese: 2 changes by azulcosta
portuguese (brazilian): 2 changes by pasantoro
polish: 2 changes by pAter-exe
2025-03-06 04:44:52 +00:00
Peter Nelson
274b7a0195
Fix #13645: "Follow vehicle" button not raised when following stopped. (#13746) 2025-03-06 00:00:57 +00:00
Peter Nelson
47ae285c9d
Fix 2d7d085e8e: Autorenew failed error string consumed too many parameters. (#13750) 2025-03-05 22:50:33 +00:00
frosch
72ddac02bd Codechange: Add plural genders by duplicating the singular ones 2025-03-05 20:49:27 +01:00
frosch
4b93a5240b Codechange: Example usage of plural genders 2025-03-05 20:49:27 +01:00
frosch
273bcf008b Codechange #13709: Update gender definitions for Spanish (es_ES and es_MX) 2025-03-05 20:49:27 +01:00
Peter Nelson
6d631d7a13
Fix f8b1e30: Fix recent savegames may have incorrect EngineFlags saved. (#13745)
Detect and update engines saved with invalid EngineFlags.
2025-03-05 17:58:03 +00:00
Loïc Guilloux
0ade7638df
Fix #13668, fd2949d: Include the \0 in TextBuf max_chars cropping (#13672) 2025-03-05 12:05:19 +01:00
Loïc Guilloux
7723625823
Fix #13729, f8b1e30: Incorrect conversion of EngineFlags to EngineFlag (#13743) 2025-03-05 09:12:06 +00:00
translators
0cfcc07ee6 Update: Translations from eints
chinese (traditional): 8 changes by KogentaSan
spanish (mexican): 36 changes by absay
english (us): 19 changes by 2TallTyler
chinese (simplified): 5 changes by WenSimEHRP
greek: 6 changes by gh658804
finnish: 6 changes by hpiirai
french: 63 changes by glx22
portuguese: 5 changes by azulcosta
portuguese (brazilian): 6 changes by pasantoro
polish: 6 changes by pAter-exe
2025-03-05 04:44:13 +00:00
Peter Nelson
51fd2853cb
Fix 6e10584b91: Keep custom news from game scripts in encoded form. (#13741)
This allows the news message to translated as appropriate.
2025-03-04 23:15:50 +00:00
Peter Nelson
b979f0414c Codechange: Prevent nested encoded strings. 2025-03-04 21:40:39 +00:00
Peter Nelson
b55af05626 Codechange: Pass encoded script strings as EncodedString.
This removes the ambiguity of having std::strings that may or may not be encoded.
2025-03-04 21:40:39 +00:00
Peter Nelson
2a05a845df Feature: Snow-covered rocks are now visible. 2025-03-04 20:39:08 +00:00
Peter Nelson
28a1267e57 Change: Adjust costs for clearing snowy landscape tiles.
Rocks with snow is no longer cheaper to clear than rocks without snow.
2025-03-04 20:39:08 +00:00
Tyler Trahan
6acbc775e5
Fix #13725: Use proper query strings for changing timetable values (#13737) 2025-03-04 11:58:28 -05:00
Peter Nelson
8a09bb8127
Fix #11226: Don't draw story page elements that won't be visible. (#13736)
When drawing the story page elements, all of them were drawn even if they are not visible. This can be a significant performance hit for long strings.
2025-03-04 13:38:37 +00:00
Peter Nelson
27761ae431 Cleanup: Remove global string parameters.
Global parameters, and functions for dealing with them, are now gone.
2025-03-04 08:48:35 +00:00
Peter Nelson
e818fcbf19 Codechange: Allow encoded strings to use as many parameters as necessary. 2025-03-04 08:48:35 +00:00
Peter Nelson
37b276b4b5 Cleanup: Remove STR_JUST_STRING2/4. 2025-03-04 08:23:28 +00:00
Peter Nelson
a1bcfb836a Codechange: Remove leftover SetStringTips. 2025-03-04 08:23:28 +00:00
Peter Nelson
e10e96b9d5 Codechange: Drop default widget strings for autoreplace window. 2025-03-04 08:23:28 +00:00
Peter Nelson
3d95a7813f Codechange: Drop default widget strings for AI config window. 2025-03-04 08:23:28 +00:00
Peter Nelson
ab0d6e8b95 Codechange: Drop default widget strings for network windows. 2025-03-04 08:23:28 +00:00
Peter Nelson
d7963f6eb7 Codechange: Drop default widget strings for NewGRF debug window. 2025-03-04 08:23:28 +00:00
translators
72a6d27252 Update: Translations from eints
english (au): 13 changes by krysclarke
chinese (traditional): 15 changes by KogentaSan
spanish (mexican): 2 changes by absay
chinese (simplified): 2 changes by WenSimEHRP
greek: 13 changes by gh658804
finnish: 2 changes by hpiirai
portuguese: 31 changes by jcteotonio, 2 changes by azulcosta
portuguese (brazilian): 1 change by pasantoro
polish: 5 changes by pAter-exe
2025-03-04 04:44:36 +00:00
Peter Nelson
4e485cd083
Fix: Network relay question used string parameters unconventionally. (#13734) 2025-03-04 00:25:15 +00:00
Peter Nelson
ed65fea7dd
Codechange: Move to GetWidgetString for help window. (#13733) 2025-03-03 23:32:08 +00:00
Rubidium
c9624cef7c Codechange: remove MallocT, CallocT and ReallocT 2025-03-04 00:10:01 +01:00
Loïc Guilloux
0d4346c8dc
Fix #13727, bdd1406: Incorrect ls.vehicle_names size for TTO saves (#13732) 2025-03-03 22:59:57 +00:00
Peter Nelson
aec1046d19 Codechange: Drop default widget strings for goal window. 2025-03-03 22:47:07 +00:00
Peter Nelson
3757d8affe Codechange: Drop default widget strings for league window. 2025-03-03 22:47:07 +00:00
Peter Nelson
d587426912 Codechange: Drop default widget strings for story window. 2025-03-03 22:47:07 +00:00
Peter Nelson
c7d6934816 Codechange: Move to GetWidgetString for town windows. 2025-03-03 22:34:22 +00:00
Peter Nelson
92e4ef7e77 Codechange: Move to GetWidgetString for toolbar windows. 2025-03-03 22:34:22 +00:00
Peter Nelson
e81884ab31 Codechange: Move to GetWidgetString for timetable window. 2025-03-03 22:34:22 +00:00
Rubidium
3880cc1b57 Codechange: swap x/y axes for dirty blocks around 2025-03-03 23:25:24 +01:00
Rubidium
ec1b9e53f4 Codechange: use std::vector over ReallocT for dirty blocks 2025-03-03 23:25:24 +01:00
Peter Nelson
92b723cb4e
Fix #13723: Invalid string parameters for build airport window. (#13724) 2025-03-03 22:17:54 +00:00
Peter Nelson
94c6221dff
Fix edf9f597ec: Screenshot with non-wallclock date saved with wrong filename. (#13721) 2025-03-03 21:44:48 +00:00
Peter Nelson
deb3755acb Codechange: Move to GetWidgetString for waypoint window. 2025-03-03 21:24:18 +00:00
Peter Nelson
a65db3be0d Codechange: Move to GetWidgetString for viewport window. 2025-03-03 21:24:18 +00:00
Peter Nelson
e1f9159b51 Codechange: Move to GetWidgetString for vehicle windows. 2025-03-03 21:24:18 +00:00
Peter Nelson
d58eb15a0f Fix #13706, Fix #13717: Replace single new line with double new line in precomposed errors. 2025-03-03 21:23:45 +00:00
Peter Nelson
92fa1b4444 Codechange: Move to GetWidgetString for station windows. 2025-03-03 21:23:13 +00:00
Peter Nelson
09806d6f9b Codechange: Move to GetWidgetString for smallmap window. 2025-03-03 21:23:13 +00:00
Peter Nelson
8f62e40bc7 Codechange: Move to GetWidgetString for sign windows. 2025-03-03 21:23:13 +00:00
Peter Nelson
3d253a9702 Codechange: Move to GetWidgetString for settings windows. 2025-03-03 21:23:13 +00:00
Peter Nelson
7a9a3ef94a Codechange: Move to GetWidgetString for script windows. 2025-03-03 21:23:13 +00:00
Peter Nelson
c7846f4629 Codechange: Move to GetWidgetString for road windows. 2025-03-03 21:20:14 +00:00
Peter Nelson
039b5a2662 Codechange: Move to GetWidgetString for rail windows. 2025-03-03 21:20:14 +00:00
Peter Nelson
ee07790a87 Codechange: Move to GetWidgetString for osk window. 2025-03-03 21:19:44 +00:00