Add Packages inventory screen and auto-scrap duplicate package pulls
Packages are unique-per-type; duplicate pulls now auto-scrap into Cache (mirroring the distro dupe->Merges path) instead of a dead-end merges pool, and the pull reveal shows "-> N cache" for the dupe card. Save loading collapses any pre-existing duplicate package entries to the highest-level instance and grants Cache for the extras, logging the migration. Also adds a dedicated Packages tab in the Collection screen (master list with slot filter/sort + affordability hints, detail panel with upgrade/scrap actions) so the whole inventory can be managed from one place, sharing state with the existing per-distro Packages sub-tab. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01MQmck8EqqWxSq5uVZ4E7yN
This commit is contained in:
@@ -127,6 +127,9 @@ namespace KernelPanic.Meta
|
||||
public string DisplayName { get; }
|
||||
public GachaRewardType RewardType { get; }
|
||||
public PullOutcomeKind OutcomeKind { get; }
|
||||
|
||||
// Holds distro dupe merges, or (when RewardType is Package) the Cache a duplicate package
|
||||
// pull was auto-scrapped for. See StatusText for which unit applies.
|
||||
public int MergesAwarded { get; }
|
||||
public IReadOnlyList<Language> LanguagesUnlocked { get; }
|
||||
public bool Guaranteed { get; }
|
||||
@@ -139,11 +142,12 @@ namespace KernelPanic.Meta
|
||||
{
|
||||
get
|
||||
{
|
||||
string dupeUnit = RewardType == GachaRewardType.Package ? "cache" : "merges";
|
||||
return OutcomeKind switch
|
||||
{
|
||||
PullOutcomeKind.Granted => "NEW",
|
||||
PullOutcomeKind.Dupe => $"→ {MergesAwarded} merges",
|
||||
PullOutcomeKind.DupeOverflow => $"→ {MergesAwarded} merges",
|
||||
PullOutcomeKind.Dupe => $"→ {MergesAwarded} {dupeUnit}",
|
||||
PullOutcomeKind.DupeOverflow => $"→ {MergesAwarded} {dupeUnit}",
|
||||
_ => Guaranteed ? "guaranteed" : PityTriggered ? "pity" : string.Empty
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user