Skip to content

Releases: Darithos/D3ModelViewer

D3 Model Viewer v1.2.0

Choose a tag to compare

@Darithos Darithos released this 28 Aug 06:37

Diablo III hand-authors a ragdoll for almost every creature in the game and stores it inside the appearance file: a collision volume on each bone and a cone-twist joint between them. This release reads it, shows it, simulates it, and writes it into the StarCraft II export. Nothing is generated — it was all already there.

Ragdoll in the viewer

  • Ragdoll (geoset panel) draws the game's bodies as wireframes over the model, and they follow the animation.
  • Ragdoll (animation panel) drops the rig from the current pose and simulates it under BepuPhysics, on an invisible floor. A faint grid shows where the ground is, because a corpse resting in mid-air and one resting on the ground look identical without it.
  • on end hands a non-looping clip to the solver at its last frame — the same point the export marks with Evt_Simulate, so you watch the whole death the way it will play in game. Ticking it unticks Loop, since a looping clip never ends. Play, or scrubbing, takes the skeleton back from the solver.

The floor's top face sits at min(0, lowest body point) of the starting pose: it drops to meet the model rather than lifting the model into it, so nothing ever starts embedded. A death animation that sinks the corpse below z = 0 will therefore rest lower here than in game.

This is a preview, not a prediction. StarCraft II runs a different solver, so resting angles and settle time will not match. What it answers reliably is whether the rig is sound — an inverted axis, a body that flies off, limbs passing through each other, a corpse that never settles.

Ragdoll in the export

.m3 files now carry PHRB / PHSH / PHYJ physics sections. In the export dialog, tick Ragdoll on a death clip and it is written not_looping with an Evt_Simulate event before the sequence end, which is how StarCraft II hands the corpse to its own solver.

Three rules keep the rig to what the game actually simulates: only the first volume on each bone, convex hulls fitted to boxes from the bone's skinned vertices, and bodies that no joint touches dropped — which is what stops a Fallen Champion's spear becoming part of the corpse.

Format notes, coverage numbers and the parts that are easy to get wrong are in docs/RAGDOLL.md.

Known limits

  • The PHSH version and the cone-only joint mapping are unverified in the StarCraft II editor itself — everything so far has been checked by round-tripping through m3studio in Blender.
  • The convex hull sub-structure is still undecoded; fitted boxes stand in for it.

Requirements

Windows 10/11 64-bit and your own Diablo III installation. The single D3ModelViewer.exe below is the whole application — no .NET install needed. SmartScreen will warn on first run because it is not code-signed.

D3 Model Viewer v1.1.1

Choose a tag to compare

@Darithos Darithos released this 26 Aug 13:00

Fixes a UI freeze introduced in v1.1.0. If you are on v1.1.0, take this update.

The bug

Loading a model that has no actor binding and no name match — a4_Heaven_Shrine_Global is one — fell back to the All animations source and put all 15,258 entries into the animation dropdown. Opening that dropdown locked the UI thread for about 31 seconds and pushed the process to ~690 MB, which was heavy enough to slow the whole machine down.

What was wrong

Two separate things, both fixed.

WPF's ComboBox defaults its ItemsPanel to a plain StackPanel, which builds a visual for every single row instead of just the visible ones. Measured against the real catalogue:

Items in list Time to open Extra memory
500 0.5s +23 MB
5,000 8.5s +63 MB
15,258 31.6s +135 MB

Switching the dropdown to a VirtualizingStackPanel fixes it outright — the same 15,258 items now open in 136 ms with +2 MB. This helps every source, not just the largest: a 760-entry skeleton match was already costing about a second.

a4_Heaven_Shrine_Global has no bones at all, so no animation could ever be applied to it — the viewer builds an empty set of skin matrices and every animation just renders the bind pose. Offering it the entire catalogue was meaningless as well as slow. v1.0.x guarded against this and v1.1.0 accidentally dropped the guard; it is back, and the panel now reads No skeleton with a tooltip explaining why.

Not changed

The export dialog's animation list is also a non-virtualising control, but it is capped at 500 rows and costs about 570 ms to populate — a hitch rather than a freeze, and unchanged since v1.0.x. Left as it is.

Download & run

  1. Download D3ModelViewer.exe below.
  2. Run it (Windows 10/11 x64).
  3. Point it at your Diablo III install folder (auto-detected when possible) and click Open.

Windows SmartScreen may warn because the exe is not code-signed. Choose "More info → Run anyway", or build from source if you're concerned.

You need your own installed copy of the game.

D3 Model Viewer v1.1.0

Choose a tag to compare

@Darithos Darithos released this 26 Aug 10:26

Animations are now bound to models using the game's own data instead of guesswork about names.

The problem

Animation matching worked by walking the model's name backwards one _ at a time and taking the first prefix that hit anything. It was wrong in both directions:

Model Before Now
NPC_Human_Male_01_A 1 animation — NPC_Human_Male_Cellar_Arm_idle_01 211 — the OmniNPC_Male set
TristramGuard_B 2 208
Beast_A 1Beast_attack_01 39 — the Beast set

Beast_A shows the small bug: Beast_A is a prefix of Beast_attack_01, so the walk stopped on that one false hit and never fell back to Beast_*.

NPC_Human_Male_01_A shows the real one. Diablo III's humanoid NPCs share a single animation library whose names have nothing to do with the models that use it, so no amount of name matching could ever find it.

What changed

The game binds animations through Appearance ← Actor → AnimSet → Anim, and the viewer now reads that chain directly. NPC_Human_Male_01_A resolves through actor NPC_Human_Male to animset OmniNPC_Male — the shared human library, straight from the game files.

The animation panel has a source dropdown with live counts, defaulting to the most specific source that finds anything, plus a search box:

  • This unit — what the game itself binds to this appearance. Authoritative; covers the ~29% of appearances that have an actor of their own.
  • This skeleton — every animation whose bones all exist in this model's rig. This is the other way a human body picks up the shared library, and it covers rigged models that have no actor.
  • Name match — the old prefix walk, now required to stop on a name boundary so Beast_A no longer matches Beast_attack_01.
  • All animations — the whole 15,258-animation catalogue.

The export dialog offers the same four sources, so the sequences you export are the ones you previewed.

The sources are kept separate rather than merged into one list, because skeleton matching is a good superset for characters and a noisy one for props — a two-bone chest has 204 trivial "matches", while the same rule is exactly what surfaces the humanoid library for a 44-bone body.

Under the hood

Two Diablo III formats were decoded for this and validated against the whole retail catalogue:

  • .acr (Actor) — Appearance SNO at @36, AnimSet SNO at @120. Across all 19,177 actors @36 resolves 100% of the time, and no other offset below 400 looks like an AnimSet in more than 4 files.
  • .ans (AnimSet) — 16-byte header, 29 SerializeData records at @32, contiguous blocks from @496, each a TagMap of int count + count × {type, tagId, value}. All 3,212 AnimSets parse with every invariant intact.

Both are written up in docs/ANIMATION-ASSOCIATION.md.

Cost is small: the actor index takes 0.14s when the storage opens, and the skeleton index takes 1.25s and is only built if you actually select that source.

Download & run

  1. Download D3ModelViewer.exe below.
  2. Run it (Windows 10/11 x64).
  3. Point it at your Diablo III install folder (auto-detected when possible) and click Open.

Windows SmartScreen may warn because the exe is not code-signed. Choose "More info → Run anyway", or build from source if you're concerned.

You need your own installed copy of the game.

D3 Model Viewer v1.0.3

Choose a tag to compare

@Darithos Darithos released this 26 Aug 09:24

Packaging and presentation release — no functional changes to the viewer or the exporters since v1.0.2.

One file

The download is now a single D3ModelViewer.exe instead of a zip containing ~400 DLLs. Nothing to extract, and no hunting through PresentationCore.dll and friends to find the executable.

It is still fully self-contained — the .NET runtime and every dependency are bundled — and the download is about the same size as the old zip. First launch is roughly 0.2s slower while the native libraries unpack to %TEMP%.

An icon

The app now has one: D3E, in a clawed, molten-ember style, drawn at all ten Windows icon sizes.

Download & run

  1. Download D3ModelViewer.exe below.
  2. Run it (Windows 10/11 x64).
  3. Point it at your Diablo III install folder (auto-detected when possible) and click Open.

Windows SmartScreen may warn because the exe is not code-signed. Choose "More info → Run anyway", or build from source if you're concerned.

You need your own installed copy of the game.

D3 Model Viewer v1.0.2

Choose a tag to compare

@Darithos Darithos released this 26 Aug 09:07

Bug-fix release. Everything from v1.0.1, plus one export fix.

Export fix (StarCraft II / .m3)

  • Cutout art now actually cuts out in StarCraft II. v1.0.1 turned on alpha testing for materials whose diffuse texture carries a cutout mask — fur, hair, foliage, grates — but exported models still rendered as solid cards in-game. The reason: SC2's alpha test does not read the diffuse layer's alpha channel. It reads the material's separate alpha-mask layer slot, which the exporter left empty, so the engine tested against a blank source and every texel passed no matter what threshold was set.

    Alpha-tested materials now get their own alpha-mask layer, bound to the diffuse texture in "alpha only" mode, wired into that slot. Cutout regions render as the ragged silhouettes the viewer shows, matching the original Diablo III art.

  • Models whose textures have no transparent texels are unaffected — those exports are byte-identical to v1.0.1.

If you exported models with v1.0.0 or v1.0.1 and they look solid where they should be see-through in the SC2 editor or in game, re-export them with this build.

The full diagnosis, the ground-truth comparison against working community and Blizzard models, and the traps found along the way (including two that crash the SC2 editor or produce a glowing white model) are written up in docs/SC2-ALPHA-MASK-LAYER-BUG.md.

Download & run

  1. Download D3ModelViewer-v1.0.2-win-x64.zip below and extract it anywhere.
  2. Run D3ModelViewer.exe (Windows 10/11 x64).
  3. Point it at your Diablo III install folder (auto-detected when possible) and click Open.

Windows SmartScreen may warn because the exe is not code-signed. Choose "More info → Run anyway", or build from source if you're concerned.

You need your own installed copy of the game.

D3 Model Viewer v1.0.1

Choose a tag to compare

@Darithos Darithos released this 23 Aug 07:16

Bug-fix release. Everything from v1.0.0, plus:

Viewer

  • Water now looks like water. Water and river surfaces (and their cousins: tar pits, Heaven's glowing bridges) used to render as lavender/purple panels — the viewer was painting the material's ripple normal map (or the scene's baked lightmap) as if it were a color texture. Diablo III colors these surfaces entirely in its shaders and ships no color art for them at all. The viewer now reads each material's ShaderMap reference and renders these geosets with a tinted, translucent water/tar/glow material instead. This affects roughly 850 scene appearances across every act (rivers, sewers, bogs, oasis pools, cesspools, tar pits, Heaven).
  • Set D3MV_WATER=0 to restore the previous raw-texture behavior for comparison.

Export fixes (StarCraft II / .m3 + .dds)

  • Cutout art no longer renders solid black in SC2. Exported .m3 materials now enable alpha testing (threshold 0.2, matching the in-viewer preview and the glTF export) whenever their diffuse texture carries a cutout mask — fur cards, hair, grates, foliage.
  • .dds exports now include a full mip chain (previously level 0 only), so textures no longer shimmer or vanish at distance in game.
  • DXT1A textures are re-encoded as DXT5 with the color under transparent texels inpainted from opaque neighbours. BC1's punch-through alpha forces transparent texels to black, which dragged dark fringes into cutout edges under filtering and mipmapping.
  • Fixed a BC3 (DXT5) alpha decoding bug: the 8-value alpha ramp used wrong interpolation weights and left its last entry unfilled, subtly corrupting soft alpha gradients in previews and PNG exports.

See docs/SC2-ALPHA-EXPORT-BUG.md in the repo for the full diagnosis of the export issue.

Download & run

  1. Download D3ModelViewer-v1.0.1-win-x64.zip below and extract it anywhere.
  2. Run D3ModelViewer.exe (Windows 10/11 x64).
  3. Point it at your Diablo III install folder (auto-detected when possible) and click Open.

Windows SmartScreen may warn because the exe is not code-signed. Choose "More info → Run anyway", or build from source if you're concerned.

You need your own installed copy of the game.

D3 Model Viewer v1.0.0

Choose a tag to compare

@Darithos Darithos released this 15 Jul 02:37

Features

Browse, preview, and export models from your own local Diablo III installation:

  • Asset browser over the full appearance catalog (reads CoreTOC.dat from CASC storage)
  • Textured 3D preview with geoset visibility toggles
  • Animation playback (matched by name + skeleton): play, loop, scrub, speed
  • Export to .m3 (StarCraft II, with selected animations as named sequences) and .gltf (Blender)
  • Textures exported as .dds and/or .png
  • Default export scale 0.02 - to try and match StarCraft II character heights

Download & run

  1. Download D3ModelViewer-v1.0.0-win-x64.zip below and extract it anywhere.
  2. Run D3ModelViewer.exe (Windows 10/11 x64).
  3. Point it at your Diablo III install folder (auto-detected when possible) and click Open.

Windows SmartScreen may warn because the exe is not code-signed. Choose "More info → Run anyway", or build from source if you're concerned.

You need your own installed copy of the game.

Thanks

This tool wouldn't exist without the excellent work of:

  • Ladislav Zezula for CascLib — the foundation for reading Blizzard's CASC storage format (MIT licensed)
  • The Helix Toolkit team for their 3D rendering library (MIT licensed)

Both are MIT licensed and integral to making this viewer work.