UNetDriver

Windows
MacOS
Linux

Inheritance Hierarchy

References

Module

Engine

Header

/Engine/Source/Runtime/Engine/Classes/Engine/NetDriver.h

Include

#include "Engine/NetDriver.h"

Syntax

class UNetDriver :
    public UObject,
    public FExec

Variables

Name Description

Public variable

TSet< FObjectRe...

 

AllOwnedReplicators

Public variable

TSharedPtr< FNe...

 

AnalyticsAggregator

Special analytics aggregator tied to AnalyticsProvider - combines analytics from all NetConnections/PacketHandlers, in one event

Public variable

TSharedPtr< IAn...

 

AnalyticsProvider

The analytics provider used by the packet handler

Public variable

int32

 

BadPingThreshold

The point we think the host is cheating or shouldn't be hosting due to crappy network

Public variable

uint32: 1

 

bClampListenServerTickRate

Public variable

bool

 

bCollectNetStats

Collect net stats even if not FThreadStats::IsCollectingData().

Public variable

bool

 

bHasStandbyCheatTriggered

Used to determine whether we've already caught a cheat or not

Public variable

bool

 

bIsPeer

If true then client connections are to other client peers

Public variable

bool

 

bIsStandbyCheckingEnabled

Used to determine if checking for standby cheats should occur

Protected variable

bool

 

bMaySendProperties

Public variable

bool

 

bNeverApplyNetworkEmulationSettings

If true this NetDriver will not apply the network emulation settings that simulate latency and packet loss in non-shippable builds

Public variable

bool

 

bNoTimeouts

If true, ignore timeouts completely. Should be used only in development

Public variable

bool

 

bSkipLocalStats

If true, it assumes the stats are being set by server data

Protected variable

bool

 

bSkipServerReplicateActors

Public variable

TMap< FName, FC...

 

ChannelDefinitionMap

Used for faster lookup of channel definitions by name.

Public variable

TArray< FChanne...

 

ChannelDefinitions

Used to specify available channel types and their associated UClass

Public variable

TArray< UNetCon...

 

ClientConnections

Array of connections to clients (this net driver is a host) - unsorted, and ordering changes depending on actor replication

Public variable

TUniquePtr< Pac...

 

ConnectionlessHandler

Serverside PacketHandler for managing connectionless packets

Public variable

float

 

ConnectionTimeout

Amount of time to wait before considering an established connection timed out.

Public variable

FDDoSDetection

 

DDoS

DDoS detection management

Public variable

bool

 

DebugRelevantActors

Dumps next net update's relevant actors when true

Public variable

TMap< FNetworkG...

 

DestroyedStartupOrDormantActors

The server adds an entry into this map for every actor that is destroyed that join-in-progress clients need to know about, that is, startup actors.

Public variable

TSharedPtr< cla...

 

GuidCache

Public variable

TMap< FNetworkG...

 

GuidToReplicatorMap

Public variable

uint32

 

InBunches

Todo document

Public variable

uint32

 

InBytes

Todo document

Public variable

uint32

 

InBytesPerSecond

Stats for network perf

Public variable

float

 

InitialConnectTimeout

Amount of time to wait for a new net connection to be established before destroying the connection

Public variable

uint32

 

InOutOfOrderPackets

Todo document

Public variable

uint32

 

InPackets

Todo document

Public variable

uint32

 

InPacketsLost

Todo document

Public variable

uint32

 

InTotalBunches

Total bunches received since the net driver's creation

Public variable

uint32

 

InTotalBytes

Total bytes in packets received since the net driver's creation

Public variable

uint32

 

InTotalPackets

Total packets received since the net driver's creation

Public variable

uint32

 

InTotalPacketsLost

Total packets lost that have been sent by clients since the net driver's creation

Public variable

float

 

JoinInProgressStandbyWaitTime

The amount of time to wait before checking a connection for standby issues

Public variable

float

 

KeepAliveTime

Public variable

double

 

LastCleanupTime

Time of last netdriver cleanup pass

Public variable

TArray< TWeakOb...

 

LastNonRelevantActors

Public variable

TArray< TWeakOb...

 

LastPrioritizedActors

These are debug list of actors.

Public variable

TArray< TWeakOb...

 

LastRelevantActors

Public variable

TArray< TWeakOb...

 

LastSentActors

Public variable

double

 

LastTickDispatchRealtime

Last realtime a tick dispatch occurred. Used currently to try and diagnose timeout issues

Public variable

TSharedPtr< FIn...

 

LocalAddr

Local address this net driver is associated with

Public variable

FConnectionMap

 

MappedClientConnections

Map of IP's to NetConnection's - for fast lookup, particularly under DDoS.

Public variable

int32

 

MaxClientRate

Public variable

int32

 

MaxDownloadSize

Public variable

int32

 

MaxInternetClientRate

Public variable

int32

 

MaxNetTickRate

Limit tick rate of replication to allow very high frame rates to still replicate data.

Public variable

TSharedPtr< cla...

 

NetCache

Public variable

UClass *

 

NetConnectionClass

The loaded UClass of the net connection type to use

Public variable

FString

 

NetConnectionClassName

Used to specify the class to use for connections

Public variable

FName

 

NetDriverName

Used to specify the net driver to filter actors with (NAME_None || NAME_GameNetDriver is the default net driver)

Public variable

uint32

 

NetGUIDInBytes

Incoming rate of NetGUID Bunches

Public variable

uint32

 

NetGUIDOutBytes

Outgoing rate of NetGUID Bunches

Public variable

int32

 

NetServerMaxTickRate

Public variable

int32

 

NetTag

Used to track whether a given actor was replicated by the net driver recently

Public variable

FNetworkNotify ...

 

Notify

Interface for communication network state to others (ie World usually, but anything that implements FNetworkNotify)

Protected variable

FDelegateHandle

 

OnLevelAddedToWorldHandle

Protected variable

FDelegateHandle

 

OnLevelRemovedFromWorldHandle

Handles that track our LevelAdded / Removed delegates.

Public variable

uint32

 

OutBunches

Todo document

Public variable

uint32

 

OutBytes

Todo document

Public variable

uint32

 

OutBytesPerSecond

Todo document

Public variable

uint32

 

OutOutOfOrderPackets

Todo document

Public variable

uint32

 

OutPackets

Todo document

Public variable

uint32

 

OutPacketsLost

Todo document

Public variable

uint32

 

OutTotalAcks

Total acks sent since the net driver's creation

Public variable

uint32

 

OutTotalBunches

Total bunches sent since the net driver's creation

Public variable

uint32

 

OutTotalBytes

Total bytes in packets sent since the net driver's creation

Public variable

uint32

 

OutTotalPackets

Total packets sent since the net driver's creation

Public variable

uint32

 

OutTotalPacketsLost

Total packets lost that have been sent by the server since the net driver's creation

Public variable

FPacketSimulati...

 

PacketSimulationSettings

Public variable

float

 

PercentForBadPing

The number of clients with bad ping before triggering the standby code

Public variable

float

 

PercentMissingForRxStandby

The number of clients missing data before triggering the standby code

Public variable

float

 

PercentMissingForTxStandby

Public variable

FDelegateHandle

 

PostTickDispatchDelegateHandle

Public variable

FDelegateHandle

 

PostTickFlushDelegateHandle

Public variable

float

 

ProcessQueuedBunchesCurrentFrameMilliseconds

Tracks the amount of time spent during the current frame processing queued bunches.

Public variable

bool

 

ProfileStats

Public variable

TArray< FDiscon...

 

RecentlyDisconnectedClients

Tracks recently disconnected client IP's, and the disconnect time - so they can be cleaned from MappedClientConnections

Public variable

int32

 

RecentlyDisconnectedTrackingTime

The amount of time, in seconds, that recently disconnected clients should be tracked

Public variable

float

 

RelevantTimeout

Public variable

FProperty *

 

RemoteRoleProperty

Public variable

TMap< FName, FN...

 

RenamedStartupActors

The server adds an entry into this map for every startup actor that has been renamed, and will always map from current name to original name

Public variable

TMap< UObject &...

 

RepChangedPropertyTrackerMap

Maps FRepChangedPropertyTracker to active objects that are replicating properties

Public variable

TMap< TWeakObje...

 

RepLayoutMap

Maps FRepLayout to the respective UClass

Public variable

TMap< UObject &...

 

ReplicationChangeListMap

Maps an object to the respective FReplicationChangelistMgr

Public variable

UClass *

 

ReplicationDriverClass

Public variable

FString

 

ReplicationDriverClassName

Public variable

uint32

 

ReplicationFrame

Used to invalidate properties marked "unchanged" in FRepChangedPropertyTracker's

Public variable

FProperty *

 

RoleProperty

Public variable

int32

 

SendCycles

Timings for Socket::SendTo()

Public variable

FOnSendRPC

 

SendRPCDel

Delegate for hooking ProcessRemoteFunction

Public variable

UNetConnection ...

 

ServerConnection

Connection to the server (this net driver is a client)

Public variable

float

 

ServerTravelPause

Amount of time a server will wait before traveling to next map, gives clients time to receive final RPCs on existing level

Public variable

FShouldSkipRepN...

 

SkipRepNotifiesDel

Delegate for hooking ShouldSkipRepNotifies

Public variable

float

 

SpawnPrioritySeconds

Public variable

float

 

StandbyRxCheatTime

The amount of time without packets before triggering the cheat code

Public variable

float

 

StandbyTxCheatTime

Todo document

Public variable

TWeakPtr< State...

 

StatelessConnectComponent

Reference to the PacketHandler component, for managing stateless connection handshakes

Public variable

float

 

StatPeriod

Interval between gathering stats

Public variable

double

 

StatUpdateTime

Time of last stat update

Public variable

FDelegateHandle

 

TickDispatchDelegateHandle

Handles to various registered delegates

Public variable

FDelegateHandle

 

TickFlushDelegateHandle

Public variable

float

 

TimeoutMultiplierForUnoptimizedBuilds

A multiplier that is applied to the above values when we are running with unoptimized builds (debug) or data (uncooked).

Public variable

uint32

 

TotalRPCsCalled

Total RPCs called since the net driver's creation

Public variable

int32

 

TotalTrackedGuidMemoryBytes

Public variable

TSet< FObjectRe...

 

UnmappedReplicators

Protected variable

FRandomStream

 

UpdateDelayRandomStream

Stream of random numbers to be used by this instance of UNetDriver

Public variable

uint32

 

VoiceBytesRecv

Tracks the total number of voice bytes received

Public variable

uint32

 

VoiceBytesSent

Tracks the total number of voice bytes sent

Public variable

uint32

 

VoiceInPercent

Tracks the voice data percentage of in bound bytes

Public variable

uint32

 

VoiceOutPercent

Tracks the voice data percentage of out bound bytes

Public variable

uint32

 

VoicePacketsRecv

Tracks the total number of voice packets received

Public variable

uint32

 

VoicePacketsSent

Tracks the total number of voice packets sent

Public variable

UWorld *

 

World

World this net driver is associated with

Public variable

UPackage *

 

WorldPackage

Constructors

Name Description

Public function

UNetDriver

(
    const FObjectInitializer& ObjectIn...
)

Public function

UNetDriver

(
    const FObjectInitializer& ObjectIn...
)

Constructors.

Functions

Name Description

Public function

void

 

AddClientConnection

(
    UNetConnection* NewConnection
)

Adds (fully initialized, ready to go) client connection to the ClientConnections list + any other game related setup

Public function

void

 

AddNetworkActor

(
    AActor* Actor
)

Tells the net driver about a networked actor that was spawned

Public function Static

void

 

AddReferencedObjects

(
    UObject* InThis,
    FReferenceCollector& Collector
)

Public function

uint32

 

AllocateConnectionId()

Public function Virtual

void

 

AssertValid()

Make sure this connection is in a reasonable state.

Public function

void

 

CancelAdaptiveReplication

(
    FNetworkObjectInfo& InNetworkActor
)

Stop adaptive replication for the given actor if it's currently throttled.

Public function Virtual

void

 

CleanPackageMaps()

Public function

void

 

CleanupWorldForSeamlessTravel()

Public function

void

 

ConsumeAsyncLoadDelinquencyAnalytics

Returns the current delinquency analytics and resets them.

Public function Virtual

UChildConnec...

 

CreateChild

(
    UNetConnection* Parent
)

Creates a child connection and adds it to the given parent connection

Public function

void

 

CreateInitialClientChannels()

Creates a channel of each type that is set as bInitialClient.

Public function

void

 

CreateInitialServerChannels

(
    UNetConnection* ClientConnecti...
)

Creates a channel of each type that is set as bIniitalServer for the given connection.

Public function Const

bool

 

DidHitchLastFrame()

Public function

void

 

DrawNetDriverDebug()

Draws debug markers in the world based on network state

Public function Const

const FNetwo...

 

FindNetworkObjectInfo

(
    const AActor* InActor
)

Get the network object matching the given Actor.

Public function

FNetworkObje...

 

FindNetworkObjectInfo

(
    const AActor* InActor
)

Get the network object matching the given Actor.

Public function

FNetworkObje...

 

FindOrAddNetworkObjectInfo

(
    const AActor* InActor
)

Get the network object matching the given Actor.

Public function

TSharedPtr< ...

 

FindOrCreateRepChangedPropertyTracker

(
    UObject* Obj
)

Finds a FRepChangedPropertyTracker associated with an object.

Public function

void

 

FlushActorDormancy

(
    AActor* Actor,
    bool bWasDormInitial
)

Flushes actor from NetDriver's dormancy list, but does not change any state on the Actor itself

Public function Virtual

void

 

FlushHandler()

Flushes all packets queued by the connectionless PacketHandler

Public function

void

 

ForceActorRelevantNextUpdate

(
    AActor* Actor
)

Force this actor to be relevant for at least one update

Public function

void

 

ForceAllActorsNetUpdateTime

(
    float NetUpdateTimeOffset,
    TFunctionRef< bool...
)

Public function Virtual

void

 

ForceNetUpdate

(
    AActor* Actor
)

Game code API for updating server Actor Replication State

Public function

void

 

ForcePropertyCompare

(
    AActor* Actor
)

Forces properties on this actor to do a compare for one frame (rather than share shadow state)

Public function

void

 

FreeConnectionId

(
    uint32 Id
)

Public function Virtual Const

AActor *

 

GetActorForGUID

(
    FNetworkGUID InGUID
)

Returns the actor that corresponds to InGUID, if one can be found.

Public function Const

const FNetAs...

 

GetAsyncLoadDelinquencyAnalytics()

Returns the current delinquency analytics.

Public function Const

UNetConnecti...

 

GetConnectionById

(
    uint32 ConnectionId
)

Returns the NetConnection associated with the ConnectionId. Slow.

Public function Const

FString

 

GetDescription()

Public function Const

int32

 

GetDuplicateLevelID()

Returns the level ID/PIE instance ID for this netdriver to use.

Public function Const

double

 

GetElapsedTime()

Public function

TSharedPtr< ...

 

GetFunctionRepLayout

(
    UFunction* Function
)

Creates if necessary, and returns a FRepLayout that maps to the passed in UFunction

Public function Virtual Const

FNetworkGUID

 

GetGUIDForActor

(
    const AActor* InActor
)

Returns the existing FNetworkGUID of InActor, if it has one.

Public function Virtual

TSharedPtr< ...

 

GetLocalAddr()

Public function Const

ENetMode

 

GetNetMode()

Public function Const

uint32

 

GetNetTraceId()

Returns identifier used for NetTrace

Public function

FNetworkObje...

 

GetNetworkObjectList()

Returns the object that manages the list of replicated UObjects.

Public function Const

const FNetwo...

 

GetNetworkObjectList()

Returns the object that manages the list of replicated UObjects.

Public function

TSharedPtr< ...

 

GetObjectClassRepLayout

(
    UClass* InClass
)

Creates if necessary, and returns a FRepLayout that maps to the passed in UClass

Public function

UChannel ...

 

GetOrCreateChannelByName

(
    const FName& ChName
)

Creates a new channel of the specified type name.

Public function Const

uint32

 

GetOutTotalNotifiedPackets()

Get the current number of sent packets for which we have received a delivery notification

Public function

TSharedPtr< ...

 

GetReplicationChangeListMgr

(
    UObject* Object
)

Returns the FReplicationChangelistMgr that is associated with the passed in object, creating one if none exist.

Public function Const

T *

 

GetReplicationDriver()

Public function Const

UReplication...

 

GetReplicationDriver()

Public function Virtual

ISocketSubsy...

 

GetSocketSubsystem()

Get the socket subsytem appropriate for this net driver

Public function

TSharedPtr< ...

 

GetStructRepLayout

(
    UStruct* Struct
)

Creates if necessary, and returns a FRepLayout that maps to the passed in UStruct

Public function Virtual Const

UWorld *

 

GetWorld()

Get the world associated with this net driver

Public function Const

UPackage ...

 

GetWorldPackage()

Public function

bool

 

HandleNetDebugTextCommand

(
    const TCHAR* Cmd,
    FOutputDevice& Ar
)

Public function

bool

 

HandleNetDisconnectCommand

(
    const TCHAR* Cmd,
    FOutputDevice& Ar
)

Public function

bool

 

HandleNetDumpDormancy

(
    const TCHAR* Cmd,
    FOutputDevice& Ar
)

Public function

bool

 

HandleNetDumpServerRPCCommand

(
    const TCHAR* Cmd,
    FOutputDevice& Ar
)

Public function

bool

 

HandleNetFloodCommand

(
    const TCHAR* Cmd,
    FOutputDevice& Ar
)

Public function

bool

 

HandlePackageMapCommand

(
    const TCHAR* Cmd,
    FOutputDevice& Ar
)

Public function

void

 

HandlePacketLossBurstCommand

(
    int32 DurationInMilliseconds
)

Public function

bool

 

HandleSocketsCommand

(
    const TCHAR* Cmd,
    FOutputDevice& Ar
)

Exec command handlers

Public function Const

bool

 

HasReplayConnection()

Whether or not this driver has an IsReplay() connection, updated in Add/RemoveClientConnection

Public function

void

 

IncreaseOutTotalNotifiedPackets()

Increase the current number of sent packets for which we have received a delivery notification

Public function Virtual

bool

 

InitBase

(
    bool bInitAsClient,
    FNetworkNotify* InNotify,
    const FURL& URL,
    bool bReuseAddressAndPort,
    FString& Error
)

Common initialization between server and client connection setup

Public function Virtual

bool

 

InitConnect

(
    FNetworkNotify* InNotify,
    const FURL& ConnectURL,
    FString& Error
)

Initialize the net driver in client mode

Public function Virtual

bool

 

InitConnectionClass()

Initializes the net connection class to use for new connections

Public function Virtual

void

 

InitConnectionlessHandler()

Initialize a PacketHandler for serverside net drivers, for handling connectionless packets

Public function Virtual

void

 

InitDestroyedStartupActors()

Initialize the list of destroyed net startup actors from the current World

Public function Virtual

bool

 

InitListen

(
    FNetworkNotify* InNotify,
    FURL& ListenURL,
    bool bReuseAddressAndPort,
    FString& Error
)

Initialize the network driver in server mode (listener)

Public function

void

 

InitPacketSimulationSettings()

Public function Virtual

bool

 

InitReplicationDriverClass()

Initialized the replication driver class to use for this driver

Protected function Virtual

UChannel ...

 

InternalCreateChannelByName

(
    const FName& ChName
)

Subclasses may override this to customize channel creation.

Protected function

void

 

InternalProcessRemoteFunction

(
    AActor* Actor,
    UObject* SubObject,
    UNetConnection* Connection,
    UFunction* Function,
    void* Parms,
    FOutParmRec* OutParms,
    FFrame* Stack,
    bool bIsServer
)

Public function Static

bool

 

IsAdaptiveNetUpdateFrequencyEnabled()

Returns whether adaptive net frequency is enabled.

Public function Virtual Const

bool

 

IsAvailable()

Returns true if this net driver is valid for the current configuration.

Public function Static

bool

 

IsDormInitialStartupActor

(
    AActor* Actor
)

Public function Const

bool

 

IsKnownChannelName

(
    const FName& ChName
)

Public function Virtual Const

bool

 

IsLevelInitializedForActor

(
    const AActor* InActor,
    const UNetConnection* InConnec...
)

Returns true if this actor is considered to be in a loaded level

Public function Virtual

bool

 

IsNetResourceValid()

Public function Const

bool

 

IsNetworkActorUpdateFrequencyThrottled

(
    const FNetworkObjectInfo& InNetwor...
)

Returns true if adaptive net update frequency is enabled and the given actor is having its update rate lowered from its standard rate.

Public function Const

bool

 

IsNetworkActorUpdateFrequencyThrottled

(
    const AActor* InActor
)

Returns true if adaptive net update frequency is enabled and the given actor is having its update rate lowered from its standard rate.

Public function Virtual Const

bool

 

IsServer()

Public function Const

bool

 

IsSimulatingPacketLossBurst()

Returns true during the duration of a packet loss burst triggered by the net.pktlossburst command.

Public function Virtual

void

 

LowLevelDestroy()

Close socket and Free the memory the OS allocated for this socket

Public function Virtual

FString

 

LowLevelGetNetworkNumber()

Public function Virtual

void

 

LowLevelSend

(
    TSharedPtr< const FInternetAddr > A...,
    void* Data,
    int32 CountBits,
    FOutPacketTraits& Traits
)

Sends a 'connectionless' (not associated with a UNetConection) packet, to the specified address.

Public function Const

const bool

 

MaySendProperties()

Typically, properties will only ever be replicated / sent from Server net drivers.

Public function

void

 

MoveMappedObjectToUnmapped

(
    const UObject* Object
)

Unmap all references to this object, so that if later we receive this object again, we can remap the original references

Public function Const

bool

 

NetObjectIsDynamic

(
    const UObject* Object
)

Public function Virtual

void

 

NotifyActorChannelCleanedUp

(
    UActorChannel* Channel,
    EChannelCloseReason CloseReason
)

Called when an actor channel is cleaned up foor an actor.

Public function Virtual

void

 

NotifyActorChannelOpen

(
    UActorChannel* Channel,
    AActor* Actor
)

Called when an actor channel is remotely opened for an actor.

Public function Virtual

void

 

NotifyActorDestroyed

(
    AActor* Actor,
    bool IsSeamlessTravel
)

Called when a spawned actor is destroyed.

Public function

void

 

NotifyActorDormancyChange

(
    AActor* Actor,
    ENetDormancy OldDormancyState
)

Notifies the NetDriver that the desired Dormancy state for this Actor has changed.

Public function

void

 

NotifyActorFullyDormantForConnection

(
    AActor* Actor,
    UNetConnection* Connection
)

Public function Virtual

void

 

NotifyActorLevelUnloaded

(
    AActor* Actor
)

Called when an actor is being unloaded during a seamless travel or do due level streaming The main point is that it calls the normal NotifyActorDestroyed to destroy the channel on the server but also removes the Actor reference, sets broken flag, and cleans up actor class references on clients.

Public function Virtual

void

 

NotifyActorRenamed

(
    AActor* Actor,
    FName PreviousName
)

Called when an actor is renamed.

Public function Virtual

void

 

NotifyActorTearOff

(
    AActor* Actor
)

Public function Virtual

void

 

NotifyActorTornOff

(
    AActor* Actor
)

Public function

void

 

NotifyRPCProcessed

(
    UFunction* Function,
    UNetConnection* Connection,
    double ElapsedTimeSeconds
)

Called after processing RPC to track time spent

Public function Virtual

void

 

NotifyStreamingLevelUnload

(
    ULevel*
)

Protected function Virtual

void

 

OnLevelAddedToWorld

(
    ULevel* Level,
    UWorld* World
)

Used to handle any NetDriver specific setup when a level has been added to the world.

Protected function Virtual

void

 

OnLevelRemovedFromWorld

(
    ULevel* Level,
    UWorld* World
)

Used to handle any NetDriver specific cleanup once a level has been removed from the world.

Public function

void

 

OnPacketSimulationSettingsChanged()

Public function

void

 

PostSeamlessTravelGarbageCollect()

Public function Virtual

void

 

PostTickDispatch()

PostTickDispatch actions

Public function Virtual

void

 

PostTickFlush()

PostTick actions

Public function

void

 

PreSeamlessTravelGarbageCollect()

Public function

void

 

PrintDebugRelevantActors()

Public function Virtual

void

 

ProcessLocalClientPackets()

Process any local talker packets that need to be sent to the server

Public function Virtual

void

 

ProcessLocalServerPackets()

Process any local talker packets that need to be sent to clients

Public function Virtual

void

 

ProcessRemoteFunction

(
    AActor* Actor,
    UFunction* Function,
    void* Parameters,
    FOutParmRec* OutParms,
    FFrame* Stack,
    UObject* SubObject
)

Process a remote function call on some actor destined for a remote location

Public function

void

 

ProcessRemoteFunctionForChannel

(
    UActorChannel* Ch,
    const FClassNetCache* ClassCac...,
    const FFieldNetCache* FieldCac...,
    UObject* TargetObj,
    UNetConnection* Connection,
    UFunction* Function,
    void* Parms,
    FOutParmRec* OutParms,
    FFrame* Stack,
    const bool IsServer,
    const ERemoteFunctionSendPolicy Sen...,
    EProcessRemoteFunctionFlags& Remot...
)

Public function

void

 

ProcessRemoteFunctionForChannel

(
    UActorChannel* Ch,
    const FClassNetCache* ClassCac...,
    const FFieldNetCache* FieldCac...,
    UObject* TargetObj,
    UNetConnection* Connection,
    UFunction* Function,
    void* Parms,
    FOutParmRec* OutParms,
    FFrame* Stack,
    const bool IsServer,
    const ERemoteFunctionSendPolicy Sen...
)

Process a remote function on given actor channel. This is called by ::ProcessRemoteFunction.

Protected function

void

 

RegisterTickEvents

(
    UWorld* InWorld
)

Register all TickDispatch, TickFlush, PostTickFlush to tick in World

Public function

void

 

ReleaseToChannelPool

(
    UChannel* Channel
)

If the channel's type is pooled, this will add the channel to the pool.

Public function

void

 

RemoveClassRepLayoutReferences

(
    UClass* Class
)

Public function

void

 

RemoveClientConnection

(
    UNetConnection* ClientConnecti...
)

Public function

void

 

RemoveNetworkActor

(
    AActor* Actor
)

Public function Virtual

void

 

ReplicateVoicePacket

(
    TSharedPtr< class FVoicePacket > Vo...,
    UNetConnection* CameFromConn
)

Determines which other connections should receive the voice packet and queues the packet for those connections.

Public function

void

 

ResetAsyncLoadDelinquencyAnalytics()

Resets the current delinquency analytics.

Public function

void

 

ResetElapsedTime()

Public function Virtual

void

 

ResetGameWorldState()

Called during seamless travel to clear all state that was tied to the previous game world (actor lists, etc)

Public function

int64

 

SendDestructionInfo

(
    UNetConnection* Connection,
    FActorDestructionInfo* Destruc...
)

Sends a message to a client to destroy an actor to the client.

Public function Virtual

int32

 

ServerReplicateActors

(
    float DeltaSeconds
)

Called to replicate any relevant actors to the connections contained within this net driver

Public function Virtual

void

 

SetAnalyticsProvider

(
    TSharedPtr< IAnalyticsProvider > In...
)

Sets the analytics provider

Public function

void

 

SetDuplicateLevelID

(
    const int32 InDuplicateLevelID
)

Sets the level ID/PIE instance ID for this netdriver to use.

Public function

void

 

SetNetDriverName

(
    FName NewNetDriverNamed
)

Change the NetDriver's NetDriverName.

Public function

void

 

SetPacketSimulationSettings

(
    const FPacketSimulationSettings& N...
)

Modify the current emulation settings

Public function

void

 

SetReplicationDriver

(
    UReplicationDriver* NewReplica...
)

Explicitly sets the ReplicationDriver instance (you instantiate it and initialize it).

Public function

void

 

SetRoleSwapOnReplicate

(
    AActor* Actor,
    bool bSwapRoles
)

Set whether this actor should swap roles before replicating properties.

Public function Virtual

void

 

SetWorld

(
    UWorld* InWorld
)

Associate a world with this net driver. Disassociates any previous world first.

Public function Virtual Const

bool

 

ShouldCallRemoteFunction

(
    UObject* Object,
    UFunction* Function,
    const FReplicationFlags& RepFlags
)

Returns true if this network driver should execute this remote call locally.

Public function Virtual Const

bool

 

ShouldClientDestroyActor

(
    AActor* Actor
)

Returns true if clients should destroy the actor when the channel is closed.

Public function Virtual Const

bool

 

ShouldClientDestroyTearOffActors()

Returns true if the client should destroy immediately any actor that becomes torn-off

Public function Virtual Const

bool

 

ShouldForwardFunction

(
    AActor* Actor,
    UFunction* Function,
    void* Parms
)

Returns true if this network driver will forward a received remote function call to other active net drivers.

Public function Virtual Const

bool

 

ShouldIgnoreRPCs()

Returns whether or not RPCs processed by this driver should be ignored.

Public function Virtual Const

bool

 

ShouldQueueBunchesForActorGUID

(
    FNetworkGUID InGUID
)

Returns true if actor channels with InGUID should queue up bunches, even if they wouldn't otherwise be queued.

Public function Virtual Const

bool

 

ShouldReceiveRepNotifiesForObject

(
    UObject* Object
)

Returns true if RepNotifies should be checked and generated when receiving properties for the given object.

Public function Virtual Const

bool

 

ShouldReplicateActor

(
    AActor* Actor
)

Returns true if this network driver will replicate the given actor.

Public function Virtual Const

bool

 

ShouldReplicateFunction

(
    AActor* Actor,
    UFunction* Function
)

Returns true if this network driver will handle the remote function call for the given actor.

Public function Virtual Const

bool

 

ShouldSkipRepNotifies()

Returns whether or not properties that are replicating using this driver should not call RepNotify functions.

Public function Virtual

void

 

Shutdown()

Shutdown all connections managed by this net driver

Public function Virtual

void

 

TickDispatch

(
    float DeltaTime
)

Handle time update: read and process packets

Public function Virtual

void

 

TickFlush

(
    float DeltaSeconds
)

ReplicateActors and Flush

Protected function

void

 

UnregisterTickEvents

(
    UWorld* InWorld
)

Unregister all TickDispatch, TickFlush, PostTickFlush to tick in World

Public function Virtual

void

 

UpdateNetworkLagState()

Update the LagState based on a heuristic to determine if we are network lagging

Public function

void

 

UpdateStandbyCheatStatus()

Updates the standby cheat information and causes the dialog to be shown/hidden as needed

Overridden from UObject

Name Description

Public function Virtual

void

 

FinishDestroy()

Called to finish destroying the object.

Public function Virtual

void

 

PostInitProperties()

Called after the C++ constructor and after the properties have been initialized, including those loaded from config.

Public function Virtual

void

 

PostReloadConfig

(
    FProperty* PropertyThatWasLoad...
)

Called from ReloadConfig after the object has reloaded its configuration data.

Public function Virtual

void

 

Serialize

(
    FArchive& Ar
)

Handles reading, writing, and reference collecting using FArchive.

Overridden from FExec

Name Description

Public function Virtual

bool

 

Exec

(
    UWorld* InWorld,
    const TCHAR* Cmd,
    FOutputDevice& Ar
)

Handle exec commands

Classes

Enums

Name

Description

Public enum

ERemoteFunctionSendPolicy

Deprecated Variables

Name Description

Public variable

float

 

Time

Time is being replaced with a double precision value, please use GetElapsedTime() instead.

Help shape the future of Unreal Engine documentation! Tell us how we're doing so we can serve you better.
Take our survey
Dismiss