Navigation
API > API/Runtime > API/Runtime/Engine
Holds the packet simulation settings in one place
| Name | FPacketSimulationSettings |
| Type | struct |
| Header File | /Engine/Source/Runtime/Engine/Classes/Engine/NetDriver.h |
| Include Path | #include "Engine/NetDriver.h" |
Syntax
USTRUCT ()
struct FPacketSimulationSettings
Variables
Public
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| PktBufferBloatInMS | int32 | Time in milliseconds during which outgoing packets will get delayed before being sent all at once. | Engine/NetDriver.h |
|
| PktDup | int32 | When set, will cause calls to FlushNet to duplicate packets. | Engine/NetDriver.h |
|
| PktFrameDelay | int32 | Delays sending packets for a specific number of ticks | Engine/NetDriver.h |
|
| PktIncomingBufferBloatInMS | int32 | Time in milliseconds during which incoming packets will get delayed before being processed all at once. | Engine/NetDriver.h |
|
| PktIncomingFrameDelay | int32 | Delays processing received packets for a specific number of ticks | Engine/NetDriver.h |
|
| PktIncomingLagMax | int32 | The maximum delay in milliseconds to add to incoming packets before they are processed. | Engine/NetDriver.h |
|
| PktIncomingLagMin | int32 | Set a value to add a minimum delay in milliseconds to incoming packets before they are processed. | Engine/NetDriver.h |
|
| PktIncomingLoss | int32 | The ratio of incoming packets that will be dropped to simulate packet loss | Engine/NetDriver.h |
|
| PktJitter | int32 | Causes sent packets to have a variable latency that fluctuates from [PktLagMin] to [PktLagMin+PktJitter] Note that this will cause packet loss on the receiving end. | Engine/NetDriver.h |
|
| PktLag | int32 | When set, will cause calls to FlushNet to delay packets. | Engine/NetDriver.h |
|
| PktLagMax | int32 | Engine/NetDriver.h |
|
|
| PktLagMin | int32 | If set lag values will randomly fluctuate between Min and Max. Ignored if PktLag value is set | Engine/NetDriver.h |
|
| PktLagVariance | int32 | When set, will cause PktLag to use variable lag instead of constant. | Engine/NetDriver.h |
|
| PktLoss | int32 | When set, will cause calls to FlushNet to drop packets. | Engine/NetDriver.h |
|
| PktLossMaxSize | int32 | Sets the maximum size of packets in bytes that will be dropped according to the PktLoss setting. | Engine/NetDriver.h |
|
| PktLossMinSize | int32 | Sets the minimum size of packets in bytes that will be dropped according to the PktLoss setting. | Engine/NetDriver.h |
|
| PktOrder | int32 | When set, will cause calls to FlushNet to change ordering of packets at random. | Engine/NetDriver.h |
|
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
void ApplySettings
(
const FPacketSimulationSettings& NewSettings |
Force new emulation settings and ignore config or cmdline values | Engine/NetDriver.h | |
bool ConfigHelperBool
(
const TCHAR* Name, |
Engine/NetDriver.h | ||
bool ConfigHelperInt
(
const TCHAR* Name, |
Engine/NetDriver.h | ||
void LoadConfig
(
const TCHAR* OptionalQualifier |
Reads in settings from the .ini file : overwrites all previous settings | Engine/NetDriver.h | |
bool LoadEmulationProfile
(
const TCHAR* ProfileName |
Load a preconfigured emulation profile from the .ini Returns true if the given profile existed | Engine/NetDriver.h | |
bool ParseHelper
(
const TCHAR* Cmd, |
Engine/NetDriver.h | ||
bool ParseSettings
(
const TCHAR* Stream, |
Reads the settings from a string: command line or an exec | Engine/NetDriver.h | |
void ResetSettings() |
Engine/NetDriver.h | ||
bool ShouldDropPacketOfSize
(
int32 NumBits |
Tells if a packet fits the size settings to potentially be dropped | Engine/NetDriver.h | |
void ValidateSettings() |
Ensure that settings have proper values | Engine/NetDriver.h |