Commit graph

6600 commits

Author SHA1 Message Date
Christian Daniel Jensen
482d2dae28
Merge branch 'Cockatrice:master' into master 2026-11-03 03:39:31 -07:00
Bryce!
9588e1960d
Preserve saved deck formats through database reload and view refresh (#7745) 2026-11-03 11:10:50 +01:00
Bryce!
fd2a99e897
Respect nonempty Qt hints and explain discovery failures [skip ci] (#7733) 2026-11-03 10:41:47 +01:00
Bryce!
dc4aa19d23
Import Moxfield signature spells into the deck [skip ci] (#7751)
Co-authored-by: Codex <codex@openai.com>
2026-11-03 10:40:28 +01:00
Bryce!
ada8f399f1
Log server identification and connection lifecycle (#7731)
* Log remote server identification and connection lifecycle [skip ci]

* Update libcockatrice_network/libcockatrice/network/client/remote/remote_client.cpp

Co-authored-by: RickyRister <42636155+RickyRister@users.noreply.github.com>

---------

Co-authored-by: BruebachL <44814898+BruebachL@users.noreply.github.com>
Co-authored-by: RickyRister <42636155+RickyRister@users.noreply.github.com>
2026-11-03 10:38:54 +01:00
Jurriaan
bc09ec6afe
[Client] Make DeckStateManager::decrementCard remove tokens from the token zone if the token is not in the given zone (#7588)
* Fixed decrementCard for tokens not using the token zone

* Removed dead function actDecrementCard

Updated documentation

* Fixed no-op, added documentation

* Removed stray blank line

* Allow finding card nodes even if no database entry exists for the given card

* Added DeckStateManager tests

* Added tokens on mainboard test

* Added if checks and sorted sources

Added if checks

* Library include fix

* Renamed zone to targetZone

* Revert "Allow finding card nodes even if no database entry exists for the given card"

This reverts commit 88578cd0d9.

* Combined loader_local_matching_test and deck_state_manager_test settings sources

* Added settings sandbox, refactor

* Format

* Renamed return variable

* Flattened if statement

* Style fix
2026-11-03 10:37:17 +01:00
Jurriaan
bfb53c5def
[Client] Visual Deck Editor: Added more mouse click modifiers to add/decrement cards to specific zones (#7589)
* Make visual database mouse click modifiers properly add/decrement different card zones

* Use event->modifiers(), refactor

* Removed QApplication include

* Added visual database display documentation page

* Minor fixes

* Added documentation for the mouse interaction of the table view
2026-11-03 10:35:58 +01:00
PILIX123
381dd21e8c
[Client] Add option to load decks from ManaBox (#7642)
* [Client] Add option to load decks from ManaBox

* [Client] Fix PR comments

* [Client] Fix UI and transaltion requests

* [Client] Fix for UI and parser not doing what expected when loading maybe board

* Add ManaBox support to docs

As pointed out in review comments

* [Client] Fix final PR comments

---------

Co-authored-by: tooomm <tooomm@users.noreply.github.com>
2026-11-03 10:33:21 +01:00
transifex-integration[bot]
c5b776ca46
Translate oracle/oracle_en@source.ts in de (#7767)
100% translated source file: 'oracle/oracle_en@source.ts'
on 'de'.

Co-authored-by: transifex-integration[bot] <43880903+transifex-integration[bot]@users.noreply.github.com>
2026-11-03 10:31:12 +01:00
BruebachL
dd7ee3541c
[PictureLoader] Keep the download log from going quadratic (#7766)
* [PictureLoader] Keep the download log from going quadratic

A fast scrollbar sweep over the visual card database requests a picture for
every cell it paints, so one gesture can ask for thousands of downloads. The
status bar built a seven-widget log entry for each of them and answered every
completion with findChildren() over the whole, unbounded log, rebuilding
url.toString() per child: O(n) per completion, O(n^2) per burst.

Profiling a sweep on master put 47% of all cycles on the GUI thread, with
qt_qFindChildren_helper at 12.4% of the process (a quarter of that thread) and
QWidgetPrivate::reparentFocusChildren at 4.1%. LagMonitor reported stalls of
3-18 s, growing with the backlog.

Keep at most MAX_LOG_ENTRIES entries and index them by URL, so a completion
and the 1 Hz cleanup only visit the matching entries. The progress bar follows
the entries that remain: dropping a finished entry moves both counters back,
dropping a pending one only its maximum. The log is a diagnostic view, not a
queue - the downloads themselves are unaffected.

* fixup! [PictureLoader] Keep the download log from going quadratic

Make the URL index a QMultiHash and say why: a deferred retry re-queues the same URL while its first log entry is still pending, so one URL can back several live entries.

---------

Co-authored-by: Lukas Brübach <Bruebach.Lukas@bdosecurity.de>
2026-11-03 10:17:53 +01:00
BruebachL
44d5138181
[VisualDatabase] Keep the card grid scrolling on macOS (#7764)
Some checks are pending
CodeQL / Analyze (cpp) (push) Waiting to run
CodeQL / Analyze (actions) (push) Waiting to run
Build Desktop / Configure (push) Waiting to run
Build Desktop / vcpkg baseline (push) Waiting to run
Build Desktop / Debian 13 (push) Blocked by required conditions
Build Desktop / Debian 12 (push) Blocked by required conditions
Build Desktop / Fedora 44 (push) Blocked by required conditions
Build Desktop / Fedora 43 (push) Blocked by required conditions
Build Desktop / Servatrice_Debian 12 (push) Blocked by required conditions
Build Desktop / Ubuntu 24.04 (push) Blocked by required conditions
Build Desktop / Ubuntu 26.04 (push) Blocked by required conditions
Build Desktop / Arch (push) Blocked by required conditions
Build Desktop / Ubuntu 26.04 cover (push) Blocked by required conditions
Build Desktop / macOS 13 Intel (push) Blocked by required conditions
Build Desktop / macOS 14 (push) Blocked by required conditions
Build Desktop / macOS 15 (push) Blocked by required conditions
Build Desktop / macOS 26 Debug (push) Blocked by required conditions
Build Desktop / Windows 10 (push) Blocked by required conditions
Build Desktop / Prune caches (push) Waiting to run
Build Docker / Servatrice (arm) (push) Waiting to run
Build Docker / Servatrice (x86) (push) Waiting to run
Build Docker / Publish multi-platform Servatrice image (push) Blocked by required conditions
* [VisualDatabase] Keep the card grid scrolling on macOS

The view ignored the wheel whenever the vertical scroll bar was not
visible. On macOS, scroll bars are transient: once the fade-out finishes,
QScrollbarStyleAnimation hides the scroll bar widget, so isVisible() then
reports false even though the grid has more rows to scroll. Scrolling was
dead until something else brought the bar back.

Gate on the scroll bar's range instead: it says whether there is anything
to scroll, while visibility is only about presentation. An event with no
range to scroll is still ignored, so an enclosing scroll area can take it.

* Update card_database_visual_view.cpp

---------

Co-authored-by: Lukas Brübach <Bruebach.Lukas@bdosecurity.de>
2026-11-02 18:18:19 +01:00
sentry[bot]
9f30892dff
[Client] Fix crash when local game commands are sent after shutdown (#7714)
Some checks are pending
CodeQL / Analyze (cpp) (push) Waiting to run
CodeQL / Analyze (actions) (push) Waiting to run
Build Desktop / Configure (push) Waiting to run
Build Desktop / vcpkg baseline (push) Waiting to run
Build Desktop / Debian 13 (push) Blocked by required conditions
Build Desktop / Debian 12 (push) Blocked by required conditions
Build Desktop / Fedora 44 (push) Blocked by required conditions
Build Desktop / Fedora 43 (push) Blocked by required conditions
Build Desktop / Servatrice_Debian 12 (push) Blocked by required conditions
Build Desktop / Ubuntu 24.04 (push) Blocked by required conditions
Build Desktop / Ubuntu 26.04 (push) Blocked by required conditions
Build Desktop / Arch (push) Blocked by required conditions
Build Desktop / Ubuntu 26.04 cover (push) Blocked by required conditions
Build Desktop / macOS 13 Intel (push) Blocked by required conditions
Build Desktop / macOS 14 (push) Blocked by required conditions
Build Desktop / macOS 15 (push) Blocked by required conditions
Build Desktop / macOS 26 Debug (push) Blocked by required conditions
Build Desktop / Windows 10 (push) Blocked by required conditions
Build Desktop / Prune caches (push) Waiting to run
Build Docker / Servatrice (arm) (push) Waiting to run
Build Docker / Servatrice (x86) (push) Waiting to run
Build Docker / Publish multi-platform Servatrice image (push) Blocked by required conditions
* [Client] Fix crash when local game commands are sent after shutdown

* [Network] Fix formatting in local client debug log

* [CI] Keep the vcpkg submodule pointer on the manifest baseline

vcpkg.json asks for builtin-baseline 9eec002 (vcpkg 2026.10.16), but the
submodule gitlink was still at 9e593bb. The runners check submodules out
shallowly, so vcpkg-tool cannot read versions/baseline.json out of the baseline
commit and every vcpkg leg (Windows and all macOS) fails in CMake configure
with:

  failed to `git show` versions/baseline.json

git phrases that as "path ... exists on disk, but not in <sha>" even when the
commit is simply absent from the shallow clone, so it reads like a tooling or
network failure rather than a mismatched pointer. Point the submodule back at
9eec002, and add a cheap job that fails when the gitlink and builtin-baseline
disagree, before the five build legs pay for it.

---------

Co-authored-by: sentry[bot] <39604003+sentry[bot]@users.noreply.github.com>
Co-authored-by: Lukas Brübach <Bruebach.Lukas@bdosecurity.de>
2026-11-02 13:28:23 +01:00
Christian Daniel Jensen
070c455b16
Merge pull request #3 from Continuum-Universes-Studio/feature/continuumatrice-zone-bands
Continuumatrice: Limbo, Refuge and Oblivion card piles
2026-11-02 02:04:54 -07:00
Christian Daniel Jensen
f4c78264b8 Document Limbo Refuge Oblivion pile behavior, icon overrides, and testing 2026-11-02 02:00:33 -07:00
Christian Daniel Jensen
dd9aca8668 Add fallback oblivion pile SVG icon 2026-11-02 01:58:35 -07:00
Christian Daniel Jensen
453ef05334 Add fallback refuge pile SVG icon 2026-11-02 01:58:31 -07:00
Christian Daniel Jensen
09e6b54869 Add fallback limbo pile SVG icon 2026-11-02 01:58:29 -07:00
Christian Daniel Jensen
71398ac33c Continuumatrice: adjust extra pile geometry and add built-in icon resources 2026-11-02 01:58:27 -07:00
Christian Daniel Jensen
dbb044771b Continuumatrice: adjust extra pile geometry and add built-in icon resources 2026-11-02 01:57:32 -07:00
Christian Daniel Jensen
3df441195d Continuumatrice: adjust extra pile geometry and add built-in icon resources 2026-11-02 01:57:29 -07:00
Christian Daniel Jensen
21f574ca7c Continuumatrice: render interactive public piles with themed icons 2026-11-02 01:56:37 -07:00
Christian Daniel Jensen
f964b6b24f Continuumatrice: render interactive public piles with themed icons 2026-11-02 01:56:35 -07:00
Christian Daniel Jensen
2afbd86ad1 Continuumatrice: render interactive public piles with themed icons 2026-11-02 01:56:32 -07:00
Christian Daniel Jensen
f9f0901f09 Continuumatrice: render interactive public piles with themed icons 2026-11-02 01:56:29 -07:00
Christian Daniel Jensen
29dd239cd2 Continuumatrice: render interactive public piles with themed icons 2026-11-02 01:56:27 -07:00
Christian Daniel Jensen
d6070c5c96 Continuumatrice: render interactive public piles with themed icons 2026-11-02 01:55:24 -07:00
Christian Daniel Jensen
f87b4eeeac Continuumatrice: add Limbo Refuge Oblivion support to card_menu.cpp 2026-11-02 01:52:40 -07:00
Christian Daniel Jensen
abf9750333 Continuumatrice: add Limbo Refuge Oblivion support to move_menu.cpp 2026-11-02 01:52:26 -07:00
Christian Daniel Jensen
384a3dc036 Continuumatrice: add Limbo Refuge Oblivion support to move_menu.h 2026-11-02 01:52:24 -07:00
Christian Daniel Jensen
1670137064 Continuumatrice: add Limbo Refuge Oblivion support to player_actions.cpp 2026-11-02 01:52:21 -07:00
Christian Daniel Jensen
e23b5eb27e Continuumatrice: add Limbo Refuge Oblivion support to card_menu_action_type.h 2026-11-02 01:52:07 -07:00
Christian Daniel Jensen
2d467955fc Continuumatrice: add Limbo Refuge Oblivion support to server_player.cpp 2026-11-02 01:52:05 -07:00
Christian Daniel Jensen
61faf612a1 Continuumatrice: add Limbo Refuge Oblivion support to player_logic.h 2026-11-02 01:52:02 -07:00
Christian Daniel Jensen
034b7189e3 Continuumatrice: add Limbo Refuge Oblivion support to player_logic.cpp 2026-11-02 01:51:50 -07:00
Christian Daniel Jensen
5ccfbf7a23 Continuumatrice: add Limbo Refuge Oblivion support to zone_names.h 2026-11-02 01:51:48 -07:00
Christian Daniel Jensen
826da7ede2 Document isolated profile and XML4 card/art workflow 2026-11-02 01:41:08 -07:00
Christian Daniel Jensen
f54dcc3e54 Isolate Continuumatrice single-instance socket from Cockatrice 2026-11-02 01:41:05 -07:00
Christian Daniel Jensen
2dab3d0f40 Give Continuumatrice its own Qt profile and data/cache namespace 2026-11-02 01:41:03 -07:00
Christian Daniel Jensen
8bc8317c57 Clarify visual battlefield orientation and card metadata 2026-11-02 01:30:36 -07:00
Christian Daniel Jensen
4a201aa5b6 Document Continuumatrice table row indices 2026-11-02 01:30:34 -07:00
Christian Daniel Jensen
d11db291e1 Align tablerow placement with Front Support Command order 2026-11-02 01:30:32 -07:00
Christian Daniel Jensen
4e2229be98 Orient Front and Command labels toward the opponent 2026-11-02 01:30:30 -07:00
Christian Daniel Jensen
bd9fd6e91b
Merge pull request #2 from Continuum-Universes-Studio/feature/continuumatrice-zone-bands
Fix QFileInfo instance method call in battlefield font loader
2026-11-02 01:02:43 -07:00
Christian Daniel Jensen
5d871dcf28 Fix QFileInfo instance method call in battlefield font loader 2026-11-02 00:58:27 -07:00
Christian Daniel Jensen
3d3a414473
Merge branch 'Cockatrice:master' into master 2026-11-02 00:46:03 -07:00
sentry[bot]
8b0c980e85
[Client] Guard dragged card ghost from painting or dropping deleted cards (#7688)
Some checks are pending
CodeQL / Analyze (cpp) (push) Waiting to run
CodeQL / Analyze (actions) (push) Waiting to run
Build Desktop / Configure (push) Waiting to run
Build Desktop / Debian 13 (push) Blocked by required conditions
Build Desktop / Debian 12 (push) Blocked by required conditions
Build Desktop / Fedora 44 (push) Blocked by required conditions
Build Desktop / Fedora 43 (push) Blocked by required conditions
Build Desktop / Servatrice_Debian 12 (push) Blocked by required conditions
Build Desktop / Ubuntu 24.04 (push) Blocked by required conditions
Build Desktop / Ubuntu 26.04 (push) Blocked by required conditions
Build Desktop / Arch (push) Blocked by required conditions
Build Desktop / Ubuntu 26.04 cover (push) Blocked by required conditions
Build Desktop / macOS 13 Intel (push) Blocked by required conditions
Build Desktop / macOS 14 (push) Blocked by required conditions
Build Desktop / macOS 15 (push) Blocked by required conditions
Build Desktop / macOS 26 Debug (push) Blocked by required conditions
Build Desktop / Windows 10 (push) Blocked by required conditions
Build Desktop / Prune caches (push) Waiting to run
Build Docker / Servatrice (arm) (push) Waiting to run
Build Docker / Servatrice (x86) (push) Waiting to run
Build Docker / Publish multi-platform Servatrice image (push) Blocked by required conditions
* [Client] Guard dragged card ghost from painting or dropping deleted cards

* [Game] Revert handling for cards destroyed mid-drag

Co-authored-by: sentry[bot] <39604003+sentry[bot]@users.noreply.github.com>

* [DeckView] Access pointer through QPointer in DeckViewCardDragItem

---------

Co-authored-by: sentry[bot] <39604003+sentry[bot]@users.noreply.github.com>
Co-authored-by: zeldazach <7460172+zeldazach@users.noreply.github.com>
2026-11-02 08:39:07 +01:00
RickyRister
62e590d300
[ServerGame] Refactor out spectator/judge bools into RoleInfo (#7761) 2026-11-02 00:37:05 -07:00
BruebachL
a1a8a59f4a
[VisualDatabase] Draw the card grid with a model/view (#7701)
* [VisualDatabase] Draw the card grid with a model/view instead of a widget per card

The visual card database built one CardInfoPictureWithTextOverlayWidget per
card, 100 per page, and tore them down on every search, resize and scroll
page. It also looked each card up again by name from the model row, kept a
shadow QList<ExactCard>, and carried paging state plus a 5 s timer that only
existed to defer the first page.

Replace that with a real view on a flattened model:

- CardDatabaseDisplayModel gains CardInfoRole and cardInfoAt(), so a view can
  get the CardInfoPtr behind a proxy row without a name round trip.
- New CardDatabaseVisualDisplayModel (libcockatrice_models) flattens the
  filtered and sorted proxy into one entry per displayed card picture: the
  preferred printing normally, every printing of the selected sets while set
  filters are active. Proxy changes rebuild it on a 30 ms coalescing timer.
- New CardDatabaseVisualView (QListView IconMode) paints only visible rows
  through the new CardPictureDelegate, keeps the old interaction contract
  (left/right/middle press -> cardClicked, hover -> cardHovered, Ctrl+wheel
  resize, no selection, no focus stealing, scroll to top on a new result) and
  repaints when CardPictureLoader reports an async image.
- CardSizeWidget::enableCtrlScrollResize() also watches scroll-area viewports,
  which is what makes Ctrl+wheel work over a QListView.
- VisualDatabaseDisplayWidget drops the paging, the shadow list, the dead
  members and the 5 s timer.

Behaviour-preserving: no gameplay change, no new user-facing strings.

* [VisualDatabase] Fix the card grid wheel step

QListView hands the delegate's item height to the scroll bar as its single step under ScrollPerPixel, so QAbstractSlider moved wheelScrollLines() whole card rows per notch. Handle the wheel in the view instead: one line is an eighth of the grid cell, so a notch moves about a third of a card row at any card size and still follows the OS line count.

---------

Co-authored-by: Lukas Brübach <Bruebach.Lukas@bdosecurity.de>
2026-11-02 08:35:58 +01:00
Christian Daniel Jensen
ccab482668
Merge pull request #1 from Continuum-Universes-Studio/feature/continuumatrice-zone-bands
Continuumatrice: colored Front / Support / Command battlefield
2026-11-02 00:21:11 -07:00
Christian Daniel Jensen
3f779c3bc1 Document battlefield colors and Continuumorphous font setup 2026-11-01 23:52:50 -07:00