feat: stackable currency with coin art, and drag ground items onto the backpack to pick up #104
No reviewers
Labels
No labels
alpha:wave-0
alpha:wave-1
alpha:wave-2
alpha:wave-3
area:assets
area:combat
area:ecology
area:infra
area:render
area:scripting
area:ui
area:world
enhancement
epic
migration
post-alpha
roadmap
tech-debt
type:bug
type:chore
type:design
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
marco/IsoMmo!104
Loading…
Reference in a new issue
No description provided.
Delete branch "feat/backpack-stacking"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Phase 2 of the weight-bounded backpack (#99): stackable kinds collapse into one entry with an amount and combined weight, plus the coin art and the ground display/interaction. Builds on #100 (Phase 1, merged). All rules are generic (per
MaxStack), not coin-specific.Changes
c97d2c1):BaseItem.MaxStack(Coin 60000);Item.Amount(serialized, v1→v2 backward-compatible).Give/PickUpmerge into existing stacks up to MaxStack then spill; a pickup that nothing absorbs keeps the ground item's id.CarriedWeightis amount-aware; the pickup cap is per whole stack. ProtocolOwnedItem.Amount;ProtocolVersion→ 2./clearbag(eb53c33): GM command to empty a backpack (testing).6fbf9db): three RGBA sprites picked by amount — single coin (1), pile (2–500), big stack (>500) — a coin sized to match a coin in the >500 mound. Ground items scaled to a tile-ish size. The client selects sprites generically via<kind>/<kind>_pile/<kind>_stack.452a457):GroundItem.Amountso a dropped pile shows the tiered sprite on the ground too. Single-click reads an item (name + amount); double-click (or E) picks it up.Verification
dotnet build: 0 warnings;csharpier check .clean;dotnet test: 314 passing (stacking, spill, non-stackable, pickup-merge, persistence round-trip, /clearbag)./give coin 500×n → one pile with the count and the combined weight in the readout; single→pile→stack sprites in the bag and on the ground; single-click reads "coin (400)"; double-click picks it up.1b1e1ed8a038072f5bf2Currency stacking + coin art (#99 phase 2)to feat: stackable currency with coin art, and drag ground items onto the backpack to pick up