Commit Graph

51091 Commits

Author SHA1 Message Date
Jonathan G Rennison
704eac8220 Fix changing font zoom level not updating font height cache 2021-06-10 21:37:27 +01:00
Jonathan G Rennison
6936fe4f6e Settings GUI: Move day length factor to environment section 2021-06-10 21:23:32 +01:00
Jonathan G Rennison
a7d8c6fe0c Add PF setting for whether to pathfind up to back of one-way PBS 2021-06-09 20:43:57 +01:00
Jonathan G Rennison
d8d01276c5
Merge pull request #266 from telk5093/jgrpp
Update: Korean translation for v0.41.3
2021-06-08 20:10:59 +01:00
TELK
56e261e904 Update: Korean translation for v0.41.3 2021-06-08 12:00:03 +09:00
Jonathan G Rennison
fb8ef7dc93 Version: Committing version data for tag: jgrpp-0.41.3 2021-06-07 20:45:50 +01:00
Vít Šefl
a73ddf4a35 Fix: Do not send vehicles towards incomplete PF nodes
YAPF could end up in a situation where it sets the best intermediate node
to a node whose construction is never finalized (i.e. it is never added to
the open list). The content of the node would be overwritten in the next
round, potentially sending the vehicle to an unwanted location.

(cherry picked from commit 0125ba82e8)
2021-06-07 18:37:06 +01:00
Patric Stout
ab74800b8e Change: by default, make "unload all" leave stations empty (#9301)
(cherry picked from commit 7648483364)
2021-06-07 18:36:35 +01:00
glx22
da8d18d052 Change: Unhide Ctrl effect for group replace protection
(cherry picked from commit e99352a5d9)
2021-06-07 18:32:13 +01:00
Vít Šefl
073b15f453 Fix: Encountering two-way red signals could prune unrelated branches.
The intermediate node branch is now only pruned if the node is on the
path leading to the two-way red signal.

(cherry picked from commit 33d99d27f4)
2021-06-07 18:31:24 +01:00
Michael Lutz
5be60d03a9 Fix: [OpenGL] Increase timeout when waiting for the GPU to be done with the drawing buffer.
The old timeout could be too short if v-sync was on on lower refresh rates.

(cherry picked from commit 97722931a9)
2021-06-07 18:28:10 +01:00
rubidium42
26bcb7762f Fix: part of a tile might not be marked dirty upon terraforming
(cherry picked from commit eaa3df1e8e)
2021-06-07 18:26:24 +01:00
Patric Stout
2b5ff44020 Fix #9281: acquire a company uses special bookkeeping to make you rich (#9300)
When you buy-out a company, you got your shares back. This is
based on company-value, which includes values for the vehicles etc.
In other words, you not only got the vehicles, but you also got
paid to get them back.

Additionally, you also got the loan of the company, but not the
money for the loan (as that is subtracted from the company-value).

Solve this by changing the rules of a buy-out: don't sell your
shares, get the loan AND the balance and get the infrastructure.

(cherry picked from commit 4d74e51907)
2021-06-07 18:26:03 +01:00
rubidium42
cf95cb2639 Fix #9316, 64eddaeb: at about 250.000 inhabitants the bridge length limit check overflows
(cherry picked from commit 4613ababd3)
2021-06-07 18:25:20 +01:00
Jonathan G Rennison
c0bb428e9e Fix vehicle sprites not being updated when moving viewport
When move is instantaneous and old and new viewport rects do not overlap
2021-06-07 18:08:51 +01:00
Rubidium
68217b4568 Cleanup: [Fluidsynth] Remove fluid_player_join
The function fluid_player_join in the library is broken beyond compare for the
usecases it was used for (see their #872). It does not wait until it is safe
to delete the player, so it is up to the end user to ensure that.

For OpenTTD we acquire a lock before fluid_synth_write_s16 and we acquire the
same lock in the stop function. So, only one of the functions can be doing its
thing, meaning we do not need to wait for the player to be stopped as it
cannot be doing anything as we prevent that by the lock.

(cherry picked from commit 79fc094c54)
2021-05-30 22:09:54 +01:00
PeterN
d274a81d3f Fix: Apply unscaled padding to Viewport inside WWT_INSET. (#9219)
Since pixel dimensions in SetPadding() are scaled by GUI size, padding for inset viewports was excessive.

Instead, automatically apply padding for WWT_INSET at widget level. This applies to all widgets inside a WWT_INSET, which in all instances is a NWID_VIEWPORT.

(cherry picked from commit 330a305c99)
2021-05-30 22:06:56 +01:00
Jonathan G Rennison
fe64093cc0 Avoid reading non-32bpp sprites twice where possible
Try to avoid unnecessary over-reading
2021-05-30 22:02:14 +01:00
Jonathan G Rennison
f212332359 Inline fast case for random access file byte/word/dword read 2021-05-30 22:02:14 +01:00
Jonathan G Rennison
054c820521 Implement custom sprite detection with new sprite mechanism 2021-05-30 22:02:14 +01:00
rubidium42
2b014ba1d9 Fix fdc11a9: Missing sprite count determined on the wrong file
(cherry picked from commit de940b1dbc)
2021-05-30 22:02:14 +01:00
Rubidium
e227bbaff0 Cleanup: remove the old FIO slot functions
(cherry picked from commit fa6abe1646)
2021-05-30 22:02:14 +01:00
Rubidium
eecf7c8525 Codechange: let NewGRF make use of SpriteFile instead of most of the FIO slot functions
(cherry picked from commit 10e35ca8e4)
2021-05-30 22:02:14 +01:00
Rubidium
6bd12e24d7 Codechange: introduce SpriteFile to be used by the sprite loader instead of the global FIO slot functionality
(cherry picked from commit fdc11a9f94)
2021-05-30 22:02:14 +01:00
Rubidium
04b38dbfca Codechange: lets music make use of RandomAccessFile instead of the FIO slot functions
(cherry picked from commit 0dd339ecd8)
2021-05-30 08:23:50 +01:00
Rubidium
525f6adcd0 Codechange: let NewGRF sounds make use of RandomAccessFile instead of the FIO slot functions
(cherry picked from commit c097bc9d7d)
2021-05-30 08:23:39 +01:00
Rubidium
4b37044ef1 Codechange: use the new RandomAccessFile as backend for the FIO slot functions
(cherry picked from commit b144e56b2c)
2021-05-30 08:21:09 +01:00
Jonathan G Rennison
98e9a3991b Increase RandomAccessFile::BUFFER_SIZE to 4096 2021-05-30 08:14:15 +01:00
Rubidium
e856ca7b69 Add: concept of a RandomAccessFile to replace the FIO slot functions
(cherry picked from commit 8e0b1b5d1a)
2021-05-30 08:11:09 +01:00
Rubidium
2606f5409a Fix: leaking file descriptors
(cherry picked from commit 495d73a67f)
2021-05-30 07:52:55 +01:00
Rubidium
7c4d803265 Fix: memory leak due to assigning result of strdup to a std::string
(cherry picked from commit 296194ad36)
2021-05-30 07:52:46 +01:00
Jonathan G Rennison
bf87578173 Fix #264: Crash before calling SDL_SetTextInputRect with no window focused 2021-05-30 07:38:37 +01:00
rubidium42
62e3bfd684 Fix #9243: [Network] For a dedicated server use a fallback client and server name
Also warn when the client or server name has not been set and provide pointers on how to set them

(cherry picked from commit 0968d009c8)
2021-05-30 06:45:44 +01:00
Jonathan G Rennison
f703e23322 Fix assert fail when ChooseTrainTrack called on disallowed 90 degree turn 2021-05-29 02:22:27 +01:00
Jonathan G Rennison
c0bf8476b1 Tracerestrict: Fix PBS entry signal conditional with signalled tunnel/bridges 2021-05-26 01:26:28 +01:00
Jonathan G Rennison
0579c8755c Add tracerestrict action: No PBS signal back PF penalty 2021-05-25 18:50:36 +01:00
Jonathan G Rennison
112b235b71 Fix name prefix of TraceRestrictNewsControlField enum values 2021-05-25 18:21:24 +01:00
Jonathan G Rennison
f2aa034a58
Merge pull request #261 from telk5093/jgrpp
Update: Korean translation for v0.41.2 + a
2021-05-22 10:07:13 +01:00
TELK
6113fd9bf0 Update: Korean translation for v0.41.2 2021-05-22 12:56:11 +09:00
TELK
81da69e278 Update: Korean translation for STR_CHEAT_TOWN_RATING 2021-05-22 12:56:10 +09:00
Jonathan G Rennison
06d92a97b6
Merge pull request #259 from unbeatable-101/jgrpp
Add installation instructions
2021-05-21 20:43:40 +01:00
Jonathan G Rennison
903ca18c01 Version: Committing version data for tag: jgrpp-0.41.2 2021-05-21 20:18:02 +01:00
Jonathan G Rennison
900a93ac59 Debug: Add sprite dumping to vehicle debug windows 2021-05-21 19:36:19 +01:00
Jonathan G Rennison
6f10b01ba2 Debug: Add general mechanism to dump a sprite group chain 2021-05-21 19:35:22 +01:00
Jonathan G Rennison
12e00624ba Debug: Fix scrollbar count and logged end marker in extra info only mode 2021-05-21 19:16:38 +01:00
Jonathan G Rennison
5d8f459066 Debug: Add button to debug window to log contents to console 2021-05-21 19:00:18 +01:00
Jonathan G Rennison
30409192f0 Fix f5183807: Tree planting scaling on extra large maps 2021-05-21 18:40:10 +01:00
PeterN
f5183807fe Fix #9242: Tree tick handler did not scale by map size. (#9246)
This means that random tree generation density is higher on small maps and lower on large maps. This difference is enough to make the Lumber Mill impractical to use on large maps.

This change skips ticks on maps smaller than 256x256 and increases iterations or shortens the interval on maps larger than 256x256.

(cherry picked from commit b972ed8604)
2021-05-21 18:32:53 +01:00
frosch
c2fce47340 Fix #9256, 12e43c697d: invalid read after free. (#9258)
This also changes ScriptEventVehicleAutoReplaced when replacing wagons:
The event is now only spawned, if the head engine changes, so only if the VehicleID of the consist changes.
Previously replacing wagons spawned an event with OldVehicleID==NewVehicleID.

(cherry picked from commit 5bd8144853)
2021-05-21 18:32:53 +01:00
PeterN
dcb0cc2c52 Fix #9186: Fix incorrect bounding box height causing station sprite glitch. (#9187)
Increased height of small station building bounding box to cover the build rather than just the platform.

(cherry picked from commit ba193f2e23)
2021-05-21 18:29:45 +01:00