Commit graph

14661 commits

Author SHA1 Message Date
Corantin H ad07be1492 Fix wrong array indexing in undo action label (fixes #8135)
`Result` was not the correct variable to use to index the operation names array, instead it should be what is returned from the selection popup.
2024-03-21 18:25:48 +01:00
Dennis Felsing 21d0d69bec
Merge pull request #8133 from dobrykafe/pr-more-settings
Include more options in appearance settings
2024-03-20 22:43:28 +00:00
dobrykafe 2a31ff1998 include more options in settings 2024-03-20 23:20:04 +01:00
Dennis Felsing f169899083 serverbrowser: communities->servers instead of communities->icon->servers 2024-03-20 12:28:41 +01:00
Robert Müller c9439eac36
Merge pull request #8102 from archimede67/editor-fix-save-missing-layers
Editor: allow saving empty quads & sounds layers
2024-03-18 22:13:34 +00:00
archimede67 95402b9559
Merge pull request #8126 from Robyt3/Engine-LineReader-UTF8-Check
Ensure line reader only returns lines which are valid UTF-8, refactoring
2024-03-18 21:19:37 +00:00
Corantin H a5a4d50237 Allow saving empty quads & sounds layers 2024-03-18 22:06:26 +01:00
Robert Müller 2a99c81721
Merge pull request #8123 from archimede67/editor-fix-autorules-crash
[Editor] Fix crash when trying to select autorule with arrow keys
2024-03-18 20:41:06 +00:00
Robert Müller 010d4dc673 Remove unnecessary UTF-8 check for config variables
Invalid UTF-8 will not be read from config files with `CLineReader` anymore and the local console never allowed entering invalid UTF-8, so this additional mangling of invalid UTF-8 string config variable values is unnecessary.
2024-03-18 21:29:43 +01:00
Robert Müller e0e6bbbbe2 Minor cleanup of CLineReader
- Use `nullptr` instead of `0`.
- Use `\0` instead of `0`.
- Move variable declaration.
2024-03-18 21:29:41 +01:00
Robert Müller 0f94d0d72c Ensure line reader only returns lines which are valid UTF-8
Skip lines containing invalid UTF-8 in `CLineReader::Get` function.
2024-03-18 21:29:34 +01:00
heinrich5991 3f70ae4b70
Merge pull request #8115 from Robyt3/Client-Mapimages-Refactoring
Various refactoring of `CMapImages`
2024-03-18 00:08:30 +00:00
Corantin H d506dc4fa9 Support navigating in selection popups with arrow keys 2024-03-17 19:44:12 +01:00
Corantin H 72029e4105 Prevent switching layer selection while popup is open 2024-03-17 15:35:32 +01:00
archimede67 47d77fad07
Merge pull request #8120 from Robyt3/UI-Color-Picker-Line-Improvement
Support clicking line color picker label to toggle checkbox
2024-03-17 10:56:31 +00:00
Robert Müller d7f3c4fb6d
Merge pull request #8118 from dobrykafe/pr-nameplates-strong
`ClNameplatesStrong` improvements
2024-03-17 10:43:24 +00:00
Robert Müller 67329acae9 Support clicking line color picker label to toggle checkbox
Closes #8117.
2024-03-17 11:37:40 +01:00
archimede67 d853a17f20
Merge pull request #8119 from Robyt3/UI-String-Fix
Fix replacement of `UI` with `Ui` in strings
2024-03-17 10:33:28 +00:00
Robert Müller bef399f296 Fix replacement of UI with Ui in strings 2024-03-17 11:16:14 +01:00
dobrykafe 19ea53998f show nameplates strong indicator from perspective of spectated player 2024-03-17 11:13:44 +01:00
dobrykafe 7f4974616a fix nameplates strong indicator 2024-03-17 11:11:51 +01:00
Robert Müller d57a2d490e Extract IsValidTile function 2024-03-17 10:48:08 +01:00
Dennis Felsing f3c246f622
Merge branch 'master' into pr_ddnet_http_age_crash 2024-03-16 23:23:35 +01:00
Robert Müller 033b659570 Avoid unnecessary calculations for invalid tiles
Only calculate offsets for valid tiles when the offsets will be used.
2024-03-16 22:33:58 +01:00
Robert Müller f1deec2c84 Rename variables i to ModType and n to LayerType 2024-03-16 22:33:58 +01:00
Robert Müller 29d924e061 Simplify handling of entities paths, remove unnecessary variables 2024-03-16 22:33:57 +01:00
Robert Müller c97c3ac7b1 Extract GetEntitiesModType function 2024-03-16 22:33:57 +01:00
Robert Müller 01daa919e8
Merge pull request #8113 from furo321/eye-emote
Remove `(until you die)` part from `/eyeemote off`
2024-03-16 20:46:43 +00:00
heinrich5991 790c73bffe
Merge pull request #8098 from Robyt3/Graphics-ImageInfo-Free
Replace `IGraphics::FreePNG` with `CImageInfo::Free`
2024-03-16 20:14:02 +00:00
heinrich5991 03aab986fe Fix crash when the serverlist request fails
We're not allowed to look at `ResultAgeSeconds` when the state is
`EHttpState::ERROR`.

Fixes #8107.
2024-03-16 21:12:47 +01:00
furo 7043a59bc3 Remove (until you die) part from /eyeemote off 2024-03-16 21:10:21 +01:00
Robert Müller 11aba0e38d Replace IGraphics::FreePNG with CImageInfo::Free
The engine graphics do not need to be involved with freeing image data.

The `Free` function now also ensures that all other member variables are cleared when freeing the image data.
2024-03-16 20:55:22 +01:00
Robert Müller 722b5f8d11 Comment out verbose serverbrowser HTTP log message
The `unknown address` log message got printed very often because many servers have 0.6 and 0.7 addresses but only 0.6 addresses are considered valid by the client.
2024-03-16 20:54:56 +01:00
Robert Müller 4f4284ba2a Fix typo in serverbrowser HTTP log context 2024-03-16 20:54:56 +01:00
Robert Müller 24caf08d84 Minor refactoring of net_addr_from_url
- Remove unnecessary branch and temporary variable usage at the end of the function.
- Move variable declarations closer to usages.
2024-03-15 18:40:03 +01:00
Robert Müller 6df1d251d7
Merge pull request #7947 from ChillerDragon/pr_coll_tele
Move tele vector init from gamecontroller to collision
2024-03-14 17:02:09 +00:00
Dennis Felsing 681b66b563 Version 18.1 2024-03-14 17:14:07 +01:00
heinrich5991 ff7b6ffe14 Take serverlist age into account when choosing master
Prefer masters with newer server lists, and try re-selecting the chosen
master if the result is older than 5 minutes.
2024-03-14 12:31:41 +01:00
heinrich5991 5603d284bf Parse Date and Last-Modified HTTP headers 2024-03-14 12:31:41 +01:00
heinrich5991 2d17097c91 Use log_* instead of Console()->Log() in HTTP serverbrowser 2024-03-14 11:19:32 +01:00
ChillerDragon 4da4ca5bdd Make tele getters const 2024-03-14 08:50:35 +08:00
ChillerDragon 552d466197 Move tele vector init from gamecontroller to collision 2024-03-14 08:46:22 +08:00
Robert Müller ae9a8fe3d4 Support overlapping scroll regions, always allow mouse scrolling
Support scrolling all scroll regions with the mouse wheel also while popup menus are open. Support overlapping scroll regions by always scrolling the top-most hovered scroll region on mouse wheel events.

The hot scroll region is now tracked separated by `CUi`, as tracking the IDs of all UI elements which are contained in scroll regions is not feasible. The separate active state for scroll regions is therefore unnecessary.

It's still necessary to disable `CListBox`es when popup menus are open, to ensure that only one list box consumes the key events.

Closes #8087. Supersedes #8090.
2024-03-12 22:15:20 +01:00
Robert Müller f291362d88 Revert name of enum literal Ui back to UI
This `enum` literal was accidentally included in the renaming of the `UI` function to `Ui`.
2024-03-12 21:49:00 +01:00
heinrich5991 8108cb04fd Inform HTTP map download of the map size 2024-03-11 17:50:51 +01:00
heinrich5991 dd5ddf07a4 Disconnect when we get map change with invalid parameters
This is the only sane thing we can do, the server will have changed its
map and we can't pretend to still be on the old one.
2024-03-11 17:50:12 +01:00
Dennis Felsing 3489131d78
Merge pull request #8085 from dobrykafe/pr-timecp
Improve `/timecp` chat command
2024-03-11 07:34:54 +00:00
Dennis Felsing 621b201acf
Merge pull request #8086 from furo321/browser-login-filter
Add a `No login required` filter
2024-03-11 07:33:21 +00:00
furo 40f641b0a6 Add a No login required filter 2024-03-11 02:09:16 +01:00
dobrykafe 35c45cf869 improve /timecp chat command 2024-03-11 00:36:07 +01:00