* Refactor server counter API to own overflow protection and filter no-op events
Counter modifications now clamp to int bounds server-side and return change
status, allowing command handlers to skip network broadcasts when values
don't actually change.
* Centralize MAX_COUNTERS_ON_CARD and enforce [0, 999] bounds on server
- Move MAX_COUNTERS_ON_CARD to trice_limits.h
- Server clamps values in setCounter() and incrementCounter()
- Client uses clamped comparison to allow recovery from invalid states
- Add tests for clamping behavior
* move incrementCount() implementation from header to cpp
* [Game][Arrows] Split Arrows into ArrowData and ArrowItem
Took 13 minutes
Took 5 seconds
Took 1 minute
Took 26 seconds
* Address comments.
Took 17 minutes
Took 9 seconds
Took 1 minute
* Change check.
Took 3 minutes
* Pass by const reference.
Took 10 minutes
* Remove extra method
Took 2 minutes
---------
Co-authored-by: Lukas Brübach <Bruebach.Lukas@bdosecurity.de>
* [Counters] Split counters into graphics and logic states
Took 22 minutes
* Don't have widget hold pointer to state -> Copy what we need and subscribe to changes.
Took 12 minutes
Took 5 seconds
* Sync value too.
Took 3 minutes
---------
Co-authored-by: Lukas Brübach <Bruebach.Lukas@bdosecurity.de>
* [Player] Stop reaching into graphics_item and emit signals instead for conceded and zoneId
Took 7 minutes
Took 3 seconds
* Add sameValue check.
Took 3 minutes
---------
Co-authored-by: Lukas Brübach <Bruebach.Lukas@bdosecurity.de>
* [Game] Move state fields out of CardItem
Took 1 hour 2 minutes
* Move stuff into .cpp
Took 14 minutes
* Signals pass changed values as params
Took 2 minutes
* Comments.
Took 23 minutes
---------
Co-authored-by: Lukas Brübach <Bruebach.Lukas@bdosecurity.de>
* [Game/Zones] Simple move refactor to differentiate between logic and graphics for zones
Took 21 minutes
* Clean up game/zones/logic folder.
Took 6 minutes
* Adjust tests.
Took 3 minutes
---------
Co-authored-by: Lukas Brübach <Bruebach.Lukas@bdosecurity.de>
* [App/Theme] Palette Editor
Took 1 minute
Took 1 hour 47 minutes
Took 6 seconds
Took 3 minutes
Took 5 minutes
Took 3 minutes
* Add oracle, add palette files and configs.
Took 10 minutes
* Fix a stupid include mistake, thanks IDE
Took 3 minutes
Took 20 seconds
* Includes.
Took 4 minutes
* Fix ampersand not displaying correctly.
Took 14 minutes
* Longer variable names.
Took 10 minutes
Took 5 seconds
* Change ampersand everywhere
Took 23 seconds
* Doxygen properly.
Took 1 minute
* Remove namespace, fold I/O into structs.
Took 12 minutes
* Remove namespace, fold I/O into structs.
Took 33 seconds
* Alphabetize.
Took 35 seconds
* Lint.
Took 49 seconds
* Add a combo box to quick switch settings.
Took 19 minutes
---------
Co-authored-by: Lukas Brübach <Bruebach.Lukas@bdosecurity.de>
* [PictureLoader] Allow saving downloaded images to local storage and not just the QNetworkManager cache.
Took 1 hour 11 minutes
Took 4 seconds
Took 25 seconds
* Give people options from a dropdown.
Took 1 hour 6 minutes
Took 3 seconds
* Simplify directory removal code.
Took 5 minutes
Took 8 seconds
* Merge pull request #8
* Create new category for new settings
* Split off storage settings
Took 47 minutes
Took 4 seconds
* Allow toggling between caching methods.
Took 1 hour 30 minutes
Took 9 seconds
* Adjust settings dialog.
Took 5 minutes
Took 59 seconds
Took 22 seconds
Took 6 seconds
* tr() strings
Took 1 minute
Took 6 seconds
* Readjust layout, default naming scheme.
Took 5 minutes
* Add stretch.
Took 9 minutes
* Make scrollable.
Took 2 minutes
* Add icon.
Took 7 minutes
* Change naming to be uniform.
Took 3 minutes
Took 3 seconds
---------
Co-authored-by: Lukas Brübach <Bruebach.Lukas@bdosecurity.de>
Co-authored-by: RickyRister <42636155+RickyRister@users.noreply.github.com>
* style: Add braces to all control flow statements
Standardize code style by adding explicit braces to all single-statement
control flow blocks (if, else, for, while) across the entire codebase.
Also documents the InsertBraces clang-format option (requires v15+) for
future automated enforcement.
* InsertBraces-check-enabled
* [VDD] Fix minimum size by adding a compact mode to quickSettingsButtons
Took 17 minutes
Took 5 seconds
* Fix and use FlowWidget/FlowLayout
Took 35 minutes
Took 4 seconds
* Set spacings.
Took 12 minutes
* Make VDE tools flow
Took 1 hour 23 minutes
Took 5 seconds
* Squeeze and flow even more.
Took 11 minutes
* Make pushbutton compact.
Took 54 minutes
Took 7 seconds
---------
Co-authored-by: Lukas Brübach <Bruebach.Lukas@bdosecurity.de>
* Refactor vertical card stacking with opt-in overflow for variable zone sizes
Introduce a shared vertical stacking layout system in SelectZone that replaces the old divideCardSpaceInZone() free function with structured layout computation (StackLayoutParams, ZoneLayout, computeZoneLayout).
By default, cards are guaranteed to fit within zone bounds (no overflow). Zones can opt-in to bottom overflow via allowBottomOverflow flag, with sqrt-scaled compression for smooth visual transitions. A clip container mechanism is available for future zones that need visual clipping.
Key changes:
- SelectZone: new layout engine with allowBottomOverflow opt-in; clip container infrastructure for future zones needing visual clipping
- StackZone: uses new layout (no overflow); adds setHeight() for dynamic resizing capabilities
- HandZone: vertical layout delegates to SelectZone's shared stacking
- AbstractCardItem: preserves hover z-value during layout passes; invalidates scene rect on hover exit for proper sibling repainting
- CardZone::onCardAdded made virtual for clip container reparenting
- Zone widths updated to CardDimensions::WIDTH_F * 1.5
* Changed anonymous namespace for static and braced functions
* CI tests re-run
* Pull client networking out of window_main and into remote_connection_controller
Took 2 minutes
* Things.
Took 13 minutes
---------
Co-authored-by: Lukas Brübach <Bruebach.Lukas@bdosecurity.de>
* Utility method to check if a theme is supposed to be in dark or light mode.
Took 22 minutes
Took 4 seconds
* Method is public.
Took 3 minutes
* Add a utility method to check if we're using a built-in theme
Took 3 minutes
Took 3 seconds
* Use built-in theme detection for home screen.
Took 6 minutes
* Re-polish on theme change
Took 2 minutes
* Fetch background on theme change.
Took 4 minutes
Took 6 seconds
* No need to double polish.
Took 4 minutes
* No need to repaint.
Took 32 seconds
* Only repolish visible widgets.
Took 5 minutes
---------
Co-authored-by: Lukas Brübach <Bruebach.Lukas@bdosecurity.de>
* Reload card db and notify enabled sets change on "Manage Sets" dialog save
Took 1 hour 18 minutes
Took 6 seconds
* Extract to method, also notify on "Reload db" and "new sets found"
Took 3 minutes
Took 4 seconds
* Add an "always enable new sets" fuse to "new sets found" dialog
Took 11 minutes
* Always debounce modelDirty() with dirty() timer.
Took 29 minutes
Took 3 minutes
* Performance improvements for settings by not constructing a new settings object on every single set() call (this forced a sync to/from fs but it seems fine to just rely on Qts own periodic sync?)
Took 23 minutes
Took 3 seconds
---------
Co-authored-by: Lukas Brübach <Bruebach.Lukas@bdosecurity.de>
* Do not allow users to remove VDE functionality by closing tabs.
Took 6 minutes
* Set filter toolbar visible on delayed initialization.
Took 5 minutes
---------
Co-authored-by: Lukas Brübach <Bruebach.Lukas@bdosecurity.de>
* Translate cockatrice/cockatrice_en@source.ts in de
100% translated source file: 'cockatrice/cockatrice_en@source.ts'
on 'de'.
* Translate cockatrice/cockatrice_en@source.ts in de
100% translated source file: 'cockatrice/cockatrice_en@source.ts'
on 'de'.
---------
Co-authored-by: transifex-integration[bot] <43880903+transifex-integration[bot]@users.noreply.github.com>
* Fix#6659: Correct logging for bottom-of-library card moves
Cause:
- This issue happens due to logic of moving the card from the top of the
deck being reused when moving from the bottom of the deck, in a way
that makes it impossible to check if the card came from the bottom.
Resolution:
- Updated the logging logic in the client for card moves.
- Added a gRPC parameter ('is_from_bottom') for card moves.
- Updates the server logic to reverse the order of the card move if the
'is_from_bottom' parameter is true.
- Added a test to show the expected behaviour of the fix.
NOTE: While the changes in this patch seem big, this is due to changing
the loop in the moveCard function to a helper function, in order to make
the bug fix change. The only change to the loop was to pass a
variable attribution to the moveCard function because it was redundant
to be in the loop.
* chore: run format on test
* refactor: new way to check if a move is from the bottom of the deck
* refactor: change isFromBottom check to static function
* update comments
Co-authored-by: ebbit1q <ebbit1q@gmail.com>
---------
Co-authored-by: ebbit1q <ebbit1q@gmail.com>