Zum Hauptinhalt springen

Replication Model

UInventoryComponent registers InventoryData and ActualInventoryCarryWeight with DOREPLIFETIME. InventoryData uses FInventoryList's NetDeltaSerialize and FastArrayDeltaSerialize over Entries; carry weight uses OnRep_ActualInventoryCarryWeight to broadcast its old/new values.

The Game Instance subsystem, manager, operation context, item lookup maps and widget objects do not replicate. Clients resolve ItemID against their local database configuration. A replicated entry contains SlotID, ItemID, StackSize and MaxStackSize rather than asset presentation content.


Authority and Network Transport​

Authority checks in common manager helpers protect those entry points. They do not turn a client subsystem call into a server call. Provide an owned project Server RPC and validate client intent there. Direct component mutations and split/merge need additional authority restrictions.

The reviewed properties have no owner-only replication condition. Actor relevancy, replication settings and lifetime determine recipients; do not assume inventories are private simply because they belong to a player.


Snapshot and Delta​

Newly relevant clients need the current entries as initial state. Subsequent changes use Fast Array deltas. These callbacks are state notifications, not a reliable event history of every gameplay action; multiple changes can be represented by a later state. Persist transaction history separately if required.

For UI event details, see Fast Array and Replication Flow. Verify late join, latency, loss, dormancy/relevancy and packaged behavior with the target Unreal build; no such runtime tests were performed here.