Commit Graph

24988 Commits (c656633bea39d2002330eddee54522c8db542785)
 

Author SHA1 Message Date
Michael Lutz c656633bea Fix #8775: [Win32] Don't create the main window when alt-tabbing back into fullscreen. 3 years ago
Michael Lutz b7a44983b4 Fix: [Win32] Original window size was lost when tabbing in and out of fullscreen. 3 years ago
Patric Stout 74aa934441 Codechange: validate that "max" value of settings fit in their storage
This is an easy mistake to make, so protect us against making such
mistakes, by validating it doesn't happen.
3 years ago
Patric Stout d7a70c67ba Fix: old snow_line_height had a higher maximum value than could be stored
So any old game made with this setting was overflowing anyway;
not really a lot we can do about that now.
3 years ago
Patric Stout a0c298a539 Fix: three max-values for settings could exceed their storage size 3 years ago
Patric Stout abac4b1758
Fix c4df0f95: bootstrap was only showing a black screen (#8788)
The bootstrap has the _switch_mode to SM_MENU, and never leaves
this mode. Neither is it considered a modal window (while in some
sense it really is). So .. we need to add another "draw anyway"
exception, to make sure bootstrap is being drawn.
3 years ago
Limyx826 47e899cf75 Add: Malaysia Ringgit as Currency
Cause why not

*Update the formating
3 years ago
Charles Pigott 64686b53ff Change: Zero out the gameloop timers when the game is paused 3 years ago
Charles Pigott ef5cea0e06 Change: De-limit framerate window's framerate 3 years ago
glx22 cd4c8ecbf3 Add: [Actions] Allow partial cache invalidation on dependencies change 3 years ago
Owen Rudge 838fd61f29 Fix: [OSX] Hide dock when entering fullscreen 3 years ago
translators 02e7bc7e0a Update: Translations from eints
swedish: 4 changes by kustridaren
norwegian (bokmal): 3 changes by buzzCraft
spanish (mexican): 12 changes by absay
korean: 4 changes by telk5093
greek: 85 changes by sntovas
german: 4 changes by MagnumSociety
catalan: 5 changes by J0anJosep
tamil: 16 changes by Ramesh78dev
dutch: 4 changes by rcpaul
polish: 5 changes by pAter-exe
3 years ago
Patric Stout 40505e645a Fix: terraform limit acted random when maxing out per_64k_frames setting
uint32 + uint32 can overflow, so cast it to uint64 first.
3 years ago
Patric Stout 25e5a92286 Fix 9b800a96: (a << 16) is unsigned, so don't remove the cast 3 years ago
Patric Stout 8bc0089fc4
Fix c3dc27e3: put the max-value of fast-forward-speed-limit to within the storage size (#8769) 3 years ago
translators 2545b24118 Update: Translations from eints
czech: 1 change by LubosKolouch
3 years ago
Charles Pigott f30f4b6892 Doc: 1.11.0-beta2 changelog 3 years ago
Patric Stout c3dc27e37e Add: settings to limit your fast-forward game speed
By default this setting is set to 2500% normal game speed.
3 years ago
dP 73fd634209 Fix #6266: Ugly lists in network lobby windows on double/quad interface sizes with custom fonts 3 years ago
Patric Stout 2d9062bfc1 Fix: [Network] don't desync if client leaves before you finish downloading map
When you are downloading a map, all the commands are queued up
for you. Clients joining/leaving is done by the network protocol,
and as such are processed immediately. This means that by the
time you are processing the commands, a client that triggered
it, might already have left.

So, all commands that do something with ClientID, shouldn't
error on an invalid ClientID when DC_EXEC is set, but
gracefully handle the command anyway, to make sure the
game-state is kept in sync with all the clients that did
execute the DoCommand while the now-gone client was still
there.

Additionally, in the small chance a client disconnects between
the server validating a DoCommand and the command being
executed, also just process the command as if the client was
still there. Otherwise, lag or latency can cause clients that
did not receive the disconnect yet to desync.
3 years ago
Patric Stout 13889b6554 Fix: [Network] don't show "server doesn't respond" while in queue
Send all clients in the queue every game-day a packet that they
are still in the queue.
3 years ago
Patric Stout 8d199b1bbc Fix: [Network] send map to next client if current client disconnects
Also terminate creating of the savegame, as the client is gone,
there really is no need for that anymore.
3 years ago
Patric Stout 3677418225 Fix: [Network] also count the person downloading the map in the queue
Strictly seen, there are "N" people -waiting- in front of you
in the queue, but it is nicer to show "N + 1" for the person that
is currently downloading the map. Avoids it showing:
"0 clients in front of you". That just feels a bit off.
3 years ago
Charles Pigott 6b8f9b50b9 Fix: Vehicle list windows did not update when this year's profit changed
Remove caching from vehicle group object. and recalculate it whenever
required instead.
3 years ago
Michael Lutz d79398a1d5 Fix #8763: [OpenGL] Cursor sprite origin can be negative. 3 years ago
Pavel Stupnikov 4fd2eecb8b
Change: Improve console warnings on invalid network commands (#8753) 3 years ago
translators cd756e6f01 Update: Translations from eints
swedish: 60 changes by kustridaren
norwegian (bokmal): 12 changes by buzzCraft
czech: 82 changes by PatrikSamuelTauchim, 1 change by tomas-vl
italian: 86 changes by AlphaJack, 9 changes by federico1564S
german: 16 changes by ebla71
romanian: 10 changes by ALEX11BR
ukrainian: 3 changes by StepanIvasyn
spanish: 1 change by MontyMontana
3 years ago
Michael Lutz 77854d561b Fix: [OpenGL] Don't use OpenGL on MESA software renderers.
Performance in this case is worse than not using OpenGL, so just let
OTTD fall back to a different video driver.
3 years ago
Patric Stout 1b5d1d074e
Fix: [SDL2] set GL attributes to get the best GL context possible (#8759) 3 years ago
frosch dfa141818b Fix: OpenGL cursor did not consider sprite offsets of cursor sprites. 3 years ago
frosch d236c57600 Fix: yet another place where the vehicle-cursor did not account for the interface zoom level. 3 years ago
Michael Lutz ef4cec9382 Fix #8750: [OpenGL] Line drawing did not set proper RGB/mask colours. 3 years ago
glx22 54fb4c04e3 Fix: [CMake] libpng header/library mismatch for macos 3 years ago
Patric Stout fe451b8dc7 Codechange: remove _realtime_tick variable 3 years ago
Patric Stout 853bfc3562 Codechange: replace _realtime_tick with std::chrono for mouse events 3 years ago
Patric Stout 53c28a8ec9 Codechange: [Network] replace _realtime_tick with std::chrono 3 years ago
Patric Stout dc7ba33b51
Fix: don't link to OpenGL with SDL2 as backend; SDL2 dynamically loads it (#8745)
Although for developers this doesn't change anything, for our
linux-generic binary it changes everything. Without this, the
OpenGL dynamic library is dragged in as dependency, and as it
depends on X11, that will be dragged in too. This is not
something we prefer to have, as that won't run on as many
machines as it could.

SDL2 doesn't depend on OpenGL directly, as it tries to load it
in on runtime. If found, it would work in exactly the same way
as if we would link to OpenGL ourselves. As such, this is
the best of both worlds: our linux-generics have less linked
dependencies, and developers won't notice any difference.

As a side-effect, if someone uses linux-generic on a machine
that does not have any OpenGL package installed, it will
gracefully fall back to the default backend of SDL instead.
3 years ago
Patric Stout d068d61f3c
Fix bddfcaef: don't tell twice that a client left because of a timeout etc (#8746)
SendError() notifies all clients of the disconnect. This calls
CloseConnection() at the end, which also notified the clients
of the disconnect. Really no need to do it twice.

The status NETWORK_RECV_STATUS_SERVER_ERROR is only set by
SendError(), so in case that is the status, don't let
ClientConnection() send another notification.
3 years ago
translators af326753a9 Update: Translations from eints
swedish: 1 change by kustridaren
english (us): 15 changes by 2TallTyler
catalan: 1 change by J0anJosep
dutch: 1 change by Afoklala
3 years ago
Michael Lutz 3cbbaa62db Change: Never auto-select an 8bpp blitter unless explicitly allowed by the 'support8bpp' setting. 3 years ago
Patric Stout 9a3dbf3122
Fix 02e770ff: allow estimating CloneVehicle if short on money (#8748)
CheckCompanyHasMoney() was also executed when not using DC_EXEC,
resulting in an error about shortage of money instead of the
estimation.
This mostly is a problem for AI players, as they will have no
way to know how much it would have cost.
3 years ago
Patric Stout d4583fa64c
Fix #8123: trams on half-tiles couldn't find depots (#8738)
Basically, follow_track.hpp contains a fix for half-tiles, but
this wasn't duplicated for when trying to find a depot and in
a few other places. This makes sure all places act the same.
3 years ago
translators 9209807d66 Update: Translations from eints
swedish: 19 changes by kustridaren
german: 1 change by Wuzzy2
slovak: 3 changes by FuryPapaya
3 years ago
Michael Lutz 311df31fb1 Codechange: [OpenGL] Load all OpenGL functions dynamically. 3 years ago
Michael Lutz a0c1a3f736 Codechange: [OpenGL] Simplify loading OpenGL extension functions. 3 years ago
Michael Lutz e1e8cc3851
Fix #8734: [OpenGL] Apply palette remap to cursor sprites. (#8742) 3 years ago
Patric Stout 6a8c461e38 Codechange: [OSX] GameLoop is really more like MainLoop
MainLoop() is used to bootstrap OSX, where later a callback is
done to GameLoop() to execute OpenTTD. All other video drivers
don't need that, so what is in GameLoop is in MainLoop for all
other drivers. This is rather confusing. So, instead, name
GameLoop MainLoopReal to be more in sync with the other drivers.
3 years ago
Patric Stout 67d3c6aa71 Codechange: [Video] move InteractiveRandom() to the VideoDriver 3 years ago
Patric Stout c409f45ddd Codechange: [Video] make the prototype of PollEvent() the same for all drivers
Additionally, call it from the draw-tick.
3 years ago
glx22 70e4845915 Change: [Actions] Use only CMake, CTest and CPack 3 years ago