wasm: container contents list, add and remove #336

Open
opened 2026-10-24 09:45:54 +02:00 by jqueuniet · 0 comments
Owner

Expose container contents (chests, money box, bags) through WASM: list, add, remove. The library has chest_contents, add_to_chest, remove_from_chest.

Scope

  • List a container's contents, with the same per-item shape as the inventory read.
  • Move an item from a slot into a container and back out to a slot.
  • Nested containers: list them as items, and refuse inserting a container into itself.
  • Respect any capacity / item-kind restrictions the engine enforces, ground-truthed against [SKPROJECT].

Acceptance

  • Round trip slot → container → slot leaves the save byte-identical to the original.
  • Contents listing matches what the game shows for a fixture with a filled container.

Blocked by the inventory-operations issue.

Expose container contents (chests, money box, bags) through WASM: list, add, remove. The library has `chest_contents`, `add_to_chest`, `remove_from_chest`. ## Scope - List a container's contents, with the same per-item shape as the inventory read. - Move an item from a slot into a container and back out to a slot. - Nested containers: list them as items, and refuse inserting a container into itself. - Respect any capacity / item-kind restrictions the engine enforces, ground-truthed against `[SKPROJECT]`. ## Acceptance - Round trip slot → container → slot leaves the save byte-identical to the original. - Contents listing matches what the game shows for a fixture with a filled container. Blocked by the inventory-operations issue.
jqueuniet added this to the dm2-tools project 2026-10-24 09:49:02 +02:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
jqueuniet/dm2-tools#336
No description provided.