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

#include <RepLayout.h>

+ Inheritance diagram for FRepLayout:

Public Member Functions

virtual ~FRepLayout ()
 
FRepStateStaticBuffer CreateShadowBuffer (const FConstRepObjectDataBuffer Source) const
 
TSharedPtr< FReplicationChangelistMgrCreateReplicationChangelistMgr (const UObject *InObject, const ECreateReplicationChangelistMgrFlags CreateFlags) const
 
TUniquePtr< FRepStateCreateRepState (const FConstRepObjectDataBuffer Source, TSharedPtr< FRepChangedPropertyTracker > &InRepChangedPropertyTracker, ECreateRepStateFlags Flags) const
 
void InitChangedTracker (FRepChangedPropertyTracker *ChangedTracker) const
 
bool ReplicateProperties (FSendingRepState *RESTRICT RepState, FRepChangelistState *RESTRICT RepChangelistState, const FConstRepObjectDataBuffer Data, UClass *ObjectClass, UActorChannel *OwningChannel, FNetBitWriter &Writer, const FReplicationFlags &RepFlags) const
 
bool ReceiveProperties (UActorChannel *OwningChannel, UClass *InObjectClass, FReceivingRepState *RESTRICT RepState, UObject *Object, FNetBitReader &InBunch, bool &bOutHasUnmapped, bool &bOutGuidsChanged, const EReceivePropertiesFlags InFlags) const
 
void GatherGuidReferences (FReceivingRepState *RESTRICT RepState, struct FNetDeltaSerializeInfo &Params, TSet< FNetworkGUID > &OutReferencedGuids, int32 &OutTrackedGuidMemoryBytes) const
 
bool MoveMappedObjectToUnmapped (FReceivingRepState *RESTRICT RepState, struct FNetDeltaSerializeInfo &Params, const FNetworkGUID &GUID) const
 
void UpdateUnmappedObjects (FReceivingRepState *RESTRICT RepState, UPackageMap *PackageMap, UObject *Object, struct FNetDeltaSerializeInfo &Params, bool &bCalledPreNetReceive, bool &bOutSomeObjectsWereMapped, bool &bOutHasMoreUnmapped) const
 
void CallRepNotifies (FReceivingRepState *RepState, UObject *Object) const
 
template<ERepDataBufferType DataType>
void ValidateWithChecksum (TConstRepDataBuffer< DataType > Data, FBitArchive &Ar) const
 
uint32 GenerateChecksum (const FRepState *RepState) const
 
template<ERepDataBufferType DstType, ERepDataBufferType SrcType>
bool DiffProperties (TArray< FProperty * > *RepNotifies, TRepDataBuffer< DstType > Destination, TConstRepDataBuffer< SrcType > Source, const EDiffPropertiesFlags Flags) const
 
template<ERepDataBufferType DstType, ERepDataBufferType SrcType>
bool DiffStableProperties (TArray< FProperty * > *RepNotifies, TArray< UObject * > *ObjReferences, TRepDataBuffer< DstType > Destination, TConstRepDataBuffer< SrcType > Source) const
 
void ENGINE_API SendPropertiesForRPC (UFunction *Function, UActorChannel *Channel, FNetBitWriter &Writer, const FConstRepObjectDataBuffer Data) const
 
void ReceivePropertiesForRPC (UObject *Object, UFunction *Function, UActorChannel *Channel, FNetBitReader &Reader, FRepObjectDataBuffer Data, TSet< FNetworkGUID > &UnmappedGuids) const
 
void ENGINE_API BuildSharedSerializationForRPC (const FConstRepObjectDataBuffer Data, UE::Net::FNetTokenStore *NetTokenStore=nullptr)
 
void ENGINE_API ClearSharedSerializationForRPC ()
 
ENGINE_API void SerializePropertiesForStruct (UStruct *Struct, FBitArchive &Ar, UPackageMap *Map, FRepObjectDataBuffer Data, bool &bHasUnmapped, const UObject *OwningObject=nullptr) const
 
ENGINE_API void SerializeObjectReplicatedProperties (UObject *Object, FBitArchive &Ar) const
 
UObjectGetOwner () const
 
void SendProperties_BackwardsCompatible (FSendingRepState *RESTRICT RepState, FRepChangedPropertyTracker *ChangedTracker, const FConstRepObjectDataBuffer Data, UNetConnection *Connection, FNetBitWriter &Writer, TArray< uint16 > &Changed) const
 
bool ReceiveProperties_BackwardsCompatible (UNetConnection *Connection, FReceivingRepState *RESTRICT RepState, FRepObjectDataBuffer Data, FNetBitReader &InBunch, bool &bOutHasUnmapped, const bool bEnableRepNotifies, bool &bOutGuidsChanged, UObject *OwningObject=nullptr) const
 
virtual ENGINE_API void AddReferencedObjects (FReferenceCollector &Collector) override
 
virtual ENGINE_API FString GetReferencerName () const override
 
template<typename T >
T * GetShadowStateValue (FRepShadowDataBuffer Data, const FName PropertyName)
 
template<typename T >
const T * GetShadowStateValue (FConstRepShadowDataBuffer Data, const FName PropertyName) const
 
const ERepLayoutFlags GetFlags () const
 
const bool IsEmpty () const
 
const int32 GetNumParents () const
 
const FPropertyGetParentProperty (int32 Index) const
 
const int32 GetParentArrayIndex (int32 Index) const
 
const int32 GetParentCondition (int32 Index) const
 
const bool IsCustomDeltaProperty (int32 Index) const
 
const uint16 GetCustomDeltaIndexFromPropertyRepIndex (const uint16 PropertyRepIndex) const
 
void CountBytes (FArchive &Ar) const
 
template<ERepDataBufferType DestinationType, ERepDataBufferType SourceType>
bool DiffProperties (TArray< FProperty * > *RepNotifies, TRepDataBuffer< DestinationType > Destination, TConstRepDataBuffer< SourceType > Source, const EDiffPropertiesFlags DiffFlags) const
 
template<ERepDataBufferType DestinationType, ERepDataBufferType SourceType>
bool DiffStableProperties (TArray< FProperty * > *RepNotifies, TArray< UObject * > *ObjReferences, TRepDataBuffer< DestinationType > Destination, TConstRepDataBuffer< SourceType > Source) const
 
- Public Member Functions inherited from FGCObject
 FGCObject ()
 
 FGCObject (const FGCObject &Other)
 
 FGCObject (FGCObject &&Other)
 
 FGCObject (EFlags Flags)
 
virtual ~FGCObject ()
 
FGCObjectoperator= (const FGCObject &)
 
FGCObjectoperator= (FGCObject &&)
 
COREUOBJECT_API void RegisterGCObject ()
 
COREUOBJECT_API void UnregisterGCObject ()
 
virtual bool GetReferencerPropertyName (UObject *Object, FString &OutPropertyName) const
 
- Public Member Functions inherited from TSharedFromThis< FRepLayout >
TSharedRef< FRepLayout, Mode > AsShared ()
 
TSharedRef< FRepLayout const, Mode > AsShared () const
 
TSharedRef< SubobjectType, Mode > AsSharedSubobject (SubobjectType *SubobjectPtr) const
 
TWeakPtr< FRepLayout, Mode > AsWeak ()
 
TWeakPtr< FRepLayout const, Mode > AsWeak () const
 
TWeakPtr< SubobjectType, Mode > AsWeakSubobject (SubobjectType *SubobjectPtr) const
 
void UpdateWeakReferenceInternal (TSharedPtr< SharedPtrType, SharedPtrMode > const *InSharedPtr, OtherType *InObject) const
 
void UpdateWeakReferenceInternal (TSharedRef< SharedRefType, SharedPtrMode > const *InSharedRef, OtherType *InObject) const
 
UE_FORCEINLINE_HINT bool DoesSharedInstanceExist () const
 

Static Public Member Functions

static ENGINE_API TSharedPtr< FRepLayoutCreateFromClass (UClass *InObjectClass, const UNetConnection *ServerConnection=nullptr, const ECreateRepLayoutFlags Flags=ECreateRepLayoutFlags::None)
 
static ENGINE_API TSharedPtr< FRepLayoutCreateFromStruct (UStruct *InStruct, const UNetConnection *ServerConnection=nullptr, const ECreateRepLayoutFlags Flags=ECreateRepLayoutFlags::None)
 
static TSharedPtr< FRepLayoutCreateFromFunction (UFunction *InFunction, const UNetConnection *ServerConnection=nullptr, const ECreateRepLayoutFlags Flags=ECreateRepLayoutFlags::None)
 
- Static Public Member Functions inherited from FGCObject
static COREUOBJECT_API void StaticInit ()
 

Friends

struct FRepStateStaticBuffer
 
class UPackageMapClient
 
class FNetSerializeCB
 
struct FCustomDeltaPropertyIterator
 

Additional Inherited Members

- Public Types inherited from FGCObject
enum class  EFlags : uint32 { None = 0 , RegisterLater = 1 << 0 , AddStableNativeReferencesOnly = 1 << 1 }
 
- Static Public Attributes inherited from FGCObject
static COREUOBJECT_API UGCObjectReferencerGGCObjectReferencer = nullptr
 
- Protected Member Functions inherited from TSharedFromThis< FRepLayout >
 TSharedFromThis ()
 
 TSharedFromThis (TSharedFromThis const &)
 
UE_FORCEINLINE_HINT TSharedFromThisoperator= (TSharedFromThis const &)
 
 ~TSharedFromThis ()
 
- Static Protected Member Functions inherited from TSharedFromThis< FRepLayout >
static UE_FORCEINLINE_HINT TSharedRef< OtherType, Mode > SharedThis (OtherType *ThisPtr)
 
static UE_FORCEINLINE_HINT TSharedRef< OtherType const, Mode > SharedThis (const OtherType *ThisPtr)
 

Detailed Description

This class holds all replicated properties for a given type (either a UClass, UStruct, or UFunction). Helpers functions exist to read, write, and compare property state.

There is only one FRepLayout for a given type, meaning all instances of the type share the FRepState.

COMMANDS:

All Properties in a RepLayout are represented as Layout Commands. These commands dictate:

  • What the underlying data type is.
  • How the data is laid out in memory.
  • How the data should be serialized.
  • How the data should be compared (between instances of Objects, Structs, etc.).
  • Whether or not the data should trigger notifications on change (RepNotifies).
  • Whether or not the data is conditional (e.g. may be skipped when sending to some or all connections).

Commands are split into 2 main types: Parent Commands (

See also
FRepParentCmd) and Child Commands (
FRepLayoutCmd).

A Parent Command represents a Top Level Property of the type represented by an FRepLayout. A Child Command represents any Property (even nested properties).

E.G., Imagine an Object O, with 4 Properties, CA, DA, I, and S. CA is a fixed size C-Style array. This will generate 1 Parent Command and 1 Child Command for each element in the array. DA is a dynamic array (TArray). This will generate only 1 Parent Command and 1 Child Command, both referencing the array. Additionally, Child Commands will be added recursively for the element type of the array. S is a UStruct. All struct types generate 1 Parent Command for the Struct Property. Additionally: If the struct has a native NetSerialize method then it will generate 1 Child Command referencing the struct. If the struct has a native NetDeltaSerialize method then it will generate no Child Commands. All other structs will recursively generate Child Commands for each nested Net Property in the struct. Note, in this case there is no Child Command associated with the top level struct property. I is an integer (or other supported non-Struct type, or object reference). This will generate 1 Parent Command and 1 Child Command.

CHANGELISTS

Along with Layout Commands that describe the Properties in a type, RepLayout uses changelists to know what Properties have changed between frames.

See also
FRepChangedHistory.

Changelists are arrays of Property Handles that describe what Properties have changed, however they don't track the actual values of the Properties.

Changelists can contain "sub-changelists" for arrays. Formally, they can be described as the following grammar:

Terminator          ::= 0
Handle              ::= Integer between 1 ~ 65535
Number              ::= Integer between 0 ~ 65535
Changelist          ::= <Terminator> | <Handle><Changelist> | <Handle><Array-Changelist><Changelist>
Array-Changelist:   ::= <Number><Changelist>

An important distinction is that Handles do not have a 1:1 mapping with RepLayoutCommands. Handles are 1-based (as opposed to 0-based), and track a relative command index within a single level of a changelist. Each Array Command, regardless of the number of child Commands it has, will only be count as a single handle in its owning changelist. Each time we recurse into an Array-Changelist, our handles restart at 1 for that "depth", and they correspond to the Commands associated with the Array's element type.

In order to generate Changelists, Layout Commands are sequentially applied that compare the values of an object's cached state to a object's current state. Any properties that are found to be different will have their handle written into the changelist. This means handles within a changelists are inherently ordered (with arrays inserted whose Handles are also ordered).

When we want to replicate properties for an object, merge together any outstanding changelists and then iterate over it using Layout Commands that serialize the necessary property data.

Receiving is very similar, except the Handles are baked into the serialized data so no explicit changelist is required. As each Handle is read, a Layout Command is applied that serializes the data from the network bunch and applies it to an object.

RETRIES AND RELIABLES

@FSendingRepState maintains a circular buffer that tracks recently sent Changelists (@FRepChangedHistory). These history items track the Changelist alongside the Packet ID that the bunches were sent in.

Once we receive ACKs for all associated packets, the history will be removed from the buffer. If NAKs are received for any of the packets, we will merge the changelist into the next set of properties we replicate.

If we receive no NAKs or ACKs for an extended period, to prevent overflows in the history buffer, we will merge the entire buffer into a single monolithic changelist which will be sent alongside the next set of properties.

In both cases of NAKs or no response, the merged changelists will be tracked in the latest history item alongside with other sent properties.

When "net.PartialBunchReliableThreshold" is non-zero and property data bunches are split into partial bunches above the threshold, we will not generate a history item. Instead, we will rely on the reliable bunch framework for resends and replication of the Object will be completely paused until the property bunches are acknowledged. However, this will not affect other history items since they are still unreliable.

Constructor & Destructor Documentation

◆ ~FRepLayout()

FRepLayout::~FRepLayout ( )
virtual

Member Function Documentation

◆ AddReferencedObjects()

void FRepLayout::AddReferencedObjects ( FReferenceCollector Collector)
overridevirtual

Pure virtual that must be overloaded by the inheriting class. Use this method to serialize any UObjects contained that you wish to keep around.

Parameters
CollectorThe collector of referenced objects.

Implements FGCObject.

◆ BuildSharedSerializationForRPC()

void FRepLayout::BuildSharedSerializationForRPC ( const FConstRepObjectDataBuffer  Data,
UE::Net::FNetTokenStore NetTokenStore = nullptr 
)

Builds shared serialization state for a multicast rpc

◆ CallRepNotifies()

void FRepLayout::CallRepNotifies ( FReceivingRepState RepState,
UObject Object 
) const

Fire any RepNotifies that have been queued for an object while receiving properties.

Parameters
RepStateThe ReceivingRepState associated with the Object. This is expected to be valid.
ObjectThe Object that received properties.

◆ ClearSharedSerializationForRPC()

void FRepLayout::ClearSharedSerializationForRPC ( )

Clears shared serialization state for a multicast rpc

◆ CountBytes()

void FRepLayout::CountBytes ( FArchive Ar) const

◆ CreateFromClass()

TSharedPtr< FRepLayout > FRepLayout::CreateFromClass ( UClass InObjectClass,
const UNetConnection ServerConnection = nullptr,
const ECreateRepLayoutFlags  Flags = ECreateRepLayoutFlags::None 
)
static

Creates a new FRepLayout for the given class.

◆ CreateFromFunction()

TSharedPtr< FRepLayout > FRepLayout::CreateFromFunction ( UFunction InFunction,
const UNetConnection ServerConnection = nullptr,
const ECreateRepLayoutFlags  Flags = ECreateRepLayoutFlags::None 
)
static

Creates a new FRepLayout for the given function.

◆ CreateFromStruct()

TSharedPtr< FRepLayout > FRepLayout::CreateFromStruct ( UStruct InStruct,
const UNetConnection ServerConnection = nullptr,
const ECreateRepLayoutFlags  Flags = ECreateRepLayoutFlags::None 
)
static

Creates a new FRepLayout for the given struct.

◆ CreateReplicationChangelistMgr()

TSharedPtr< FReplicationChangelistMgr > FRepLayout::CreateReplicationChangelistMgr ( const UObject InObject,
const ECreateReplicationChangelistMgrFlags  CreateFlags 
) const

Creates and initializes a new FReplicationChangelistMgr.

Parameters
InObjectThe Object that is being managed.
CreateFlagsFlags modifying how the manager is created.

◆ CreateRepState()

TUniquePtr< FRepState > FRepLayout::CreateRepState ( const FConstRepObjectDataBuffer  Source,
TSharedPtr< FRepChangedPropertyTracker > &  InRepChangedPropertyTracker,
ECreateRepStateFlags  Flags 
) const

Creates and initializes a new FRepState.

This includes:

  • Initializing the ShadowData.
  • Associating and validating the appropriate ChangedPropertyTracker.
  • Building initial ConditionMap.
Parameters
RepStateThe RepState to initialize.
ClassThe class of the object represented by the input memory.
SrcMemory buffer storing object property data.
InRepChangedPropertyTrackerThe PropertyTracker we want to associate with the RepState.
Returns
A new RepState. Note, maybe a a FRepStateBase or FRepStateSending based on parameters.

◆ CreateShadowBuffer()

PRAGMA_ENABLE_DEPRECATION_WARNINGS FRepStateStaticBuffer FRepLayout::CreateShadowBuffer ( const FConstRepObjectDataBuffer  Source) const

Creates and initialize a new Shadow Buffer.

Shadow Data / Shadow States are used to cache property data so that the Object's state can be compared between frames to see if any properties have changed. They are also used on clients to keep track of RepNotify state.

This includes:

  • Allocating memory for all Properties in the class.
  • Constructing instances of each Property.
  • Copying the values of the Properties from given object.
Parameters
SourceMemory buffer storing object property data.

◆ DiffProperties() [1/2]

template<ERepDataBufferType DestinationType, ERepDataBufferType SourceType>
bool FRepLayout::DiffProperties ( TArray< FProperty * > *  RepNotifies,
TRepDataBuffer< DestinationType Destination,
TConstRepDataBuffer< SourceType >  Source,
const EDiffPropertiesFlags  DiffFlags 
) const

◆ DiffProperties() [2/2]

template<ERepDataBufferType DstType, ERepDataBufferType SrcType>
bool FRepLayout::DiffProperties ( TArray< FProperty * > *  RepNotifies,
TRepDataBuffer< DstType >  Destination,
TConstRepDataBuffer< SrcType >  Source,
const EDiffPropertiesFlags  Flags 
) const

Compare all properties between source and destination buffer, and optionally update the destination buffer to match the state of the source buffer if they don't match.

Parameters
RepNotifiesRepNotifies that should be fired if we're changing properties.
DestinationDestination buffer that will be changed if we're changing properties.
SourceSource buffer containing desired property values.
FlagsControls how DiffProperties behaves.
Returns
True if there were any properties with different values.

◆ DiffStableProperties() [1/2]

template<ERepDataBufferType DestinationType, ERepDataBufferType SourceType>
bool FRepLayout::DiffStableProperties ( TArray< FProperty * > *  RepNotifies,
TArray< UObject * > *  ObjReferences,
TRepDataBuffer< DestinationType Destination,
TConstRepDataBuffer< SourceType >  Source 
) const

◆ DiffStableProperties() [2/2]

template<ERepDataBufferType DstType, ERepDataBufferType SrcType>
bool FRepLayout::DiffStableProperties ( TArray< FProperty * > *  RepNotifies,
TArray< UObject * > *  ObjReferences,
TRepDataBuffer< DstType >  Destination,
TConstRepDataBuffer< SrcType >  Source 
) const
See also
DiffProperties

The main difference between this method and DiffProperties is that this method will skip any properties that are:

  • Transient
  • Point to Actors or ActorComponents
  • Point to Objects that are non-stably named for networking.
Parameters
RepNotifiesRepNotifies that should be fired if we're changing properties.
DestinationDestination buffer that will be changed if we're changing properties.
SourceSource buffer containing desired property values.
FlagsControls how DiffProperties behaves.
Returns
True if there were any properties with different values.

◆ GatherGuidReferences()

void FRepLayout::GatherGuidReferences ( FReceivingRepState *RESTRICT  RepState,
struct FNetDeltaSerializeInfo Params,
TSet< FNetworkGUID > &  OutReferencedGuids,
int32 OutTrackedGuidMemoryBytes 
) const

Finds any properties in the Shadow Buffer of the given Rep State that are currently valid (mapped or unmapped) references to other network objects, and retrieves the associated Net GUIDS.

Parameters
RepStateThe RepState whose shadow buffer we'll inspect. This is expected to be valid.
OutReferencedGuidsSet of Net GUIDs being referenced by the RepState.
OutTrackedGuidMemoryBytesTotal memory usage of properties containing GUID references.

◆ GenerateChecksum()

uint32 FRepLayout::GenerateChecksum ( const FRepState RepState) const

◆ GetCustomDeltaIndexFromPropertyRepIndex()

const uint16 FRepLayout::GetCustomDeltaIndexFromPropertyRepIndex ( const uint16  PropertyRepIndex) const

◆ GetFlags()

const ERepLayoutFlags FRepLayout::GetFlags ( ) const
inline

◆ GetNumParents()

const int32 FRepLayout::GetNumParents ( ) const
inline

◆ GetOwner()

UObject * FRepLayout::GetOwner ( ) const
inline

◆ GetParentArrayIndex()

const int32 FRepLayout::GetParentArrayIndex ( int32  Index) const
inline

◆ GetParentCondition()

const int32 FRepLayout::GetParentCondition ( int32  Index) const
inline

◆ GetParentProperty()

const FProperty * FRepLayout::GetParentProperty ( int32  Index) const
inline

◆ GetReferencerName()

FString FRepLayout::GetReferencerName ( ) const
overridevirtual

Overload this method to report a name for your referencer

Implements FGCObject.

◆ GetShadowStateValue() [1/2]

template<typename T >
const T * FRepLayout::GetShadowStateValue ( FConstRepShadowDataBuffer  Data,
const FName  PropertyName 
) const
inline

◆ GetShadowStateValue() [2/2]

template<typename T >
T * FRepLayout::GetShadowStateValue ( FRepShadowDataBuffer  Data,
const FName  PropertyName 
)
inline

Gets a pointer to the value of the given property in the Shadow State.

Returns
A pointer to the property value in the shadow state, or nullptr if the property wasn't found.

◆ InitChangedTracker()

PRAGMA_DISABLE_DEPRECATION_WARNINGS void FRepLayout::InitChangedTracker ( FRepChangedPropertyTracker ChangedTracker) const

◆ IsCustomDeltaProperty()

const bool FRepLayout::IsCustomDeltaProperty ( int32  Index) const
inline

◆ IsEmpty()

const bool FRepLayout::IsEmpty ( ) const
inline

◆ MoveMappedObjectToUnmapped()

bool FRepLayout::MoveMappedObjectToUnmapped ( FReceivingRepState *RESTRICT  RepState,
struct FNetDeltaSerializeInfo Params,
const FNetworkGUID GUID 
) const

Called to indicate that the object referenced by the FNetworkGUID is no longer mapped. This can happen if the Object was destroyed, if its level was streamed out, or for any other reason that may cause the Server (or client) to no longer be able to properly reference the object. Note, it's possible the object may become valid again later.

Parameters
RepStateThe RepState that holds a reference to the object. This is expected to be valid.
GUIDThe Network GUID of the object to unmap.
ParamsDelta Serialization Params used for Custom Delta Properties.

◆ ReceiveProperties()

bool FRepLayout::ReceiveProperties ( UActorChannel OwningChannel,
UClass InObjectClass,
FReceivingRepState *RESTRICT  RepState,
UObject Object,
FNetBitReader InBunch,
bool bOutHasUnmapped,
bool bOutGuidsChanged,
const EReceivePropertiesFlags  InFlags 
) const

Reads all property values from the received buffer, and applies them to the property memory.

Parameters
OwningChannelThe channel of the Actor that owns the object whose properties we're reading.
InObjectClassClass of the object.
RepStateRepState for the object. This is expected to be valid.
DataPointer to memory where read property data should be stored.
InBunchThe data that should be read.
bOutHasUnmappedWhether or not unmapped GUIDs were read.
bOutGuidsChangedWhether or not any GUIDs were changed.
FlagsControls how ReceiveProperties behaves.

◆ ReceiveProperties_BackwardsCompatible()

bool FRepLayout::ReceiveProperties_BackwardsCompatible ( UNetConnection Connection,
FReceivingRepState *RESTRICT  RepState,
FRepObjectDataBuffer  Data,
FNetBitReader InBunch,
bool bOutHasUnmapped,
const bool  bEnableRepNotifies,
bool bOutGuidsChanged,
UObject OwningObject = nullptr 
) const

Currently only used for Replays / with the UDemoNetDriver.

◆ ReceivePropertiesForRPC()

void FRepLayout::ReceivePropertiesForRPC ( UObject Object,
UFunction Function,
UActorChannel Channel,
FNetBitReader Reader,
FRepObjectDataBuffer  Data,
TSet< FNetworkGUID > &  UnmappedGuids 
) const

◆ ReplicateProperties()

bool FRepLayout::ReplicateProperties ( FSendingRepState *RESTRICT  RepState,
FRepChangelistState *RESTRICT  RepChangelistState,
const FConstRepObjectDataBuffer  Data,
UClass ObjectClass,
UActorChannel OwningChannel,
FNetBitWriter Writer,
const FReplicationFlags RepFlags 
) const

Writes out any changed properties for an Object into the given data buffer, and does book keeping for the RepState of the object.

Note, this does not compare properties or send them on the wire, it's only used to serialize properties.

Parameters
RepStateRepState for the object. This is expected to be valid.
RepChangelistStateRepChangelistState for the object.
DataPointer to memory where property data is stored.
ObjectClassClass of the object.
WriterWriter used to store / write out the replicated properties.
RepFlagsFlags used for replication.

◆ SendProperties_BackwardsCompatible()

void FRepLayout::SendProperties_BackwardsCompatible ( FSendingRepState *RESTRICT  RepState,
FRepChangedPropertyTracker ChangedTracker,
const FConstRepObjectDataBuffer  Data,
UNetConnection Connection,
FNetBitWriter Writer,
TArray< uint16 > &  Changed 
) const

Currently only used for Replays / with the UDemoNetDriver.

◆ SendPropertiesForRPC()

void FRepLayout::SendPropertiesForRPC ( UFunction Function,
UActorChannel Channel,
FNetBitWriter Writer,
const FConstRepObjectDataBuffer  Data 
) const
See also
SendProperties.

◆ SerializeObjectReplicatedProperties()

void FRepLayout::SerializeObjectReplicatedProperties ( UObject Object,
FBitArchive Ar 
) const

Serializes all replicated properties of a UObject in or out of an archive (depending on what type of archive it is).

◆ SerializePropertiesForStruct()

void FRepLayout::SerializePropertiesForStruct ( UStruct Struct,
FBitArchive Ar,
UPackageMap Map,
FRepObjectDataBuffer  Data,
bool bHasUnmapped,
const UObject OwningObject = nullptr 
) const

◆ UpdateUnmappedObjects()

void FRepLayout::UpdateUnmappedObjects ( FReceivingRepState *RESTRICT  RepState,
UPackageMap PackageMap,
UObject Object,
struct FNetDeltaSerializeInfo Params,
bool bCalledPreNetReceive,
bool bOutSomeObjectsWereMapped,
bool bOutHasMoreUnmapped 
) const

Attempts to update any unmapped network guids referenced by the RepState. If any guids become mapped, we will update corresponding properties on the given object to point to the referenced object.

Parameters
RepStateThe RepState associated with the Object. This is expected to be valid.
PackageMapThe package map that controls FNetworkGUID associations.
ObjectThe live game object whose properties should be updated if we map any objects.
bOutSomeObjectsWereMappedWhether or not we successfully mapped any references.
bOutHasMoreUnamappedWhether or not there are more unmapped references in the RepState.

◆ ValidateWithChecksum()

template<ERepDataBufferType DataType>
void FRepLayout::ValidateWithChecksum ( TConstRepDataBuffer< DataType >  Data,
FBitArchive Ar 
) const

Friends And Related Symbol Documentation

◆ FCustomDeltaPropertyIterator

friend struct FCustomDeltaPropertyIterator
friend

◆ FNetSerializeCB

friend class FNetSerializeCB
friend

◆ FRepStateStaticBuffer

◆ UPackageMapClient

friend class UPackageMapClient
friend

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