Hard vs soft references

Mock Q9 (Partial) · study plan 1.1: "the single most likely technical question for a Blueprint-heavy role" · 8 min

In one breath

A hard reference loads the other asset with yours, and everything it hard-references, all the way down. A soft reference is just a path; nothing loads until you ask. A Cast To BP_Something node is a hard reference. That's how a small prop ends up dragging 400 MB into memory.

Hard vs soft

HardSoft (TSoftObjectPtr, TSoftClassPtr, FSoftObjectPath)
StoresA pointer, recorded in the package's import tableA path string
Loading mine loads it?Yes, synchronously and transitivelyNo. Load on request (async via FStreamableManager / Asset Manager)
CostMemory and load timeLatency. Code must handle "not loaded yet"
Use forSmall things always needed with the ownerBig or optional things: meshes, textures, sounds, levels, UI, runtime picks

How one reference becomes 400 MB

Finding it

ToolShows
Reference Viewer (right-click asset)What this pulls in, and what pulls it in
Size MapTotal size including dependencies: "this prop is 400 MB"
Asset AuditEvery asset sorted by total size
memreport -full, obj listWhat's actually resident in a running build
A script (the tools answer)Walk every BP via the asset registry, sum dependencies, flag anything over a threshold. Run it in CI.

Fixing it

Do, don't just read (study plan 1.1)

Open Size Map on the heaviest Blueprint in Neon Echo (or BP_HeroCharacter in WadOfGore). Write down the number and what's in the chain. That becomes an interview answer with a real number in it.

Quiz yourself

What happens when you load an asset with a hard reference to another?

The referenced asset loads too, synchronously, and so does everything it hard-references, transitively.

Which innocent-looking Blueprint node creates a hard reference?

Cast To <Blueprint class>. (Also variables typed as a BP class.)

Why doesn't reference bloat show up while working in the editor?

The editor has usually loaded everything already, with no memory budget or cook step, so the chain looks free.

Reference Viewer vs Size Map?

Reference Viewer: the graph of what references what. Size Map: total memory/disk including dependencies.

Two ways to talk to a manager BP without casting to it.

A Blueprint Interface, or an event dispatcher. (Or put the logic in a C++ base class / subsystem.)

Cost of switching to soft references?

Latency and complexity: you load on demand (ideally async) and must handle the not-yet-loaded / null case.