Case Study 03 · Rust Desktop Software

D2 Assistant

A local-first desktop application for managing classic Diablo II characters, items, and save files.

The engineering challenge was to make complex inventory and character workflows useful while treating player save files as valuable data that must remain recoverable.

Product interface

D2 Assistant skill editor for a Diablo II character

One tool for the whole workflow

Existing offline tools separated item storage, save editing, recipe lookup, and build planning. D2 Assistant brings character inspection and editing, a shared item bank, bulk transfers, search, backups, and runeword references into one desktop application.

The product is local-first: save parsing and edits happen on the player's computer, while SQLite stores app data such as the shared bank.

Rust, Tauri, TypeScript

Engineering decisions shaped by failure modes

Write to the selected save in place

The product requirement is to target the file the player selected and avoid creating a second, similarly named character file. Sanitized fixture tests are still needed to prove every character-edit path end to end.

Make recovery part of the transfer path

Bank transfers validate the selected items and destination, serialize and reparse the result, check item counts, create a verified backup, stage the write, and verify the bytes written. Character-edit flows still need broader fixture-backed integration coverage.

Lock writes while the game is open

The running game may hold a save in memory, and the process does not reliably identify which character is loaded. The safe behavior is to block character and stash writes until the game exits.

Report compatibility honestly

The current save editor supports original Diablo II: Lord of Destruction version 96 files. D2R recipe references do not imply D2R save support, and local duplicate checks are not Battle.net protection.

How I built it with agents in the loop

I used AI agents as implementation capacity while keeping product direction, priorities, and acceptance criteria under human control. I started from actual play workflows, identified where an operation could lose or duplicate items, wrote down the expected behavior, and checked the running application against it.

That review changed implementation details: transfers target the selected character file, item batches report per-item failures, search distinguishes a word like “Mage” from “Damage” while preserving short rune searches, and save writes are locked while the game is running.

The repository uses frontend build and test checks, Rust formatting and Clippy, Rust tests, duplicate-code detection, and complexity reporting. Those gates catch regressions; they do not substitute for testing every real save-file variant.

Scope and verification limits

The current release targets offline classic Lord of Destruction version 96 saves. It does not edit D2R saves, connect to Battle.net, or provide server-side ownership checks. Sanitized fixture coverage and failure-injection tests are still needed to establish end-to-end confidence for every save mutation path.