Navigation
API > API/Runtime > API/Runtime/Engine
| Name | UNetConnection |
| Type | class |
| Header File | /Engine/Source/Runtime/Engine/Classes/Engine/NetConnection.h |
| Include Path | #include "Engine/NetConnection.h" |
Syntax
UCLASS (CustomConstructor, Abstract, MinimalAPI, Transient, Config=Engine)
class UNetConnection : public UPlayer
Inheritance Hierarchy
- FExec → UPlayer → UNetConnection
- UObjectBase → UObjectBaseUtility → UObject → UPlayer → UNetConnection
Derived Classes
UNetConnection derived class hierarchy
Constructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
UNetConnection
(
const FObjectInitializer& ObjectInitializer |
Constructors and destructors. | Engine/NetConnection.h | |
UNetConnection
(
FVTableHelper& Helper |
Engine/NetConnection.h |
Destructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual ~UNetConnection() |
Destructor | Engine/NetConnection.h |
Enums
Public
| Name | Remarks |
|---|---|
| EWriteBitsDataType | What type of data is being written |
Typedefs
| Name | Type | Remarks | Include Path |
|---|---|---|---|
| FNetCloseResult | UE::Net::FNetCloseResult | Engine/NetConnection.h | |
| FNetConnectionPacketLoss | TPacketLossData< 3 > | Percentage of packets lost during the last StatPeriod | Engine/NetConnection.h |
| FNetResult | UE::Net::FNetResult | Engine/NetConnection.h | |
| FOnConnectionOpened | TMulticastDelegate_ThreeParams< void, UNetConnection *, APlayerController *, UNetConnection * > | Delegate that is called when a connection has been successfully completed on a client and calls HandleClientPlayer(). | Engine/NetConnection.h |
Constants
| Name | Type | Remarks | Include Path |
|---|---|---|---|
| GNetConnectionBeingCleanedUp | class UNetConnection * | @hack: set to net connection currently inside CleanUp(), for HasClientLoadedCurrentWorld() to be able to find it during PlayerController destruction, since we clear its Player before destroying it. | Engine/NetConnection.h |
Variables
Public
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| AllowMerge | bool | Engine/NetConnection.h | ||
| AnalyticsVars | FNetConnAnalyticsVars | Net Analytics The locally cached/updated analytics variables, for the NetConnection - aggregated upon connection Close | Engine/NetConnection.h | |
| AverageFrameTime | double | The average frame delta time over the last 1 second period. | Engine/NetConnection.h | |
| AvgLag | float | Average lag seen during the last StatPeriod | Engine/NetConnection.h | |
| bLastHasServerFrameTime | bool | Engine/NetConnection.h | ||
| bNeedsByteSwapping | bool | Whether this channel needs to byte swap all data or not | Engine/NetConnection.h | |
| bPendingDestroy | uint32 | Engine/NetConnection.h | ||
| Challenge | FString | Engine/NetConnection.h | ||
| Channels | TArray< TObjectPtr< UChannel > > | Engine/NetConnection.h | ||
| Children | TArray< TObjectPtr< class UChildConnection > > | Child connections for secondary viewports | Engine/NetConnection.h |
|
| ClientLoginState | EClientLoginState::Type | Login state tracking. | Engine/NetConnection.h | |
| ClientResponse | FString | Engine/NetConnection.h | ||
| ClientVisibleLevelNames | TSet< FName > | On the server, the package names of streaming levels that the client has told us it has made visible the server will only replicate references to Actors in visible levels so that it's impossible to send references to Actors the client has not initialized | Engine/NetConnection.h | |
| CountedFrames | int32 | Nb of stats accumulated in CumulativeTime | Engine/NetConnection.h | |
| CumulativeTime | double | Total frames times accumulator | Engine/NetConnection.h | |
| DefaultMaxChannelSize | int32 | Engine/NetConnection.h |
|
|
| Driver | TObjectPtr< class UNetDriver > | Owning net driver | Engine/NetConnection.h | |
| ExpectedClientLoginMsgType | uint8 | Engine/NetConnection.h | ||
| FrameTime | double | Engine/NetConnection.h | ||
| Handler | TUniquePtr< PacketHandler > | PacketHandler, for managing layered handler components, which modify packets as they are sent/received | Engine/NetConnection.h | |
| InBytes | int32 | Bytes sent/received on this connection (accumulated during a StatPeriod) | Engine/NetConnection.h | |
| InBytesPerSecond | int32 | Bytes sent/received on this connection (per second) - these are from previous StatPeriod interval | Engine/NetConnection.h | |
| InitInReliable | int32 | Engine/NetConnection.h | ||
| InitOutReliable | int32 | Engine/NetConnection.h | ||
| InPacketId | int32 | Engine/NetConnection.h | ||
| InPackets | int32 | Packets sent/received on this connection (accumulated during a StatPeriod) | Engine/NetConnection.h | |
| InPacketsLost | int32 | Packets lost on this connection (accumulated during a StatPeriod) | Engine/NetConnection.h | |
| InPacketsPerSecond | int32 | Packets sent/received on this connection (per second) - these are from previous StatPeriod interval | Engine/NetConnection.h | |
| InPacketsThisFrame | int32 | Packets received in the current tick | Engine/NetConnection.h | |
| InReliable | TArray< int32 > | Engine/NetConnection.h | ||
| InTotalBytes | int32 | Total bytes sent/received on this connection | Engine/NetConnection.h | |
| InTotalPackets | int32 | Total packets sent/received on this connection | Engine/NetConnection.h | |
| InTotalPacketsLost | int32 | Total packets lost on this connection | Engine/NetConnection.h | |
| KeepProcessingActorChannelBunchesMap | TMap< FNetworkGUID, TArray< TObjectPtr< class UActorChannel > > > | This holds a list of actor channels that want to fully shutdown, but need to continue processing bunches before doing so | Engine/NetConnection.h | |
| LagAcc | double | Total accumulated lag values during the current StatPeriod | Engine/NetConnection.h | |
| LagCount | int32 | Nb of stats accumulated in LagAcc | Engine/NetConnection.h | |
| LastEnd | FBitWriterMark | Engine/NetConnection.h | ||
| LastGoodPacketRealtime | double | Engine/NetConnection.h | ||
| LastOut | FOutBunch | Engine/NetConnection.h | ||
| LastOutBunch | FOutBunch * | Engine/NetConnection.h | ||
| LastProcessedFrame | uint32 | The last frame where we gathered and processed actors for this connection | Engine/NetConnection.h | |
| LastReceiveRealtime | double | Engine/NetConnection.h | ||
| LastReceiveTime | double | Internal. | Engine/NetConnection.h | |
| LastSendTime | double | Engine/NetConnection.h | ||
| LastStart | FBitWriterMark | Merge info. | Engine/NetConnection.h | |
| LastTickTime | double | Engine/NetConnection.h | ||
| LastTime | double | Monitors frame time | Engine/NetConnection.h | |
| LogCallCount | int32 | Engine/NetConnection.h | ||
| LogCallLastTime | double | Log tracking. | Engine/NetConnection.h | |
| LogSustainedCount | int32 | Engine/NetConnection.h | ||
| LowLevelSendDel | FOnLowLevelSend | Delegate for hooking LowLevelSend | Engine/NetConnection.h | |
| MaxPacket | int32 | Engine/NetConnection.h | ||
| MaxPacketHandlerBits | int32 | The maximum number of bits all packet handlers will reserve | Engine/NetConnection.h | |
| NetAnalyticsData | TNetAnalyticsDataPtr< FNetConnAnalyticsData > | The net analytics data holder for the NetConnection analytics, which is where analytics variables are aggregated upon Close | Engine/NetConnection.h | |
| NumAckBits | int | Number of bits used for acks in the current packet. | Engine/NetConnection.h | |
| NumBunchBits | int | Number of bits used for bunches in the current packet. | Engine/NetConnection.h | |
| NumPacketIdBits | int | Number of bits used for the packet id in the current packet. | Engine/NetConnection.h | |
| NumPaddingBits | int | Number of bits used for padding in the current packet. | Engine/NetConnection.h | |
| OpenChannels | TArray< TObjectPtr< class UChannel > > | Engine/NetConnection.h | ||
| OutAckPacketId | int32 | Engine/NetConnection.h | ||
| OutBytes | int32 | Engine/NetConnection.h | ||
| OutBytesPerSecond | int32 | Engine/NetConnection.h | ||
| OutBytesPerSecondHistory | uint8 | Engine/NetConnection.h | ||
| OutLagPacketId | int32 | Engine/NetConnection.h | ||
| OutLagTime | double | Engine/NetConnection.h | ||
| OutPacketId | int32 | Engine/NetConnection.h | ||
| OutPackets | int32 | Engine/NetConnection.h | ||
| OutPacketsLost | int32 | Engine/NetConnection.h | ||
| OutPacketsPerSecond | int32 | Engine/NetConnection.h | ||
| OutPacketsThisFrame | int32 | Packets sent in the current tick | Engine/NetConnection.h | |
| OutReliable | TArray< int32 > | Engine/NetConnection.h | ||
| OutTotalAcks | int32 | Total acks sent on this connection | Engine/NetConnection.h | |
| OutTotalBytes | int32 | Engine/NetConnection.h | ||
| OutTotalPackets | int32 | Engine/NetConnection.h | ||
| OutTotalPacketsLost | int32 | Engine/NetConnection.h | ||
| OwningActor | TObjectPtr< class AActor > | Reference to controlling actor (usually PlayerController) | Engine/NetConnection.h | |
| PackageMap | TObjectPtr< class UPackageMap > | Package map between local and remote. (negotiates net serialization) | Engine/NetConnection.h | |
| PackageMapClass | TSubclassOf< UPackageMap > | The class name for the PackageMap to be loaded | Engine/NetConnection.h | |
| PacketOverhead | int32 | Negotiated parameters. | Engine/NetConnection.h | |
| PendingOutRec | TArray< int32 > | Engine/NetConnection.h | ||
| PlayerId | FUniqueNetIdRepl | Net id of remote player on this connection. Only valid on client connections (server side). | Engine/NetConnection.h | |
| QueuedBits | int32 | The amount of bits allowed to be sent in a given tick to respect the bandwidth per second net speed. | Engine/NetConnection.h | |
| RawPingInSeconds | double | The raw ping value of the last packet the connection processed | Engine/NetConnection.h | |
| ReceivedRawPacketDel | FOnReceivedRawPacket | Delegate for hooking ReceivedRawPacket | Engine/NetConnection.h | |
| RemoteAddr | TSharedPtr< FInternetAddr > | The remote address of this connection, typically generated from the URL. | Engine/NetConnection.h | |
| RequestURL | FString | Engine/NetConnection.h | ||
| ResendAllDataState | EResendAllDataState | This functionality is used during replay checkpoints for example, so we can re-use the existing connection and channels to record a version of each actor and capture all properties that have changed since the actor has been alive... | Engine/NetConnection.h | |
| ResponseId | int32 | Engine/NetConnection.h | ||
| SendBuffer | FBitWriter | Packet. | Engine/NetConnection.h | |
| SendBunchHeader | FBitWriter | The singleton buffer for sending bunch header information | Engine/NetConnection.h | |
| SentTemporaries | TArray< TObjectPtr< class AActor > > | This actor is bNetTemporary, which means it should never be replicated after it's initial packet is complete | Engine/NetConnection.h | |
| StatelessConnectComponent | TWeakPtr< StatelessConnectHandlerComponent > | Reference to the PacketHandler component, for managing stateless connection handshakes | Engine/NetConnection.h | |
| StatPeriod | float | Interval between gathering stats | Engine/NetConnection.h | |
| StatUpdateTime | double | Stat display. | Engine/NetConnection.h | |
| TickCount | int32 | Count of ticks. | Engine/NetConnection.h | |
| TimeSensitive | bool | Engine/NetConnection.h | ||
| TotalDelayedRPCs | int32 | Delayed RPCs and the total average frame delay | Engine/NetConnection.h | |
| TotalDelayedRPCsFrameCount | int32 | Engine/NetConnection.h | ||
| URL | FURL | Engine/NetConnection.h | ||
| ViewTarget | TObjectPtr< class AActor > | The actor that is currently being viewed/controlled by the owning controller | Engine/NetConnection.h |
Protected
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| ActorChannels | FActorChannelMap | Engine/NetConnection.h | ||
| ActorsStarvedByClassTimeMap | TMap< FString, TArray< float > > | A map of class names to arrays of time differences between replication of actors of that class for each connection | Engine/NetConnection.h | |
| AverageJitterInMS | float | Jitter represents the average time divergence of all sent packets. | Engine/NetConnection.h | |
| bAllowExistingChannelIndex | bool | Engine/NetConnection.h | ||
| bAutoFlush | bool | Engine/NetConnection.h | ||
| bConnectionPendingCloseDueToReplicationFailure | bool | True if we are pending close due to unrecoverable replication errors. | Engine/NetConnection.h | |
| bConnectionPendingCloseDueToSocketSendFailure | bool | True if we are pending close due to a socket failure during send | Engine/NetConnection.h | |
| bFlushedNetThisFrame | bool | Set to true after a packet is flushed (sent) and reset at the end of the connection's Tick. | Engine/NetConnection.h | |
| bFlushingPacketOrderCache | bool | Whether or not PacketOrderCache is presently being flushed | Engine/NetConnection.h | |
| bForceInitialDirty | uint32 | Engine/NetConnection.h | ||
| bHasWarnedAboutChannelLimit | bool | True if we've hit the actor channel limit and logged a warning about it | Engine/NetConnection.h | |
| bIgnoreActorBunches | bool | Engine/NetConnection.h | ||
| bIgnoreReservedChannels | bool | Engine/NetConnection.h | ||
| bInternalAck | uint32 | Engine/NetConnection.h | ||
| bIsOSReceiveTimeLocal | bool | Engine/NetConnection.h | ||
| bLoggedFlushNetQueuedBitsOverflow | bool | Used to limit logging when we detect QueuedBits overflow | Engine/NetConnection.h | |
| bReceivedCloseReason | bool | Whether or not this NetConnection has already received an NMT_CloseReason message | Engine/NetConnection.h | |
| bReplay | uint32 | Engine/NetConnection.h | ||
| bReserveDestroyedChannels | bool | Engine/NetConnection.h | ||
| bSendBufferHasDummyPacketInfo | bool | Did we write the dummy PacketInfo in the current SendBuffer | Engine/NetConnection.h | |
| bUnlimitedBunchSizeAllowed | uint32 | Engine/NetConnection.h | ||
| ChannelIndexMap | TMap< int32, int32 > | Track remapped channel index values when replay flag is set | Engine/NetConnection.h | |
| ChannelRecord | FWrittenChannelsRecord | Per packet bookkeeping of written channelIds | Engine/NetConnection.h | |
| ChannelsToTick | TArray< TObjectPtr< UChannel > > | The channels that need ticking. | Engine/NetConnection.h | |
| ChildrenLookup | TMap< int32, TObjectPtr< class UChildConnection > > | Engine/NetConnection.h |
|
|
| ClientHandshakeId | uint32 | An optional unique identifier set by the client when establishing a connection. | Engine/NetConnection.h | |
| ClientMakingVisibleLevelNames | TSet< FName > | On the server, the package names of streaming levels that the client has told us it is making visible | Engine/NetConnection.h | |
| ClientPendingStreamingStatusRequest | TMap< FName, FNetLevelVisibilityTransactionId > | This is used to track any pending streaming status requests the server has sent | Engine/NetConnection.h | |
| ClientVisibleActorOuters | TMap< FName, bool > | This is an acceleration set that is derived from ClientWorldPackageName and ClientVisibleLevelNames. | Engine/NetConnection.h | |
| ClientWorldPackageName | FName | On the server, the world the client has told us it has loaded used to make sure the client has traveled correctly, prevent replicating actors before level transitions are done, etc | Engine/NetConnection.h | |
| ConnectionHandle | UE::Net::FConnectionHandle | Per NetDriver unique ID that can be used instead of passing around a pointer to the connection. | Engine/NetConnection.h | |
| ConnectTimestamp | double | Time when connection request was first initiated | Engine/NetConnection.h | |
| DestroyedStartupOrDormantActorGUIDs | TSet< FNetworkGUID > | The server adds GUIDs to this set for each destroyed actor that does not have a channel but that the client still knows about: startup, dormant, or recently dormant set. | Engine/NetConnection.h | |
| DormantReplicatorSet | UE::Net::Private::FDormantReplicatorHolder | Engine/NetConnection.h | ||
| EngineVersion | FEngineVersion | Engine version information for compatibility | Engine/NetConnection.h | |
| FaultRecovery | TUniquePtr< UE::Net::FNetConnectionFaultRecovery > | NetConnection specific Fault Recovery for attempting to recover from connection faults, before triggering Close | Engine/NetConnection.h | |
| GracefulCloseTimeoutDeadline | double | Driver ElapsedTime at which a graceful close will time out and terminate. | Engine/NetConnection.h | |
| HasDirtyAcks | uint32 | Keep old behavior where we send a packet with only acks even if we have no other outgoing data if we got incoming data | Engine/NetConnection.h | |
| HeaderMarkForPacketInfo | FBitWriterMark | Stores the bit number where we wrote the dummy packet info in the packet header | Engine/NetConnection.h | |
| IgnoredBunchChannels | TSet< int32 > | Set of channels we may need to ignore when processing a delta checkpoint | Engine/NetConnection.h | |
| IgnoredBunchGuids | TSet< FNetworkGUID > | Set of guids we may need to ignore when processing a delta checkpoint | Engine/NetConnection.h | |
| IgnoringChannels | TMap< int32, FNetworkGUID > | Tracks channels that we should ignore when handling special demo data. | Engine/NetConnection.h | |
| InPacketsLossPercentage | FNetConnectionPacketLoss | Engine/NetConnection.h | ||
| InternalAck | uint32 | Engine/NetConnection.h | ||
| InTotalHandlerPackets | int32 | Total packets received on this connection, including PacketHandler | Engine/NetConnection.h | |
| LastNotifiedPacketId | int32 | Full PacketId of last sent packet that we have received notification for (i.e. we know if it was delivered or not). | Engine/NetConnection.h | |
| LastOSReceiveTime | FPacketTimestamp | Engine/NetConnection.h | ||
| LastRecvAckTimestamp | double | The last time an ack was received | Engine/NetConnection.h | |
| NetConnectionHistogram | FHistogram | Histogram of the received packet time | Engine/NetConnection.h | |
| NetPing | TPimplPtr< UE::Net::FNetPing > | Ping collection and calculation | Engine/NetConnection.h | |
| NetworkCustomVersions | FCustomVersionContainer | Engine/NetConnection.h | ||
| NextServerNetPlayerIndex | int32 | Engine/NetConnection.h | ||
| OnConnectionOpened | FOnConnectionOpened | Engine/NetConnection.h | ||
| OutFirstAckPacketId | int32 | Engine/NetConnection.h | ||
| OutgoingBunches | TArray< FOutBunch * > | This is only used in UChannel::SendBunch. | Engine/NetConnection.h | |
| OutPacketsLossPercentage | FNetConnectionPacketLoss | Engine/NetConnection.h | ||
| OutTotalNotifiedPackets | uint32 | Count the number of notified packets, i.e. packets that we know if they are delivered or not. | Engine/NetConnection.h | |
| PackageVersionLicenseeUE | int32 | Licensee package version for compatibility | Engine/NetConnection.h | |
| PackageVersionUE | FPackageFileVersion | Engine package version for compatibility | Engine/NetConnection.h | |
| PacketAnalytics | FNetConnectionPacketAnalytics | Engine/NetConnection.h | ||
| PacketNotify | FNetPacketNotify | Sequence data used to implement reliability | Engine/NetConnection.h | |
| PacketOrderCache | TOptional< TCircularBuffer< TUniquePtr< FBitReader > > > | Buffer of partially read (post-PacketHandler) sequenced packets, which are waiting for a missing packet/sequence | Engine/NetConnection.h | |
| PacketOrderCacheCount | int32 | The current number of valid packets in PacketOrderCache | Engine/NetConnection.h | |
| PacketOrderCacheStartIdx | int32 | The current start index for PacketOrderCache | Engine/NetConnection.h | |
| PendingGracefulCloseResult | TPimplPtr< UE::Net::FNetResult, EPimplPtrMode::DeepCopy > | Stored close reason from a GracefulClose call, to be used in the actual Close | Engine/NetConnection.h | |
| PendingUpdateLevelVisibility | TMap< FName, FUpdateLevelVisibilityLevelInfo > | This is used to capture visibility updates while the server is in transition and deffer the update until the server has completed the transition | Engine/NetConnection.h | |
| PlayerConnectionFunction | TFunction< class ULocalPlayer *(UNetConnection *, APlayerController *)> | Engine/NetConnection.h | ||
| PlayerOnlinePlatformName | FName | Online platform ID of remote player on this connection. | Engine/NetConnection.h | |
| PreviousJitterTimeDelta | int32 | The difference between the send and receive clock time of the last received packet | Engine/NetConnection.h | |
| PreviousPacketSendTimeInS | double | Timestamp of the last packet sent | Engine/NetConnection.h | |
| RepContextActor | AActor * | Only set temporarily during the frame, should not need to be tracked for gc | Engine/NetConnection.h | |
| RepContextLevel | ULevel * | Engine/NetConnection.h | ||
| ReplicationConnectionDriver | UReplicationConnectionDriver * | Engine/NetConnection.h | ||
| ReservedChannels | TSet< int32 > | Set of channel index values to reserve so GetFreeChannelIndex won't use them | Engine/NetConnection.h | |
| RPCDoS | TUniquePtr< FRPCDoSDetection > | RPC/Replication code DoS detection | Engine/NetConnection.h | |
| SaturationAnalytics | FNetConnectionSaturationAnalytics | Engine/NetConnection.h | ||
| State | EConnectionState | Connection information. | Engine/NetConnection.h | |
| StatPeriodCount | int32 | Counts the number of stat samples taken | Engine/NetConnection.h | |
| TotalOutOfOrderPacketsDuplicate | int32 | Stat tracking for the total number of out of order packets that were duplicates | Engine/NetConnection.h | |
| TotalOutOfOrderPacketsLost | int32 | Out of order packet tracking/correction Stat tracking for the total number of out of order packets lost | Engine/NetConnection.h | |
| TotalOutOfOrderPacketsRecovered | int32 | Stat tracking for the total number of out of order packets recovered | Engine/NetConnection.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
FActorChannelMap::TConstIterator ActorChannelConstIterator() |
Engine/NetConnection.h | ||
const FActorChannelMap & ActorChannelMap() |
Engine/NetConnection.h | ||
int32 ActorChannelsNum() |
Engine/NetConnection.h | ||
void AddActorChannel
(
AActor* Actor, |
Engine/NetConnection.h | ||
void AddDestructionInfo
(
FActorDestructionInfo* DestructionInfo |
Engine/NetConnection.h | ||
void AddReservedChannel
(
int32 ChIndex |
Engine/NetConnection.h | ||
virtual void AssertValid() |
Make sure this connection is in a reasonable state. | Engine/NetConnection.h | |
virtual void CleanUp() |
Closes the control channel, cleans up structures, and prepares for deletion | Engine/NetConnection.h | |
void CleanupDormantReplicatorsForActor
(
AActor* Actor |
Remove the reference of all dormant object replicators owned by an actor | Engine/NetConnection.h | |
void CleanupStaleDormantReplicators() |
Removes dormant object replicators from objects now invalid. | Engine/NetConnection.h | |
void ClearDormantFlushedObjectsForActor
(
AActor* Actor |
Clear stored flushed replicated sub-objects for a given actor, generally after replication or when the actor is destroyed | Engine/NetConnection.h | |
virtual bool ClientHasInitializedLevel
(
const ULevel* TestLevel |
Returns whether the client has initialized the given level | Engine/NetConnection.h | |
virtual bool ClientHasInitializedLevelFor
(
const AActor* TestActor |
Returns whether the client has initialized the level required for the given object | Engine/NetConnection.h | |
void Close
(
FNetResult&& CloseReason |
Closes the connection (including sending a close notify across the network) | Engine/NetConnection.h | |
void Close
(
FNetCloseResult&& CloseReason |
Closes the connection (including sending a close notify across the network) | Engine/NetConnection.h | |
void Close () |
Closes the connection (including sending a close notify across the network) NOTE: To be deprecated in the near future. | Engine/NetConnection.h | |
void ConsumePacketAnalytics
(
FNetConnectionPacketAnalytics& Out |
Returns the current packet stability analytics and resets them. | Engine/NetConnection.h | |
| Returns the current delinquency analytics and resets them. | Engine/NetConnection.h | ||
void ConsumeSaturationAnalytics
(
FNetConnectionSaturationAnalytics& Out |
Returns the current saturation analytics and resets them. | Engine/NetConnection.h | |
bool ContainsActorChannel
(
const TWeakObjectPtr< AActor >& Actor |
Engine/NetConnection.h | ||
UChannel * CreateChannelByName
(
const FName& ChName, |
Create a channel. | Engine/NetConnection.h | |
UChildConnection * CreateChild
(
int32* OutNetPlayerIndex |
Create and return a child connection and assign it a new NetPlayerIndex. | Engine/NetConnection.h | |
UChildConnection * CreateChildWithNetPlayerIndex
(
int32 NetPlayerIndex |
Create and return a child connection and assign it a NetPlayerIndex provided as an argument. | Engine/NetConnection.h | |
virtual TSharedPtr< FObjectReplicator > CreateReplicatorForNewActorChannel
(
UObject* Object |
Called by UActorChannel. | Engine/NetConnection.h | |
virtual FString Describe() |
Describe the connection. | Engine/NetConnection.h | |
virtual void DispatchPacket
(
FBitReader& Reader, |
Disassemble and dispatch packet. | Engine/NetConnection.h | |
void EnableEncryption () |
Enables encryption for the underlying encryption packet handler component. | Engine/NetConnection.h | |
void EnableEncryption
(
const FEncryptionData& EncryptionData |
Sets the encryption data and enables encryption. | Engine/NetConnection.h | |
void EnableEncryptionServer
(
const FEncryptionData& EncryptionData |
Sets the encryption data, enables encryption, and sends the encryption ack to the client. | Engine/NetConnection.h | |
void ExecuteOnAllDormantReplicators
(
UE::Net::FExecuteForEachDormantReplicator ExecuteFunction |
Trigger a callback on all dormant replicators of every dormant actor we stored | Engine/NetConnection.h | |
void ExecuteOnAllDormantReplicatorsOfActor
(
AActor* OwnerActor, |
Trigger a callback on all dormant replicators owned by a dormant actor | Engine/NetConnection.h | |
UActorChannel ** FindActorChannel
(
const TWeakObjectPtr< AActor >& Actor |
Engine/NetConnection.h | ||
UActorChannel * FindActorChannelRef
(
const TWeakObjectPtr< AActor >& Actor |
Engine/NetConnection.h | ||
TSharedPtr< FObjectReplicator > FindAndRemoveDormantReplicator
(
AActor* OwnerActor, |
Find a dormant replicator for the channel actor or one of its subobjects. | Engine/NetConnection.h | |
virtual void FlushDormancy
(
AActor* Actor |
Engine/NetConnection.h | ||
| Validate an objects dormancy state and prepare the object for replication again | Engine/NetConnection.h | ||
virtual void FlushNet
(
bool bIgnoreSimulation |
Flushes any pending data, bundling it into a packet and sending it via LowLevelSend() also handles network simulation settings (simulated lag, packet loss, etc) unless bIgnoreSimulation is true | Engine/NetConnection.h | |
void FlushPacketOrderCache
(
bool bFlushWholeCache |
Flush the cache of sequenced packets waiting for a missing packet. | Engine/NetConnection.h | |
void ForcePropertyCompare
(
AActor* Actor |
Forces properties on this actor to do a compare for one frame (rather than share shadow state) | Engine/NetConnection.h | |
| Returns the actor starvation map | Engine/NetConnection.h | ||
virtual int32 GetAddrPort() |
Engine/NetConnection.h | ||
bool GetAutoFlush() |
Engine/NetConnection.h | ||
float GetAverageJitterInMS() |
Current jitter for this connection in milliseconds | Engine/NetConnection.h | |
UChildConnection * GetChildConnectionWithNetPlayerIndex
(
const int32 NetPlayerIndex |
Return the child connection that uses the provided NetPlayerIndex. | Engine/NetConnection.h | |
uint32 GetClientHandshakeId() |
Get the client handshake id for this connection. | Engine/NetConnection.h | |
const TSet< FName > & GetClientMakingVisibleLevelNames() |
Engine/NetConnection.h | ||
FName GetClientWorldPackageName() |
Engine/NetConnection.h | ||
UE::Net::FConnectionHandle GetConnectionHandle() |
Returns a connection identifier which contains both parent connection and child connection information. | Engine/NetConnection.h | |
uint32 GetConnectionId() |
Engine/NetConnection.h | ||
const EConnectionState GetConnectionState() |
Engine/NetConnection.h | ||
| Returns the view target for this connection. | Engine/NetConnection.h | ||
double GetConnectTime() |
Engine/NetConnection.h | ||
TSet< FNetworkGUID > & GetDestroyedStartupOrDormantActorGUIDs() |
Engine/NetConnection.h | ||
UE::Net::FDormantObjectMap * GetDormantFlushedObjectsForActor
(
AActor* Actor |
Retrieve stored set of replicated sub-objects of the given actor at the time of the last dormancy flush This data is cleared when the actor is processed by ReplicateActor | Engine/NetConnection.h | |
const UNetDriver * GetDriver () |
Engine/NetConnection.h | ||
UNetDriver * GetDriver () |
Engine/NetConnection.h | ||
UE::Net::FNetConnectionFaultRecovery * GetFaultRecovery() |
Engine/NetConnection.h | ||
int64 GetFreeSendBufferBits () |
Returns number of bits left in current packet that can be used without causing a flush. | Engine/NetConnection.h | |
const FNetConnectionPacketLoss & GetInLossPercentage() |
Engine/NetConnection.h | ||
int32 GetInTotalHandlerPackets() |
Engine/NetConnection.h | ||
FNetTraceCollector * GetInTraceCollector() |
Engine/NetConnection.h | ||
double GetLastRecvAckTime() |
Engine/NetConnection.h | ||
TFunction< class ULocalPlayer *(UNetConnection *, APlayerController *)> GetLocalPlayerFunction() |
Engine/NetConnection.h | ||
int32 GetMaxSingleBunchSizeBits() |
The maximum number of bits allowed within a single bunch. | Engine/NetConnection.h | |
FHistogram GetNetHistogram() |
Engine/NetConnection.h | ||
UE::Net::FNetPing * GetNetPing() |
Engine/NetConnection.h | ||
bool GetNetPlayerIndex
(
UChildConnection* ChildConnection, |
Return true if the provided child connection belongs to the parent and the NetPlayerIndex output to OutNetPlayerIndex. | Engine/NetConnection.h | |
uint32 GetNetworkCustomVersion
(
const FGuid& VersionGuid |
Engine/NetConnection.h | ||
int32 GetNumTickingChannels() |
Engine/NetConnection.h | ||
FOnConnectionOpened & GetOnConnectionOpened() |
Engine/NetConnection.h | ||
| Returns the OutgoingBunches array, only to be used by UChannel::SendBunch | Engine/NetConnection.h | ||
const FNetConnectionPacketLoss & GetOutLossPercentage() |
Engine/NetConnection.h | ||
uint32 GetOutTotalNotifiedPackets() |
Get the current number of sent packets for which we have received a delivery notification | Engine/NetConnection.h | |
FNetTraceCollector * GetOutTraceCollector() |
Engine/NetConnection.h | ||
const FNetConnectionPacketAnalytics & GetPacketAnalytics() |
Returns the current packet stability analytics. | Engine/NetConnection.h | |
uint32 GetParentConnectionId() |
If this is a child connection it will return the topmost parent coonnection ID, otherwise it will return its own ID. | Engine/NetConnection.h | |
bool GetPendingCloseDueToReplicationFailure() |
Engine/NetConnection.h | ||
| Returns the online platform name for the player on this connection. | Engine/NetConnection.h | ||
const FNetQueuedActorDelinquencyAnalytics & GetQueuedActorDelinquencyAnalytics() |
Returns the current delinquency analytics. | Engine/NetConnection.h | |
virtual TSharedPtr< const FInternetAddr > GetRemoteAddr () |
Return the platform specific FInternetAddr type, containing this connections address. | Engine/NetConnection.h | |
AActor * GetRepContextActor() |
Engine/NetConnection.h | ||
ULevel * GetRepContextLevel() |
Engine/NetConnection.h | ||
UReplicationConnectionDriver * GetReplicationConnectionDriver() |
Engine/NetConnection.h | ||
FRPCDoSDetection * GetRPCDoS() |
Engine/NetConnection.h | ||
const FNetConnectionSaturationAnalytics & GetSaturationAnalytics() |
Returns the current saturation analytics. | Engine/NetConnection.h | |
virtual float GetTimeoutValue() |
Return current timeout value that should be used | Engine/NetConnection.h | |
int32 GetTotalOutOfOrderPackets() |
Get the total number of out of order packets on this connection. | Engine/NetConnection.h | |
int32 GetTotalOutOfOrderPacketsDuplicate() |
Get the total number of out of order packets that were duplicates on this connection. | Engine/NetConnection.h | |
int32 GetTotalOutOfOrderPacketsLost() |
Get the total number of out of order packets lost on this connection. | Engine/NetConnection.h | |
int32 GetTotalOutOfOrderPacketsRecovered() |
Get the total number of out of order packets recovered on this connection. | Engine/NetConnection.h | |
virtual UChildConnection * GetUChildConnection() |
Get the representation of a secondary splitscreen connection that reroutes calls to the parent connection | Engine/NetConnection.h | |
UVoiceChannel * GetVoiceChannel() |
Engine/NetConnection.h | ||
virtual UWorld * GetWorld() |
Get the world the connection belongs to | Engine/NetConnection.h | |
void GracefulClose
(
FNetResult&& CloseReason |
Starts a graceful close. | Engine/NetConnection.h | |
virtual void GracefulClose
(
FNetCloseResult&& CloseReason |
Starts a graceful close. | Engine/NetConnection.h | |
virtual void HandleClientPlayer
(
APlayerController* PC, |
Handle the player controller client | Engine/NetConnection.h | |
void HandleReceiveCloseReason
(
const FString& CloseReasonList |
Handles parsing/validation and logging of NMT_CloseReason messages | Engine/NetConnection.h | |
bool HandleReceiveNetUpgrade
(
uint32 RemoteNetworkVersion, |
Handles receiving NMT_Upgrade messages (including at stateless handshake level) | Engine/NetConnection.h | |
bool HasReceivedClientPacket() |
Whether or not a client packet has been received - used serverside, to delay any packet sends | Engine/NetConnection.h | |
virtual void InitBase
(
UNetDriver* InDriver, |
Initialize common settings for this connection instance | Engine/NetConnection.h | |
virtual void InitConnection
(
UNetDriver* InDriver, |
Initializes an "addressless" connection with the passed in settings | Engine/NetConnection.h | |
virtual void InitHandler() |
Initializes the PacketHandler | Engine/NetConnection.h | |
virtual void InitLocalConnection
(
UNetDriver* InDriver, |
Initialize this connection instance to a remote source | Engine/NetConnection.h | |
virtual void InitRemoteConnection
(
UNetDriver* InDriver, |
Initialize this connection instance from a remote source | Engine/NetConnection.h | |
virtual void InitSendBuffer() |
Resets the FBitWriter to its default state | Engine/NetConnection.h | |
virtual void InitSequence
(
int32 IncomingSequence, |
Initializes the sequence numbers for the connection, usually from shared randomized data | Engine/NetConnection.h | |
bool IsClientMsgTypeValid
(
const uint8 ClientMsgType |
This function validates that ClientMsgType is the next expected msg type. | Engine/NetConnection.h | |
bool IsClosingOrClosed () |
Returns true if this connection's state is USOCK_Closing or USOCK_Closed. | Engine/NetConnection.h | |
virtual bool IsEncryptionEnabled() |
Returns true if encryption is enabled for this connection. | Engine/NetConnection.h | |
bool IsForceInitialDirty() |
Engine/NetConnection.h | ||
bool IsInternalAck() |
Engine/NetConnection.h | ||
virtual bool IsNetReady () |
Returns true if the connection is ready to send and has not exceeded the bandwidth limit yet. | Engine/NetConnection.h | |
virtual int32 IsNetReady
(
bool bSaturate |
Return whether this connection is ready for sending. | Engine/NetConnection.h | |
bool IsPacketSequenceWindowFull
(
uint32 SafetyMargin |
Return whether this connection can send packets without exhausting the packet sequence history window, as it could cause packets to be NAKed even when they've been received by the remote peer. | Engine/NetConnection.h | |
bool IsReplay() |
Engine/NetConnection.h | ||
virtual bool IsReplayReady() |
Engine/NetConnection.h | ||
bool IsReservingDestroyedChannels() |
Engine/NetConnection.h | ||
bool IsUnlimitedBunchSizeAllowed () |
Used to allow connections to ignore the bunch size limitation applied before splitting into partial bunch packets, or when receiving partial bunches to reassemble. | Engine/NetConnection.h | |
virtual FString LowLevelDescribe() |
Engine/NetConnection.h | ||
virtual FString LowLevelGetRemoteAddress
(
bool bAppendPort |
Engine/NetConnection.h | ||
virtual void LowLevelSend
(
void* Data, |
Sends a byte stream to the remote endpoint using the underlying socket | Engine/NetConnection.h | |
virtual void NotifyActorChannelCleanedUp
(
UActorChannel* Channel, |
Engine/NetConnection.h | ||
virtual void NotifyActorDestroyed
(
AActor* Actor, |
Called when owning network driver receives NotifyActorDestroyed. | Engine/NetConnection.h | |
virtual void NotifyActorNetGUID
(
UActorChannel* Channel |
Called when an actor channel is open and knows its NetGUID. | Engine/NetConnection.h | |
virtual void NotifyAnalyticsProvider() |
Notification that the NetDriver analytics provider has been updated NOTE: Can also mean disabled, e.g. during hotfix | Engine/NetConnection.h | |
void PopLastStart() |
Pops the LastStart bits off of the send buffer, used for merging bunches | Engine/NetConnection.h | |
void PostTickDispatch() |
Called after Driver.TickDispatch has processed received packets | Engine/NetConnection.h | |
void PreTickDispatch() |
Called before Driver.TickDispatch processes received packets | Engine/NetConnection.h | |
void ReadInput
(
float DeltaSeconds |
Read input | Engine/NetConnection.h | |
void ReceivedNak
(
int32 NakPacketId |
Packet was negatively acknowledged. | Engine/NetConnection.h | |
virtual void ReceivedPacket
(
FBitReader& Reader, |
Handle a packet we just received. | Engine/NetConnection.h | |
virtual void ReceivedRawPacket
(
void* Data, |
Allows the connection to process the raw data that was received | Engine/NetConnection.h | |
virtual FString RemoteAddressToString() |
Gets a unique ID for the connection, this ID depends on the underlying connection For IP connections this is an IP Address and port, for steam this is a SteamID | Engine/NetConnection.h | |
void RemoveActorChannel
(
AActor* Actor |
Actor Channel Accessors | Engine/NetConnection.h | |
void RemoveChild
(
UChildConnection* ChildConnection |
Remove a child connection from internal data structures. | Engine/NetConnection.h | |
void RemoveDestructionInfo
(
FActorDestructionInfo* DestructionInfo |
Engine/NetConnection.h | ||
| Remove any reference to the dormant object replicator | Engine/NetConnection.h | ||
void ResetActorsStarvedByClassTimeMap() |
Clears the actor starvation map | Engine/NetConnection.h | |
void ResetDestructionInfos() |
Engine/NetConnection.h | ||
void ResetGameWorldState() |
Clear all Game specific state. Called during seamless travel | Engine/NetConnection.h | |
void ResetPacketAnalytics() |
Resets the current packet stability analytics. | Engine/NetConnection.h | |
void ResetPacketBitCounts() |
Sets all of the bit-tracking variables to zero. | Engine/NetConnection.h | |
void ResetQueuedActorDelinquencyAnalytics() |
Resets the current delinquency analytics. | Engine/NetConnection.h | |
void ResetSaturationAnalytics() |
Resets the current saturation analytics. | Engine/NetConnection.h | |
void SendChallengeControlMessage
(
const FEncryptionKeyResponse& Response |
Sends the NMT_Challenge message based on encryption response | Engine/NetConnection.h | |
void SendChallengeControlMessage () |
Sends the NMT_Challenge message | Engine/NetConnection.h | |
void SendClientEncryptionAck() |
Sends an NMT_EncryptionAck message | Engine/NetConnection.h | |
void SendCloseReason
(
FNetResult&& CloseReason |
Sends an NMT_CloseReason message, with the specified close reason or close reason chain. | Engine/NetConnection.h | |
void SendCloseReason
(
FNetCloseResult&& CloseReason |
Sends an NMT_CloseReason message, with the specified close reason or close reason chain. | Engine/NetConnection.h | |
int32 SendRawBunch
(
FOutBunch& Bunch, |
Send a raw bunch | Engine/NetConnection.h | |
int32 SendRawBunch
(
FOutBunch& Bunch, |
Engine/NetConnection.h | ||
void SetAllowExistingChannelIndex
(
bool bAllow |
Sets whether we handle opening channels with an index that already exists, used by replays to fast forward the packet stream | Engine/NetConnection.h | |
void SetAutoFlush
(
bool bValue |
Engine/NetConnection.h | ||
void SetClientHandshakeId
(
uint32 InClientHandshakeId |
Set the client handshake id for this connection. | Engine/NetConnection.h | |
virtual void SetClientLoginState
(
const EClientLoginState::Type NewState |
Wrapper for setting the current client login state, so we can trap for debugging, and verbosity purposes. | Engine/NetConnection.h | |
void SetClientWorldPackageName
(
FName NewClientWorldPackageName |
Engine/NetConnection.h | ||
void SetConnectionId
(
uint32 InConnectionId |
Engine/NetConnection.h | ||
void SetConnectionState
(
EConnectionState ConnectionState |
Engine/NetConnection.h | ||
void SetEncryptionData
(
const FEncryptionData& EncryptionData |
Sets the data for the underlying encryption packet handler component, but doesn't modify encryption enabled state. | Engine/NetConnection.h | |
void SetEngineVersion
(
const FEngineVersion& InEngineVersion |
Sets engine version information for compatibility purposes | Engine/NetConnection.h | |
void SetExpectedClientLoginMsgType
(
const uint8 NewType |
Wrapper for setting the current expected client login msg type. | Engine/NetConnection.h | |
void SetForceInitialDirty
(
bool bValue |
Engine/NetConnection.h | ||
void SetIgnoreActorBunches
(
bool bInIgnoreActorBunches, |
Sets whether or not we should ignore bunches for a specific set of NetGUIDs. | Engine/NetConnection.h | |
void SetIgnoreReservedChannels
(
bool bInIgnoreReservedChannels |
Sets whether or not GetFreeChannelIndex should ignore reserved channels Should only be used with InternalAck. | Engine/NetConnection.h | |
void SetInternalAck
(
bool bValue |
Engine/NetConnection.h | ||
void SetLocalPlayerFunction
(
TFunction< class ULocalPlayer*(UNetConnection*, APlayerController*)> GetPlayerFunctio... |
Set a callback that returns a local player to be used by HandleClientPlayer(). | Engine/NetConnection.h | |
void SetNetVersionsOnArchive
(
FArchive& Ar |
Set version information on an archive that can be used for compatibility checks | Engine/NetConnection.h | |
void SetNetworkCustomVersions
(
const FCustomVersionContainer& CustomVersions |
Engine/NetConnection.h | ||
void SetPackageVersionLicenseeUE
(
int32 InPackageVersionLicenseeUE |
Sets the licensee package version for compatibility purposes | Engine/NetConnection.h | |
void SetPackageVersionUE
(
FPackageFileVersion InPackageVersionUE |
Sets the UE package version for compatibility purposes | Engine/NetConnection.h | |
void SetPacketOSReceiveTime
(
const FPacketTimestamp& InOSReceiveTime, |
Sets the OS/NIC level timestamp, for the last packet that was received | Engine/NetConnection.h | |
void SetPendingCloseDueToReplicationFailure() |
Engine/NetConnection.h | ||
void SetPlayerOnlinePlatformName
(
const FName InPlayerOnlinePlatformName |
Sets the PlayerOnlinePlatformName member. | Engine/NetConnection.h | |
void SetReplay
(
bool bValue |
Engine/NetConnection.h | ||
void SetReplicationConnectionDriver
(
UReplicationConnectionDriver* NewReplicationConnectionDriver |
Engine/NetConnection.h | ||
void SetReserveDestroyedChannels
(
bool bInReserveChannels |
Sets whether or not we should track released channel indices, see also SetIgnoreReservedChannels Should only be used with InternalAck. | Engine/NetConnection.h | |
void SetUnlimitedBunchSizeAllowed
(
bool bValue |
Engine/NetConnection.h | ||
bool ShouldReplicateVoicePacketFrom
(
const FUniqueNetId& Sender |
Called to determine if a voice packet should be replicated to this connection or any of its child connections | Engine/NetConnection.h | |
void SlowAssertValid() |
Make sure this connection is in a reasonable state. | Engine/NetConnection.h | |
void StartTickingChannel
(
UChannel* Channel |
Adds the channel to the ticking channels list. | Engine/NetConnection.h | |
void StopTickingChannel
(
UChannel* Channel |
Removes a channel from the ticking list directly | Engine/NetConnection.h | |
void StoreDormantReplicator
(
AActor* OwnerActor, |
Store a replicator to the dormancy map and release its strong pointer to its object | Engine/NetConnection.h | |
void TearDownReplicationConnectionDriver() |
Engine/NetConnection.h | ||
virtual void Tick
(
float DeltaSeconds |
Poll the connection. If it is timed out, close it. | Engine/NetConnection.h | |
bool TrackLogsPerSecond() |
This function tracks the number of log calls per second for this client, and disconnects the client if it detects too many calls are made per second | Engine/NetConnection.h | |
void TrackReplicationForAnalytics
(
const bool bWasSaturated |
Called to notify the connection that we attempted to replicate its actors this frame. | Engine/NetConnection.h | |
FNetLevelVisibilityTransactionId UpdateLevelStreamStatusChangedTransactionId
(
const ULevelStreaming* LevelObject, |
Update FNetLevelVisibilityTransactionId for server instigated level streaming | Engine/NetConnection.h | |
void UpdateLevelVisibility
(
const FUpdateLevelVisibilityLevelInfo& LevelVisibility |
Called by PlayerController to tell connection about client level visibility change | Engine/NetConnection.h | |
virtual void ValidateSendBuffer() |
Validates the FBitWriter to make sure it's not in an error state | Engine/NetConnection.h | |
int32 WriteBitsToSendBuffer
(
const uint8* Bits, |
Appends the passed in data to the SendBuffer to be sent when FlushNet is called | Engine/NetConnection.h |
Overridden from UObject
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual void FinishDestroy() |
Engine/NetConnection.h | ||
virtual void Serialize
(
FArchive& Ar |
Engine/NetConnection.h |
Protected
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
void CleanupDormantActorState() |
Engine/NetConnection.h | ||
void ClearDormantReplicatorsReference() |
Engine/NetConnection.h | ||
virtual void DestroyIgnoredActor
(
AActor* Actor |
Called internally to destroy an actor during replay fast-forward when the actor channel index will be recycled | Engine/NetConnection.h | |
virtual void DestroyOwningActor() |
During cleanup this will destroy the actor owned by this connection (generally a PlayerController) | Engine/NetConnection.h | |
int32 GetLastNotifiedPacketId() |
Return last notified packet id | Engine/NetConnection.h | |
bool GetPendingCloseDueToSocketSendFailure() |
Engine/NetConnection.h | ||
virtual void HandleConnectionTimeout
(
const FString& Error |
This is called whenever a connection has passed the relative time to be considered timed out. | Engine/NetConnection.h | |
void InitChannelData() |
Engine/NetConnection.h | ||
void NotifyConnectionUpdated() |
Notification that information about this connection may have been updated | Engine/NetConnection.h | |
void SetConnectionHandle
(
UE::Net::FConnectionHandle Handle |
Engine/NetConnection.h | ||
void SetPendingCloseDueToSocketSendFailure() |
Engine/NetConnection.h |
Static
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
static void AddReferencedObjects
(
UObject* InThis, |
Engine/NetConnection.h |