File format · .n3d2

N3D2 Mesh Files (Nebula Device 2): Format, Corruption and Repair

A guide to the .n3d2 ASCII mesh format used by Nebula Device 2: how the file is built, why meshes stop loading, and what repair can save.


The .n3d2 extension identifies a mesh resource file for The Nebula Device 2, an open-source 3D engine from the German studio Radon Labs GmbH. The file is plain text. It describes a 3D model as numbers: vertex positions, normals, texture coordinates, optional skin weights, and the triangles that connect everything into a surface. That text-based nature changes how damage behaves, and how much of a broken mesh can be saved. This page covers the format, the usual failure modes, and what professional repair can realistically recover.

What is an N3D2 file?

Radon Labs GmbH, based in Berlin, built The Nebula Device 2 as the engine behind its role-playing games, including Drakensang. The studio released the engine as open source, so the code survived even after the company closed in 2010. The original website did not. Today the engine's public source mirrors are the closest thing to official documentation, and the mesh loader inside that source is the authoritative definition of this format.

An N3D2 file holds one mesh: a character, a prop, or a piece of level geometry the engine renders. It is the ASCII form of the mesh resource. The engine also accepted a binary form, .nvx2, which carries the same data in compact bytes. Exporters for 3ds Max and Maya wrote these files. Many teams kept the ASCII version in source control, since it diffs cleanly, and converted to the binary form only for shipping builds. No MIME type is registered for the format, and any plain text editor can open it.

Inside an N3D2 file: structure and key facts

The format is line-oriented ASCII with a small header followed by data. The header declares the number of vertex groups, the vertex count, the triangle count, and the width of each vertex row. It also lists the components each row contains, which may include positions, normals, several UV channels, vertex colours, tangents, binormals, and skin weights with joint indices. A group table then splits the triangle list into subsets, typically one per material. After that come the vertex rows and triangle indices as plain numbers.

The engine trusts that header completely. It allocates buffers from the declared counts and streams the data in, so the counts must match the rows that actually follow. A missing line, an extra token, or a stray byte is enough to abort the load. There is no binary magic number to check, because there is nothing binary in the file. Recognition and validation both happen by parsing the text, which is why the engine source remains the definitive specification.

Why do N3D2 files become corrupt?

Most damage happens while the file is being written. If the modelling tool or exporter crashes mid-save, or the disk fills up, the file ends partway through a vertex row. The header still promises the full count, so the engine reads off the end of the data and fails. A zero-byte file is the extreme case of the same failure.

Encoding problems are the other classic cause. The format expects plain single-byte text. Editors that quietly re-save a file as UTF-16, insert a byte order mark, or convert line endings can break parsing before the first line is even read. The same applies to transfers that mangle the file, such as a download that ends early or a server error page saved in place of the mesh.

Manual editing causes its own share of failures. A deleted line breaks the count contract, and a typo turns a number into a token no parser will accept. Word processors can also inject smart quotes or rich formatting that the engine will never tolerate. Storage faults matter too: bad sectors and failing drives leave garbage bytes inside an otherwise readable file. Binary data saved under the .n3d2 name, such as a renamed .nvx2 mesh, looks like gibberish for a different reason.

What can be recovered from a damaged mesh?

The outlook depends on which part is broken. When the header is damaged but the vertex rows are intact, recovery is usually complete: the counts and component list can be rebuilt from the data itself. When the file was truncated, everything up to the cut survives, and the mesh can be salvaged with its tail missing. Scattered corruption leaves holes rather than total loss.

Individual damaged values are often survivable as well. Normals can be recomputed from surviving geometry, and texture coordinates can be borrowed from nearby vertices. Lost skin weights are harder; the geometry still loads, but the mesh may need re-binding in a modelling tool before it animates correctly. If the file turns out to be a binary .nvx2 or an archive in disguise, it follows a different but equally workable recovery path.

How does the repair process work?

One rule applies before anything else: work on a copy. Every extra save in an unsuitable editor can remove information that was still recoverable.

Repair starts with triage. We examine the file in a hex editor first. That confirms whether the bytes are really text, and flags a byte order mark, wide characters, or a binary header from another format. Next we normalise the encoding back to plain text and check the line structure.

Then we parse the file with our own tooling rather than trusting the header. That pass counts the vertex rows and triangles that actually exist, validates every number, and records where junk appears. From those findings we rebuild the header so the declared counts match the real data, reconstruct the group table, and clean or cut the damaged rows.

Finally we test. The repaired mesh is validated against the loader's expectations and checked in a viewer where possible. We then deliver it as a valid .n3d2, a converted .nvx2, or an interchange format you can re-import into any modelling package. For an overview of how we approach this work in general, see our 3D model file repair service.

Frequently asked questions

Can I open an N3D2 file in a text editor?

Yes, and it is the quickest way to check whether the data is present. Use a programmer's editor such as Notepad++ or VS Code, and open it without re-saving. If the file shows a readable header followed by long rows of figures, the content survives. Garbled symbols or a wall of binary mean encoding damage or a different format entirely.

Is an N3D2 file the same as an NVX2 file?

They describe the same mesh resource in two forms. N3D2 is the ASCII text form, and NVX2 is the compact binary form the engine reads at runtime. Renaming one to the other converts nothing. A repair service can convert between them once the mesh is valid.

My N3D2 file is zero bytes. Is anything recoverable?

Usually not from the file itself, because nothing was written to it. Look around instead: the exporter's source scene, a version control history, a backup, or an already converted .nvx2 may hold the same asset. A zero-byte mesh after a crash is often a symptom, so check the other files from that export too.

Where can I find official documentation now that Radon Labs is gone?

The studio closed in 2010 and its site went with it. The engine was open source, though, so the code and its mesh loader live on in public source mirrors. That loader is the most precise description of the format available, and it is the reference any serious repair should be checked against.

Can a repaired mesh be converted to a modern format?

Yes, once the mesh parses cleanly. Vertex positions, normals, and texture coordinates map onto common interchange formats without loss. Skinned meshes need more care, since weights and joint indices depend on a matching skeleton, but the geometry alone converts straightforwardly.

Send us the file for a free evaluation

If a mesh refuses to load, our engineers will examine it and tell you plainly what is recoverable before you commit to anything. Upload the file through our free file evaluation page and we will report back with the damage map and the likely outcome. There is no obligation, and a look costs you nothing.

Send us your .n3d2 file for a free evaluation

Our recovery engineers will tell you exactly what can be recovered — at no cost. There is no charge if we cannot recover your data.

Start a free evaluation