Skip to main content

Technical Architecture

Runtime Layers​

LayerResponsibility
UInventorySettingsDatabase and UI configuration
UInventorySubSystemGame Instance access, item indexes, operation wrappers, local UI delegates
UInventoryManagerDatabase loading, component resolution, operation state dispatch
UInventoryComponentEntry storage, stack/capacity calculations and carry weight
FInventoryList / FRepInventoryDataFast Array serialization and slot receive notifications
UMG widgets and UI libraryAsset presentation, drag/drop intent and visual prediction
Project integrationServer RPCs, authorization, gameplay actions and persistence

The operation layer is synchronous after initialization: a wrapper constructs FInventoryOpContext and calls RunOperation on the local manager. The context is neither replicated nor a queued transaction. Network transport is separate from this call.


Ownership and Resolution​

The subsystem owns a manager through UPROPERTY. It holds ItemIDLookup and DataBaseByItemID. The manager reads soft databases, which reference hard item masters. Actors own inventory components; the component sets InventoryData.Owner to itself in BeginPlay so receive callbacks can notify I_FastArrayListener.

GetInventoryCompByTag searches the supplied Pawn's interface components and then its PlayerState's interface components. Exact matching selects the first matching component. This is not a globally registered component registry or a world-actor lookup.


Definition Versus Instance​

The replicated entry is a minimal stack record. Item definitions, presentation assets and per-item-type metadata are resolved locally from its ItemID. Each endpoint therefore needs matching configured content. GUID identity belongs to the entry, not to each unit in a multi-item stack.

See Operation Flow, Replication, Data Assets and Subsystem API. The architecture described in the PDF includes stronger transaction guarantees than the current implementation; Implementation Limits is part of this reference.