HumankindAssetFramework

Building the plugin

For adopters who just want to use the Factory, no build is needed — grab a released HumankindAssetFramework.dll. Build only if you’re changing the plugin.

Plugin (HumankindAssetFramework.dll)

Needs the .NET SDK. The project file is HumankindAssetFramework.csproj. Put a References\ folder next to the .csproj containing:

Then:

dotnet build -c Release

and copy bin\Release\HumankindAssetFramework.dll<Humankind>\BepInEx\plugins\.

Blender (optional dependency)

Blender is needed for .blend import, animated-model import, Strip parts, and Reduce-to-tris decimation — auto-detected under Program Files, or point the Factory Settings override / EditorPrefs 'ENC.blenderPath' at blender.exe. Static GLB/OBJ/FBX bakes with neither Strip nor Reduce need no Blender: the GLB path uses the self-contained Tools/glbconv/glbconv.exe (no .NET install required, and its Convert grid option decimates without Blender). A dotnet glbconv.dll fallback exists for local dev.

Why Blender does the geometry work (design rationale)

The heavy geometry passes shell out to headless Blender (Tools/prep_model.py, rig_anim.py, blend_export.py) rather than being written in C#. The scripts are Python, but Python is only the remote control — the actual decimation/import/export executes inside Blender’s C/C++ core:

Tests

dotnet test Tests/HumankindAssetFramework.Tests.csproj -c Release

An xUnit suite (net471) over the pure registry/parse/era layer — the half that touches no live-game reflection, and where the bugs have historically been. Needs the same gitignored References\ DLLs as the plugin build (mirrored into the test bin). Full detail — what’s covered, what’s deliberately out of scope and why, how to add a test — is in Testing.md.

Editor tooling (baker/)

The Model Factory editor scripts are mirrored in baker/ (the live copies compile inside the ENCReload Unity project, which tracks only its Databases in git). Drop them into a Unity project that has the Humankind SDK to get the Tools ▸ Model Factory window.