Worst-case scenario: the UEd Goblin wipes the map and burns down your house.

UE3:OnlineSubsystem (UDK)

From Unreal Wiki, The Unreal Engine Documentation Site
Jump to: navigation, search
UDK Object >> OnlineSubsystem
Package: 
Engine
Direct subclass:
OnlineSubsystemCommonImpl
This class in other games:
UT3

This class holds a set of online interfaces that game code uses to talk with the platform layer's services. The set of services are implemented as interface pointers so that we can mix & match services at run time. This also allows licensees the ability to use part of our base services and provide custom implmentations of others.

Properties[edit]

AccountInterface[edit]

Type: OnlineAccountInterface

The interface to use for creating and/or enumerating account information

AsyncMinCompletionTime[edit]

Type: float

Modifiers: config

Used to introduce latency when communicating with the online layer for testing purposes

BuildIdOverride[edit]

Type: int

Modifiers: config

Used to specify a build override value

bUseBuildIdOverride[edit]

Type: bool

Modifiers: config

Whether to use the override or not

ContentInterface[edit]

Type: OnlineContentInterface

The interface to use for online content

GameInterface[edit]

Type: OnlineGameInterface

The interface to use for creating, searching for, or destroying online games

IniLocPatcherClassName[edit]

Type: string

Modifiers: config

The class to create our patcher instance from

NamedInterfaceDefs[edit]

Type: array<NamedInterfaceDef>

Modifiers: config

The list of named interfaces to automatically create and store

NamedInterfaces[edit]

Type: array<NamedInterface>

Modifiers: private

Holds the set of registered named interfaces

NewsInterface[edit]

Type: OnlineNewsInterface

The interface to use for reading game specific news announcements

PartyChatInterface[edit]

Type: OnlinePartyChatInterface

The interface to use for accessing online party chat methods

Patcher[edit]

Type: IniLocPatcher

Modifiers: transient

The object responsible for patching downloaded INI/loc files

PlayerInterface[edit]

Type: OnlinePlayerInterface

The interface for accessing online player methods

PlayerInterfaceEx[edit]

Type: OnlinePlayerInterfaceEx

The interface for accessing online player extension methods

Sessions[edit]

Type: array<NamedSession>

Modifiers: const, protected

The list of sessions currently managed by the online subsystem

StatsInterface[edit]

Type: OnlineStatsInterface

The interface to use for stats read/write operations

SystemInterface[edit]

Type: OnlineSystemInterface

The interface for accessing system wide network functions

VoiceInterface[edit]

Type: OnlineVoiceInterface

The interface to use for voice communication

Enums[edit]

See OnlineSubsystem enums.

Structs[edit]

See OnlineSubsystem structs.

Functions[edit]

Static native functions[edit]

AreUniqueNetIdsEqual[edit]

static final native noexportheader function bool AreUniqueNetIdsEqual (const out UniqueNetId NetIdA, const out UniqueNetId NetIdB)

Returns:

TRUE if the netids are the same

GetNumSupportedLogins[edit]

static final native function int GetNumSupportedLogins ()

Returns the number of players that can be signed in on this platform

StringToUniqueNetId[edit]

static final native noexportheader function bool StringToUniqueNetId (string UniqueNetIdString, out UniqueNetId out_UniqueId)

Converts a string representing a UniqueNetId into a UniqueNetId struct.

Parameters:

  • UniqueNetIdString - the string containing the text representation of the unique id.
  • out_UniqueId - will receive the UniqueNetId generated from the string.

Returns:

TRUE if the string was successfully converted into a UniqueNetId; FALSE if the string was not a valid UniqueNetId.

UniqueNetIdToString[edit]

static final native noexportheader function string UniqueNetIdToString (const out UniqueNetId IdToConvert)

Generates a string representation of a UniqueNetId struct.

Parameters:

  • IdToConvert - the unique net id that should be converted to a string.

Returns:

the specified UniqueNetId represented as a string.

Other static functions[edit]

DumpGameSettings[edit]

static function DumpGameSettings (const OnlineGameSettings GameSettings)

Logs the game settings object

Parameters:

  • GameSettings - settings to dump

DumpNetIds[edit]

static function DumpNetIds (const out array<UniqueNetIdPlayers, string DebugLabel)

Log list of players' netids for debugging

Native functions[edit]

Init[edit]

native event bool Init ()

Called from engine start up code to allow the subsystem to initialize

Returns:

TRUE if the initialization was successful, FALSE otherwise

GetBuildUniqueId[edit]

native function int GetBuildUniqueId ()

Generates a unique number based off of the current script compilation

Returns:

the unique number from the current script compilation

Events[edit]

Exit[edit]

event Exit ()

Called from the engine shutdown code to allow the subsystem to release any resources that may have been allocated

GetNamedInterface[edit]

event Object GetNamedInterface (name InterfaceName)

Returns the interface object associated with the specified name

Parameters:

  • InterfaceName - the name of the interface to retrieve

Returns:

The object that matches the interface name if found

PostInit[edit]

event bool PostInit ()

Used to trigger any automated tasks that need to happen just after startup

SetAccountInterface[edit]

event bool SetAccountInterface (Object NewInterface)

Called from native code to assign the account interface

Parameters:

  • NewInterface - the object to assign as providing the account interface

Returns:

TRUE if the interface is valid, FALSE otherwise

SetContentInterface[edit]

event bool SetContentInterface (Object NewInterface)

Called from native code to assign the content interface

Parameters:

  • NewInterface - the object to assign as providing the content interface

Returns:

TRUE if the interface is valid, FALSE otherwise

SetGameInterface[edit]

event bool SetGameInterface (Object NewInterface)

Called from native code to assign the game interface

Parameters:

  • NewInterface - the object to assign as providing the game interface

Returns:

TRUE if the interface is valid, FALSE otherwise

SetNamedInterface[edit]

event SetNamedInterface (name InterfaceName, Object NewInterface)

Adds the interface object to the named interface list with the specified name

Parameters:

  • InterfaceName - the name of the interface to add it as
  • NewInterface - the object/interface that is being cached

SetNewsInterface[edit]

event bool SetNewsInterface (Object NewInterface)

Called from native code to assign the news interface

Parameters:

  • NewInterface - the object to assign as providing the news interface

Returns:

TRUE if the interface is valid, FALSE otherwise

SetPartyChatInterface[edit]

event bool SetPartyChatInterface (Object NewInterface)

Called from native code to assign the party chat interface

Parameters:

  • NewInterface - the object to assign as providing the news interface

Returns:

TRUE if the interface is valid, FALSE otherwise

SetPlayerInterface[edit]

event bool SetPlayerInterface (Object NewInterface)

Called from native code to assign the player interface

Parameters:

  • NewInterface - the object to assign as providing the player interface

Returns:

TRUE if the interface is valid, FALSE otherwise

SetPlayerInterfaceEx[edit]

event bool SetPlayerInterfaceEx (Object NewInterface)

Called from native code to assign the extended player interface

Parameters:

  • NewInterface - the object to assign as providing the player interface

Returns:

TRUE if the interface is valid, FALSE otherwise

SetStatsInterface[edit]

event bool SetStatsInterface (Object NewInterface)

Called from native code to assign the stats interface

Parameters:

  • NewInterface - the object to assign as providing the stats interface

Returns:

TRUE if the interface is valid, FALSE otherwise

SetSystemInterface[edit]

event bool SetSystemInterface (Object NewInterface)

Called from native code to assign the system interface

Parameters:

  • NewInterface - the object to assign as providing the system interface

Returns:

TRUE if the interface is valid, FALSE otherwise

SetVoiceInterface[edit]

event bool SetVoiceInterface (Object NewInterface)

Called from native code to assign the voice interface

Parameters:

  • NewInterface - the object to assign as providing the voice interface

Returns:

TRUE if the interface is valid, FALSE otherwise

Other instance functions[edit]

DumpSessionState[edit]

function DumpSessionState ()

Logs the session state for all sessions present

DumpVoiceRegistration[edit]

function DumpVoiceRegistration ()

Logs the list of players that are registered for voice

SetDebugSpewLevel[edit]

function SetDebugSpewLevel (int DebugSpewLevel)

Sets the debug output level for the platform specific API (if applicable)

Parameters:

  • DebugSpewLevel - the level to set