Skip to content

Class SpectatorBackend

ClassList > SpectatorBackend

Inherits the following classes: GGPOSession, IPollSink, Udp::Callbacks

Public Functions

Type Name
virtual GGPOErrorCode AddLocalInput (GGPOPlayerHandle player, void * values, int size)
virtual GGPOErrorCode AddPlayer (GGPOPlayer * player, GGPOPlayerHandle * handle)
virtual GGPOErrorCode DisconnectPlayer (GGPOPlayerHandle handle)
virtual GGPOErrorCode DoPoll (int timeout)
virtual GGPOErrorCode GetNetworkStats (FGGPONetworkStats * stats, GGPOPlayerHandle handle)
virtual GGPOErrorCode IncrementFrame (void)
virtual void OnMsg (int connection_id, UdpMsg * msg, int len)
virtual GGPOErrorCode SetDisconnectNotifyStart (int timeout)
virtual GGPOErrorCode SetDisconnectTimeout (int timeout)
virtual GGPOErrorCode SetFrameDelay (GGPOPlayerHandle player, int delay)
SpectatorBackend (GGPOSessionCallbacks * cb, const char * gamename, ConnectionManager * connection_manager, int num_players, int input_size, int connection_id)
virtual GGPOErrorCode SyncInput (void * values, int size, int * disconnect_flags)
virtual ~SpectatorBackend ()

Public Functions inherited from GGPOSession

See GGPOSession

Type Name
virtual GGPOErrorCode AddLocalInput (GGPOPlayerHandle player, void * values, int size) = 0
virtual GGPOErrorCode AddPlayer (GGPOPlayer * player, GGPOPlayerHandle * handle) = 0
virtual GGPOErrorCode Chat (char * text)
virtual GGPOErrorCode DisconnectPlayer (GGPOPlayerHandle handle)
virtual GGPOErrorCode DoPoll (int timeout)
virtual GGPOErrorCode GetNetworkStats (FGGPONetworkStats * stats, GGPOPlayerHandle handle)
virtual GGPOErrorCode IncrementFrame (void)
virtual GGPOErrorCode Logv (const char * fmt, va_list list)
virtual GGPOErrorCode SetDisconnectNotifyStart (int timeout)
virtual GGPOErrorCode SetDisconnectTimeout (int timeout)
virtual GGPOErrorCode SetFrameDelay (GGPOPlayerHandle player, int delay)
virtual GGPOErrorCode SyncInput (void * values, int size, int * disconnect_flags) = 0
virtual GGPOErrorCode TrySynchronizeLocal ()
virtual ~GGPOSession ()

Public Functions inherited from IPollSink

See IPollSink

Type Name
virtual bool OnHandlePoll (void *)
virtual bool OnLoopPoll (void *)
virtual bool OnMsgPoll (void *)
virtual bool OnPeriodicPoll (void *, int)
virtual ~IPollSink ()

Public Functions inherited from Udp::Callbacks

See Udp::Callbacks

Type Name
virtual void OnMsg (int connection_id, UdpMsg * msg, int len) = 0
virtual ~Callbacks ()

Protected Attributes

Type Name
GGPOSessionCallbacks _callbacks
UdpProtocol _host
int _input_size
GameInput _inputs
int _next_input_to_send
int _num_players
Poll _poll
bool _synchronizing
Udp _udp

Protected Functions

Type Name
void CheckInitialSync (void)
void OnUdpProtocolEvent (UdpProtocol::Event & e)
void PollUdpProtocolEvents (void)

Public Functions Documentation

function AddLocalInput

inline virtual GGPOErrorCode SpectatorBackend::AddLocalInput (
    GGPOPlayerHandle player,
    void * values,
    int size
) 

Implements GGPOSession::AddLocalInput


function AddPlayer

inline virtual GGPOErrorCode SpectatorBackend::AddPlayer (
    GGPOPlayer * player,
    GGPOPlayerHandle * handle
) 

Implements GGPOSession::AddPlayer


function DisconnectPlayer

inline virtual GGPOErrorCode SpectatorBackend::DisconnectPlayer (
    GGPOPlayerHandle handle
) 

Implements GGPOSession::DisconnectPlayer


function DoPoll

virtual GGPOErrorCode SpectatorBackend::DoPoll (
    int timeout
) 

Implements GGPOSession::DoPoll


function GetNetworkStats

inline virtual GGPOErrorCode SpectatorBackend::GetNetworkStats (
    FGGPONetworkStats * stats,
    GGPOPlayerHandle handle
) 

Implements GGPOSession::GetNetworkStats


function IncrementFrame

virtual GGPOErrorCode SpectatorBackend::IncrementFrame (
    void
) 

Implements GGPOSession::IncrementFrame


function OnMsg

virtual void SpectatorBackend::OnMsg (
    int connection_id,
    UdpMsg * msg,
    int len
) 

Implements Udp::Callbacks::OnMsg


function SetDisconnectNotifyStart

inline virtual GGPOErrorCode SpectatorBackend::SetDisconnectNotifyStart (
    int timeout
) 

Implements GGPOSession::SetDisconnectNotifyStart


function SetDisconnectTimeout

inline virtual GGPOErrorCode SpectatorBackend::SetDisconnectTimeout (
    int timeout
) 

Implements GGPOSession::SetDisconnectTimeout


function SetFrameDelay

inline virtual GGPOErrorCode SpectatorBackend::SetFrameDelay (
    GGPOPlayerHandle player,
    int delay
) 

Implements GGPOSession::SetFrameDelay


function SpectatorBackend

SpectatorBackend::SpectatorBackend (
    GGPOSessionCallbacks * cb,
    const char * gamename,
    ConnectionManager * connection_manager,
    int num_players,
    int input_size,
    int connection_id
) 

function SyncInput

virtual GGPOErrorCode SpectatorBackend::SyncInput (
    void * values,
    int size,
    int * disconnect_flags
) 

Implements GGPOSession::SyncInput


function ~SpectatorBackend

virtual SpectatorBackend::~SpectatorBackend () 

Protected Attributes Documentation

variable _callbacks

GGPOSessionCallbacks SpectatorBackend::_callbacks;

variable _host

UdpProtocol SpectatorBackend::_host;

variable _input_size

int SpectatorBackend::_input_size;

variable _inputs

GameInput SpectatorBackend::_inputs[SPECTATOR_FRAME_BUFFER_SIZE];

variable _next_input_to_send

int SpectatorBackend::_next_input_to_send;

variable _num_players

int SpectatorBackend::_num_players;

variable _poll

Poll SpectatorBackend::_poll;

variable _synchronizing

bool SpectatorBackend::_synchronizing;

variable _udp

Udp SpectatorBackend::_udp;

Protected Functions Documentation

function CheckInitialSync

void SpectatorBackend::CheckInitialSync (
    void
) 

function OnUdpProtocolEvent

void SpectatorBackend::OnUdpProtocolEvent (
    UdpProtocol::Event & e
) 

function PollUdpProtocolEvents

void SpectatorBackend::PollUdpProtocolEvents (
    void
) 


The documentation for this class was generated from the following file C:/Users/wistf/Unreal Projects/NightSkyEngine/Plugins/NightSkyEngine/Source/GGPOUE4/Private/backends/spectator.h