INetwork

C++
struct INetwork {
  enum ENetwork_Multithreading_Mode {
    NETWORK_MT_OFF = 0,
    NETWORK_MT_PRIORITY_NORMAL,
    NETWORK_MT_PRIORITY_HIGH
  };
  enum ENetContextCreationFlags {
    eNCCF_Multiplayer = BIT(0)
  };
};
File

INetwork.h

Description

Main access point for creating Network objects.

INetwork::ENetContextCreationFlags Enumeration
C++
enum ENetContextCreationFlags {
  eNCCF_Multiplayer = BIT(0)
};
File

INetwork.h

INetwork::ENetwork_Multithreading_Mode Enumeration
C++
enum ENetwork_Multithreading_Mode {
  NETWORK_MT_OFF = 0,
  NETWORK_MT_PRIORITY_NORMAL,
  NETWORK_MT_PRIORITY_HIGH
};
File

INetwork.h

INetwork::~INetwork Destructor
C++
virtual ~INetwork();
INetwork::AddHostMigrationEventListener Method
C++
virtual void AddHostMigrationEventListener(IHostMigrationEventListener* pListener, const char* pWho, EListenerPriorityType priority) = 0;
INetwork::AddRebroadcasterConnection Method
C++
virtual void AddRebroadcasterConnection(INetChannel* pChannel, TNetChannelID channelID) = 0;
Description

AddRebroadcasterConnection Adds a connection to the rebroadcaster mesh pChannel - pointer to the channel being added channelID - game side channel ID associated with pChannel (if known)

INetwork::BeginCipher Method
C++
virtual TCipher BeginCipher(const uint8* pKey, uint32 keyLength) = 0;
Description

Streamed encryption

INetwork::CleanupPunkBuster Method
C++
virtual void CleanupPunkBuster() = 0;
INetwork::CreateLanQueryListener Method
C++
virtual ILanQueryListener * CreateLanQueryListener(IGameQueryListener * pGameQueryListener) = 0;
Parameters
Parameters
Description
IGameQueryListener * pGameQueryListener
the game half of the query listener, must be non-null (will be released by INetQueryListener).
Return
Pointer to the new INetQueryListener, or NULL on failure.
Description

Queries the local network for games that are running.

INetwork::CreateNetContext Method
C++
virtual INetContext * CreateNetContext(IGameContext * pGameContext, uint32 flags) = 0;
Description

Creates a server context with an associated game context.

INetwork::CreateNub Method
C++
virtual INetNub * CreateNub(const char * address, IGameNub * pGameNub, IGameSecurity * pSecurity, IGameQuery * pGameQuery) = 0;
Parameters
Parameters
Description
const char * address
specify an address for the nub to open, or NULL.
IGameNub * pGameNub
the game half of this nub, must be non-null (will be released by the INetNub).
IGameSecurity * pSecurity
security callback interface (for banning/unbanning ip's, etc, can be null).
IGameQuery * pGameQuery
interface for querying information about the nub (for server snooping, etc, can be null).
Return
Pointer to the new INetNub, or NULL on failure.
Description

Allocates a nub for communication with another computer.

See Also
INetwork::Decrypt Method
C++
virtual void Decrypt(TCipher cipher, uint8* pOutput, const uint8* pInput, uint32 bufferLength) = 0;
INetwork::DecryptBuffer Method (TCipher, uint8*, uint8*, uint32)
C++
virtual void DecryptBuffer(TCipher cipher, uint8* pOutput, const uint8* pInput, uint32 bufferLength) = 0;
INetwork::DecryptBuffer Method (uint8*, uint8*, uint32, uint8*, uint32)
C++
virtual void DecryptBuffer(uint8* pOutput, const uint8* pInput, uint32 bufferLength, const uint8* pKey, uint32 keyLength) = 0;
INetwork::EnableHostMigration Method
C++
virtual void EnableHostMigration(bool bEnabled) = 0;
Description

Host Migration

INetwork::Encrypt Method
C++
virtual void Encrypt(TCipher cipher, uint8* pOutput, const uint8* pInput, uint32 bufferLength) = 0;
INetwork::EncryptBuffer Method (TCipher, uint8*, uint8*, uint32)
C++
virtual void EncryptBuffer(TCipher cipher, uint8* pOutput, const uint8* pInput, uint32 bufferLength) = 0;
Description

When doing block encryption on many buffers with the same key it is much more efficient to create a cipher with BeginCipher then call the following functions as many times as needed before calling EndCipher to free the cipher.

INetwork::EncryptBuffer Method (uint8*, uint8*, uint32, uint8*, uint32)
C++
virtual void EncryptBuffer(uint8* pOutput, const uint8* pInput, uint32 bufferLength, const uint8* pKey, uint32 keyLength) = 0;
Description

Expose Encryption to game Block encryption

INetwork::EndCipher Method
C++
virtual void EndCipher(TCipher cipher) = 0;
INetwork::FastShutdown Method
C++
virtual void FastShutdown() = 0;
Description

Disconnects everything before fast shutdown.

INetwork::GetBandwidthStatistics Method
C++
virtual void GetBandwidthStatistics(SBandwidthStats* const pStats) = 0;
Description

Gets the socket level bandwidth statistics

INetwork::GetHostName Method
C++
virtual const char * GetHostName() = 0;
Description

Gets the local host name.

INetwork::GetLobby Method
C++
virtual ICryLobby* GetLobby() = 0;
INetwork::GetMemoryStatistics Method
C++
virtual void GetMemoryStatistics(ICrySizer * pSizer) = 0;
Description

Gathers memory statistics for the network module.

INetwork::GetNetGameInfo Method
C++
virtual SNetGameInfo GetNetGameInfo() = 0;
INetwork::GetPerformanceStatistics Method
C++
virtual void GetPerformanceStatistics(SNetworkPerformance * pSizer) = 0;
Description

Gathers performance statistics for the network module.

INetwork::GetProfilingStatistics Method
C++
virtual void GetProfilingStatistics(SNetworkProfilingStats* const pStats) = 0;
Description

Gets debug and profiling statistics from network members

INetwork::GetRemoteControlSystemSingleton Method
C++
virtual IRemoteControlSystem* GetRemoteControlSystemSingleton() = 0;
Description

Retrieves RCON system interface.

INetwork::GetService Method
C++
virtual INetworkServicePtr GetService(const char * name) = 0;
Description

Initializes some optional service.

INetwork::GetSimpleHttpServerSingleton Method
C++
virtual ISimpleHttpServer* GetSimpleHttpServerSingleton() = 0;
Description

Retrieves HTTP server interface.

INetwork::HasNetworkConnectivity Method
C++
virtual bool HasNetworkConnectivity() = 0;
INetwork::IsHostMigrationEnabled Method
C++
virtual bool IsHostMigrationEnabled() = 0;
INetwork::IsPbClEnabled Method
C++
virtual bool IsPbClEnabled() = 0;
INetwork::IsPbInstalled Method
C++
virtual bool IsPbInstalled() = 0;
INetwork::IsPbSvEnabled Method
C++
virtual bool IsPbSvEnabled() = 0;
INetwork::IsRebroadcasterEnabled Method
C++
virtual bool IsRebroadcasterEnabled() const = 0;
Description

IsRebroadcasterEnabled Informs the caller if the rebroadcaster is enabled or not

INetwork::NpBeginFunction Method
C++
virtual void NpBeginFunction(SNetProfileStackEntry* entry, bool read) = 0;
INetwork::NpCountReadBits Method
C++
virtual void NpCountReadBits(bool count) = 0;
INetwork::NpEndFunction Method
C++
virtual void NpEndFunction() = 0;
INetwork::NpGetChildFromCurrent Method
C++
virtual bool NpGetChildFromCurrent(const char * name, SNetProfileStackEntry ** entry, bool rmi) = 0;
INetwork::NpGetNullProfile Method
C++
virtual SNetProfileStackEntry* NpGetNullProfile() = 0;
INetwork::NpIsInitialised Method
C++
virtual bool NpIsInitialised() = 0;
INetwork::NpRegisterBeginCall Method
C++
virtual void NpRegisterBeginCall(const char * name, SNetProfileStackEntry** entry, float budge, bool rmi) = 0;
INetwork::PbCaptureConsoleLog Method
C++
virtual void PbCaptureConsoleLog(const char* output, int length) = 0;
Description

EvenBalance - M. Quinn

INetwork::PbClientAutoComplete Method
C++
virtual void PbClientAutoComplete(const char*, int length) = 0;
Description

EvenBalance - M. Quinn

INetwork::PbConsoleCommand Method
C++
virtual bool PbConsoleCommand(const char*, int length) = 0;
Description

EvenBalance - M. Quinn

INetwork::PbServerAutoComplete Method
C++
virtual void PbServerAutoComplete(const char*, int length) = 0;
Description

EvenBalance - M. Quinn

INetwork::Release Method
C++
virtual void Release() = 0;
Description

Releases the interface (and delete the object that implements it).

INetwork::RemoveHostMigrationEventListener Method
C++
virtual void RemoveHostMigrationEventListener(IHostMigrationEventListener* pListener) = 0;
INetwork::RijndaelDecryptBuffer Method
C++
virtual uint32 RijndaelDecryptBuffer(uint8* pOutput, const uint8* pInput, uint32 bufferLength, const uint8* pKey, uint32 keyLength) = 0;
INetwork::RijndaelEncryptBuffer Method
C++
virtual uint32 RijndaelEncryptBuffer(uint8* pOutput, const uint8* pInput, uint32 bufferLength, const uint8* pKey, uint32 keyLength) = 0;
Description

Rijndael encrypts/decrypts in 16 byte blocks so the return value the number of bytes encrypted/decrypted will be less than bufferLength if bufferLength isn't a multiple of 16.

INetwork::SetCDKey Method
C++
virtual void SetCDKey(const char*) = 0;
Description

Sets CD key string for online validation.

INetwork::SetMultithreadingMode Method
C++
virtual void SetMultithreadingMode(ENetwork_Multithreading_Mode threadMode) = 0;
Description

Enables/disables multi threading.

INetwork::SetNetGameInfo Method
C++
virtual void SetNetGameInfo(SNetGameInfo) = 0;
INetwork::StartupPunkBuster Method
C++
virtual void StartupPunkBuster(bool server) = 0;
INetwork::SyncWithGame Method
C++
virtual void SyncWithGame(ENetworkGameSync syncType) = 0;
Parameters
Parameters
Description
blocking
time to block for network input (zero to not block).
Description

Updates all nubs and contexts.

INetwork::TerminateHostMigration Method
C++
virtual void TerminateHostMigration(CrySessionHandle gh) = 0;