[Adventure] Commander mode: "Owned" count on shop/reward cards should count all printings
メンテナーはふだん 1 日以内に返信
まだ誰も着手していません。
評価
調査の方向性
forge-gui-mobile/src/forge/adventure/util/RewardActor.java の344行目付近から開始します。そこでは報酬の所有数が計算されます。CardPool.countByName(PaperCard) は AdventurePlayer.current().isCommanderMode() が true の場合だけ使用し、他のモードでは印刷ごとの個数を維持します。完了とは、ショップカードと報酬カードが Commander モードで所有している各印刷を名前ごとに数え、既存の New バッジが修正後の個数を使用する状態を意味します。
索引モデルが issue の本文から書いたものです。
説明
Is your feature request related to a problem? Please describe.
In Adventure Commander mode, shop and reward cards show Owned: 0 (or the "New" badge) for a card I already own if the one on offer is a different printing. For example, a shop offers a Sol Ring and shows Owned: 0. I buy it, and my collection then shows 2 Sol Rings, because my first one came from another set.
Commander is singleton, so the useful question is "do I already have this card?", not "do I have this exact printing?" Shops and rewards regularly offer other printings: set-themed shops, enemy deck loot, boosters.
The count comes from RewardActor (line 344), which matches the exact printing:
int ownedCount = AdventurePlayer.current().getCollectionCards(true).count(reward.card);
Describe the solution you'd like
In Commander mode, count owned copies by card name. CardPool.countByName(PaperCard) already exists, so this could be a small change:
var pool = AdventurePlayer.current().getCollectionCards(true);
int ownedCount = AdventurePlayer.current().isCommanderMode()
? pool.countByName(reward.card)
: pool.count(reward.card);
The "New" badge is driven by the same value, so it would also stop showing for printings of cards you already own. Non-Commander Adventure keeps the current per-printing count. Auto-sell isn't touched, since it already has its own "Auto-sell variants of owned cards in Commander" option.
Describe alternatives you've considered
Always counting by name, in every mode. That's simpler, but players collecting specific printings or arts outside Commander might want the per-printing count.
Showing both, e.g. Owned: 0 (1 any printing). That's more informative, but busier on small screens.
A game setting/option that toggled the behavior between multiple possible counting modes.
Additional context
- 主要言語
- Java
- スター
- 2.7k
- フォーク
- 1.1k
- 平均マージ
- 19時間 28分
- マージ済み PR(30日)
- 316
環境構築
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
Card-Forge/forge のほかの issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
Card-Forge/forge#13092 ·
メンテナーはふだん 1 日以内に返信
-
難易度 1/5 1時間未満 初心者へのやさしさ 85/100
Card-Forge/forge#12877 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
Card-Forge/forge#12710 ·
メンテナーはふだん 1 日以内に返信
-
Shandalar "The Drunken Plea" quest completes prematurely再び着手できるかも @Simisays が 37 日前に担当しましたが、オープン中のプルリクエストはありません。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
Card-Forge/forge#12306 · 担当者 1 名 ·
メンテナーはふだん 1 日以内に返信
-
難易度 1/5 1時間未満 初心者へのやさしさ 82/100
Card-Forge/forge#12206 ·
メンテナーはふだん 1 日以内に返信
Card-Forge/forge の issue をすべて見る
似ている issue
-
難易度 1/5 1〜3時間 初心者へのやさしさ 92/100
HexaHexes/neoforge-mod-template#124 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 70/100
OpenLiberty/open-liberty#36410 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
erkamyaman/rust-anything#1153 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
メンテナーはふだん 1 日以内に返信