UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
FGuidReferences Class Reference

#include <GuidReferences.h>

Public Member Functions

NETCORE_API FGuidReferences (FBitReader &InReader, FBitReaderMark &InMark, const TSet< FNetworkGUID > &InUnmappedGUIDs, const TSet< FNetworkGUID > &InMappedDynamicGUIDs, const int32 InParentIndex, const int32 InCmdIndex, UPackageMap *InPackageMap)
 
 FGuidReferences (FGuidReferencesMap *InArray, const int32 InParentIndex, const int32 InCmdIndex, UPackageMap *InPackageMap)
 
NETCORE_API ~FGuidReferences ()
 
FGuidReferencesoperator= (const FGuidReferences &Other)=delete
 
NETCORE_API FGuidReferences (const FGuidReferences &Other)
 
NETCORE_API FGuidReferencesoperator= (FGuidReferences &&)
 
NETCORE_API FGuidReferences (FGuidReferences &&Other)
 
void CountBytes (FArchive &Ar) const
 
const TSet< FNetworkGUID > & GetUnmappedGUIDs () const
 
NETCORE_API void AddUnmappedGUID (FNetworkGUID InGUID)
 
NETCORE_API void RemoveUnmappedGUID (FNetworkGUID InGUID)
 
NETCORE_API bool UpdateUnmappedGUIDs (UPackageMap *InPackageMap, UObject *OriginalObject, const FProperty *Property, int32 AbsOffset)
 

Public Attributes

int32 ParentIndex
 
int32 CmdIndex
 
int32 NumBufferBits
 
TSet< FNetworkGUIDMappedDynamicGUIDs
 
TArray< uint8Buffer
 
FGuidReferencesMapArray
 

Detailed Description

References to Objects (including Actors, Components, etc.) are replicated as NetGUIDs, since the literal memory pointers will be different across game instances. In these cases, actual replicated data for the Object will be handled elsewhere (either on its own Actor channel, or on its Owning Actor's channel, as a replicated subobject).

As Objects are replicated and received, these GUID References will become "mapped", and the networking system will update the corresponding properties with pointers to the appropriate objects.

As Objects are destroyed (due to game play, actor channels closing, relevancy, etc.), GUID References will be "unmapped", and their corresponding properties will nulled out.

The process of Mapping and Unmapping can happen numerous times for the same object (e.g., if an Actor goes in and out of relevancy repeatedly).

This class helps manage those references for specific replicated properties. A FGuidReferences instance will be created for each Replicated Property that is a reference to an object.

Guid References may also be nested in properties (like dynamic arrays), so we'll recursively track those as well.

Constructor & Destructor Documentation

◆ FGuidReferences() [1/4]

FGuidReferences::FGuidReferences ( FBitReader InReader,
FBitReaderMark InMark,
const TSet< FNetworkGUID > &  InUnmappedGUIDs,
const TSet< FNetworkGUID > &  InMappedDynamicGUIDs,
const int32  InParentIndex,
const int32  InCmdIndex,
UPackageMap InPackageMap 
)

◆ FGuidReferences() [2/4]

FGuidReferences::FGuidReferences ( FGuidReferencesMap InArray,
const int32  InParentIndex,
const int32  InCmdIndex,
UPackageMap InPackageMap 
)
inline

◆ ~FGuidReferences()

FGuidReferences::~FGuidReferences ( )

◆ FGuidReferences() [3/4]

FGuidReferences::FGuidReferences ( const FGuidReferences Other)

◆ FGuidReferences() [4/4]

FGuidReferences::FGuidReferences ( FGuidReferences &&  Other)

Member Function Documentation

◆ AddUnmappedGUID()

void FGuidReferences::AddUnmappedGUID ( FNetworkGUID  InGUID)

Starts tracking InGUID if not already and calls UPackageMap::AddUnmappedNetGUIDReference if bRemapStableSubobjects is enabled.

◆ CountBytes()

void FGuidReferences::CountBytes ( FArchive Ar) const
inline

◆ GetUnmappedGUIDs()

const TSet< FNetworkGUID > & FGuidReferences::GetUnmappedGUIDs ( ) const
inline

Get the set of GUIDs for objects that haven't been loaded / created yet.

◆ operator=() [1/2]

FGuidReferences & FGuidReferences::operator= ( const FGuidReferences Other)
delete

◆ operator=() [2/2]

FGuidReferences & FGuidReferences::operator= ( FGuidReferences &&  Other)

◆ RemoveUnmappedGUID()

void FGuidReferences::RemoveUnmappedGUID ( FNetworkGUID  InGUID)

Stops tracking a GUID and calls UPackageMap::RemoveUnmappedNetGUIDReference if bRemapStableSubobjects is enabled.

◆ UpdateUnmappedGUIDs()

bool FGuidReferences::UpdateUnmappedGUIDs ( UPackageMap InPackageMap,
UObject OriginalObject,
const FProperty Property,
int32  AbsOffset 
)

Called by FRepLayout to update GUID tracking when updating unmapped objects.

Member Data Documentation

◆ Array

FGuidReferencesMap* FGuidReferences::Array

If this FGuidReferences instance is owned by an Array Property that contains nested GUID References, then this will be a valid FGuidReferencesMap containing the nested FGuidReferences.

◆ Buffer

TArray<uint8> FGuidReferences::Buffer

A copy of the last network data read related to this GUID Reference.

◆ CmdIndex

int32 FGuidReferences::CmdIndex

The Property Command index of the actual property that references the GUID.

◆ MappedDynamicGUIDs

TSet<FNetworkGUID> FGuidReferences::MappedDynamicGUIDs

GUIDs for dynamically spawned objects that have already been created.

◆ NumBufferBits

int32 FGuidReferences::NumBufferBits

◆ ParentIndex

int32 FGuidReferences::ParentIndex

The Property Command index of the top level property that references the GUID.


The documentation for this class was generated from the following files: