net.MinHandshakeVersion

net.MinHandshakeVersion

#Overview

name: net.MinHandshakeVersion

This variable is created as a Console Variable (cvar).

It is referenced in 2 C++ source files.

#Summary

#References in C++ code

#Callsites

This variable is referenced in the following C++ source code:

#Loc: <Workspace>/Engine/Source/Runtime/Engine/Private/PacketHandlers/StatelessConnectHandlerComponent.cpp:262

Scope (from outer to inner):

file
namespace    UE::Net

Source code excerpt:


	static FAutoConsoleVariableRef CVarNetMinHandshakeVersion(
		TEXT("net.MinHandshakeVersion"),
		MinSupportedHandshakeVersion,
		TEXT("The minimum supported stateless handshake protocol version (numeric)."));

	static FAutoConsoleVariableRef CVarNetCurrentHandshakeVersion(
		TEXT("net.CurrentHandshakeVersion"),
		CurrentHandshakeVersion,

#Loc: <Workspace>/Engine/Source/Runtime/Engine/Private/PacketHandlers/StatelessConnectHandlerComponent.cpp:1820

Scope (from outer to inner):

file
function     void StatelessConnectHandlerComponent::Tick

Source code excerpt:

					// In case the server doesn't support the current handshake version, randomly switch between supported versions - if enabled
					// (we don't know if the server supports the minimum version either, so pick from the full range).
					// It's better for devs to explicitly hotfix the 'net.MinHandshakeVersion' value, instead of relying upon this fallback.
					if (!!CVarNetDoHandshakeVersionFallback.GetValueOnAnyThread() && FMath::RandBool())
					{
						// Decrement the minimum version, based on the number of handshake packets sent - to select for higher supported versions
						const int32 MinVersion = FMath::Max(MinSupportedHandshakeVersion, CurrentHandshakeVersion - SentHandshakePacketCount);

						if (MinVersion != CurrentHandshakeVersion)