Commit graph

18732 commits

Author SHA1 Message Date
Robert Müller 7a84a746e0 Add CSample::TotalTime function 2023-12-29 12:25:39 +01:00
Dennis Felsing 0f1171a501
Merge pull request #7741 from furo321/translate-racefinish
Use 0.7 translation layer for `Sv_RaceFinish` netmessage.
2023-12-29 08:00:19 +00:00
furo 1a94aa6d8a Use 0.7 translation layer for Sv_RaceFinish netmessage. 2023-12-29 08:33:36 +01:00
Dennis Felsing ee2dd0ac1c
Merge pull request #7740 from Robyt3/UI-Mouse-Clamp
Fix mouse being outside of UI screen on right and bottom edges
2023-12-28 22:33:27 +00:00
Dennis Felsing 54b697e874
Merge pull request #7105 from dobrykafe/pr-restart-button
Add restart button for when game needs to restart to apply settings
2023-12-28 22:25:16 +00:00
dobrykafe 429b0c6fdb add restart button for restart warning label 2023-12-28 22:39:36 +01:00
Robert Müller 018529c683 Fix mouse being outside of UI screen on right and bottom edges
Ensure that the UI mouse position stays inside the UI screen rect. Previously, the mouse was not considered to be inside the UI screen when all the way at the right or bottom edge. This caused the map editor tooltip to not be shown when the mouse is all the way at the right side of the map editor view. This is a cleaner fix for #4553 which reverts the previous workaround from #6423.
2023-12-28 21:23:16 +01:00
Dennis Felsing 3820abaefb
Merge pull request #7739 from Robyt3/Editor-Toolbar-Anim-Grid-Icons
Improve editor toolbar anim and grid buttons, add dropdowns
2023-12-28 18:04:51 +00:00
Dennis Felsing 67181c0e73
Merge pull request #7734 from archimede67/editor-resizeable-layers-panel
Editor: refactor dragbar, allow resize of layers panel
2023-12-28 18:03:24 +00:00
Corantin H ffd7776147 Add cursor types and use resize cursor for dragbars 2023-12-28 18:35:23 +01:00
Corantin H c2ce2c9d1a Refactor editor dragbar, allow resize of layers panel 2023-12-28 18:35:22 +01:00
Robert Müller c9640459e4 Improve editor toolbar anim and grid buttons, add dropdowns
Add dropdown menus for changing animation and grid settings (i.e. animation speed and grid size) instead of conditionally showing more buttons for this directly in the menu bar. This frees up space in the menu bar, which is currently full on 5:4 resolutions.

The icons previously used for the default animation/grid buttons are now used for the main buttons that toggle animation/grid instead of using text.

Support setting lower animation speeds with the plus and minus buttons by adjusting the step size when the animation speed is low.

Support setting arbitrary animation speed by text input.
2023-12-28 17:43:09 +01:00
Dennis Felsing fedad1de6c
Merge pull request #7736 from archimede67/editor-fix-group-pos-props
Editor: fix group position properties not working correctly
2023-12-27 23:23:53 +00:00
Dennis Felsing 02331d1986
Merge pull request #7733 from Robyt3/Textrender-Selection-Quad-Reuse
More efficient text selection rendering
2023-12-27 23:13:49 +00:00
Dennis Felsing e8da11bcf0
Merge pull request #7735 from archimede67/fix-editor-multi-edit-issues
Editor: fix duplicate layers in popup layer context
2023-12-27 23:10:34 +00:00
Corantin H 3d606847fd Fix group position properties not working correctly 2023-12-28 00:03:28 +01:00
Corantin H 83540ade5c Fix duplicate layers in popup layer context
Clear layers from context before adding any layer, preventing layers from being kept in the vector until only a single layer is selected. Fixes #4978.
2023-12-27 23:11:52 +01:00
Robert Müller 72019df288 More efficient text selection rendering
Render one quad for each line of the text selection instead of rendering one quad per selected character.

This increases the average FPS when the console is open and all text is selected by around 10% (from around 849 to around 943 FPS) (on my machine, in release mode).
2023-12-27 21:07:25 +01:00
Dennis Felsing 15e6e5eeab
Merge pull request #7730 from archimede67/editor-fix-picker
Fix broken selection in editor
2023-12-27 17:38:57 +00:00
Dennis Felsing f93573c55a
Merge pull request #7732 from archimede67/editor-fix-append
Editor: improve append (fixes #7625)
2023-12-27 17:38:40 +00:00
Corantin H f3fc85cfbb Improve editor append (fixes #7625)
Fix broken editor append.
Check for image data when image names are identical. In such case, appended image is renamed until its name is unique.
2023-12-27 18:09:39 +01:00
Corantin H b949a7de21 Fix broken selection in editor 2023-12-27 17:41:19 +01:00
Dennis Felsing dfb6967a47
Merge pull request #7722 from archimede67/autocomplete-console-refactor
Refactor argument autocompletion in console
2023-12-27 15:01:06 +00:00
Dennis Felsing a149d28649
Merge pull request #7728 from archimede67/editor-differentiate-cp-tele
Editor: differentiate between normal and checkpoint teles
2023-12-27 14:45:37 +00:00
Corantin H 42771ac42f Refactor argument autocompletion in console
Allows autocompletion of specific argument instead of the first argument only
2023-12-27 15:43:56 +01:00
Corantin H 84c2168650 Differentiate between normal and checkpoint teles 2023-12-27 15:23:57 +01:00
Dennis Felsing 083c8c77bf
Merge pull request #7727 from Robyt3/Graphics-Color-Rounding
Fix color rendering being inconsistent with displayed color values, fix slightly incorrect color components shown in color pickers
2023-12-27 13:22:13 +00:00
Robert Müller 32373c0559 Fix color rendering being inconsistent with displayed color values
When normalizing color components in the engine graphics, round the components to the nearest integer instead of rounding down. Otherwise the color that is rendered in color pickers may be off by 1 in any of its RGB components from the color that the color picker displays as text (hex string and individual components). The slightly incorrect color can be confirmed by creating a screenshot or otherwise reading the backbuffer (planned editor pipette feature).

This should not change map rendering, since maps already store quantized RGBA values on which the rounding mode should have no effect. It may however slightly change appearance of colors in all other places (at most +1 in every RGB component).
2023-12-27 13:49:55 +01:00
Robert Müller 6cc42aa58c Fix slightly incorrect color components shown in color pickers
The individual color components were rounded down when being displayed on their own in color pickers, whereas the components are rounded to the nearest integer when packing the colors into the hex string. This was causing minor discrepancies between the color being displayed/saved as hex and the individual components. Rounding the components when packing is necessary to reduce the error when converting between color spaces.
2023-12-27 13:47:03 +01:00
Dennis Felsing 269f276fee
Merge pull request #7726 from archimede67/allow-panning-outside-container
Editor: allow panning outside initial container
2023-12-27 12:20:34 +00:00
Dennis Felsing e549e67c95
Merge pull request #7725 from archimede67/editor-automap-include-fix
Only include `layer_tiles.h` in `auto_map.cpp`
2023-12-27 12:05:32 +00:00
Corantin H 4e10d55b36 Allow panning outside initial container 2023-12-27 12:57:36 +01:00
Corantin H d3ff602f62 Only include layer_tiles.h in auto_map.cpp 2023-12-27 12:29:25 +01:00
Dennis Felsing 7f5aaec50f
Merge pull request #7724 from Robyt3/Client-MapRender-Text-SetColor-Optimize
Improve performance when rendering map overlay texts
2023-12-27 11:17:13 +00:00
Robert Müller 4c2dfa24db Improve performance when rendering map overlay texts
The text color was previously set and reset for every individual number being rendered for non-empty tele, speedup, switch and tune tiles. The color is the same for all tiles from each entities layer, so most of these `TextColor` calls are unnecessary. Now the text color is only set and reset once when rendering each entities layer.
2023-12-27 11:51:18 +01:00
Dennis Felsing 453bc0f66a
Merge pull request #7720 from MrBlubberBut/patch-2
Fix automatic hammer on release when cl_dummy_control is set to 1
2023-12-27 09:01:45 +00:00
Dennis Felsing 9828da6f3e Fix formatting 2023-12-27 09:45:10 +01:00
Dennis Felsing 751b2a4a93
Merge pull request #7721 from archimede67/editor-better-tele-text
Editor: improve text rendering inside tele tiles
2023-12-27 08:44:04 +00:00
Corantin H fcc095b675 Improve text rendering inside tele tiles in editor 2023-12-27 00:16:44 +01:00
Dennis Felsing 90596e51ee
Merge pull request #7719 from archimede67/editor-adjust-special-tiles-shortcut
Editor: add shortcut to adjust special tiles numbers
2023-12-26 22:13:02 +00:00
Dennis Felsing d23aca47be
Merge pull request #7718 from MrBlubberBut/patch-1
Clarify Windows build process in README.md
2023-12-26 22:12:30 +00:00
Corantin H 166b27fc27 Use ctrl+f when brush is not empty to replace tile numbers with next free 2023-12-26 20:42:42 +01:00
Corantin H 643cdf8717 Add shortcut to change tele, switch and tune number of current brush (#5400) 2023-12-26 20:17:36 +01:00
MrBlubberBut 32e187f18e
Fix automatic hammer on release when cl_dummy_control is set to 1
Let's say you have this bind:

```bind x +toggle cl_dummy_hammer 1 0```

and you set cl_dummy_control to 1.

When you press the bind i mentioned above, and then release, the dummy will hammer where he is looking (not at you). So, in total, there will be two hammers. One hammer when you press down the button and the dummy hammers towards you, and then another hammer when you release the button and the dummy hammers where he is looking.

This fixes it, and also makes sure it does not conflict with cl_dummy_copy_moves (as if it is enabled and cl_dummy_control is enabled, the dummy will not copy fire, hook, or jump) so I made sure it keeps this functionality as it's pretty cool.

This does not fix any other bugs yet, maybe I will fix those in the future but we'll see. Any bug you may encounter with this change is also probably present in the main branch, such as resetonswitch not working perfectly with dummy_control, but if you do find something different then let me know.
2023-12-26 13:59:06 -05:00
MrBlubberBut e7f28f7881
Update README.md
Clarify the build process :)
2023-12-26 13:36:40 -05:00
Dennis Felsing 8ce103f04f
Merge pull request #7717 from archimede67/editor-unused-tiles-popup
Show unused tiles warning popup for all entities layer
2023-12-26 18:29:35 +00:00
Dennis Felsing 53dba33c21
Merge pull request #7715 from infclass/kaffeine/pr
RenderTools: Add const/static method qualifiers
2023-12-26 18:24:25 +00:00
Dennis Felsing 998dcaa393
Merge pull request #7716 from archimede67/quads-qol-buttons-fix
Remove checks when drawing quads QoL buttons
2023-12-26 18:13:53 +00:00
Corantin H e9958aca19 Show unused tiles warning popup for all entities layer 2023-12-26 19:11:36 +01:00
Alexander Akulich 43710fe541 Use CRenderTools::GetRenderTeeOffsetToRenderedTee via class name instead of instance
Fixes clang-tidy warning.
2023-12-26 21:08:50 +03:00