Cuberite
A lightweight, fast and extensible game server for Minecraft
Public Member Functions | Public Attributes | Private Member Functions | Private Attributes | List of all members
cForgeHandshake Class Reference

#include <ForgeHandshake.h>

Collaboration diagram for cForgeHandshake:
Collaboration graph
[legend]

Public Member Functions

void AugmentServerListPing (Json::Value &ResponseValue)
 Add the registered Forge mods to the server ping list packet. More...
 
void BeginForgeHandshake (const AString &a_Name, const cUUID &a_UUID, const Json::Value &a_Properties)
 Begin the Forge Modloader Handshake (FML|HS) sequence. More...
 
 cForgeHandshake (cClientHandle *client)
 
void DataReceived (cClientHandle *a_Client, const char *a_Data, size_t a_Size)
 Process received data from the client advancing the Forge handshake. More...
 
void SendServerHello ()
 Send the ServerHello packet in the Forge handshake. More...
 

Public Attributes

bool m_IsForgeClient
 True if the client advertised itself as a Forge client. More...
 

Private Member Functions

void HandleClientHello (cClientHandle *a_Client, const char *a_Data, size_t a_Size)
 
void HandleHandshakeAck (cClientHandle *a_Client, const char *a_Data, size_t a_Size)
 
void HandleModList (cClientHandle *a_Client, const char *a_Data, size_t a_Size)
 
AStringMap ParseModList (const char *a_Data, size_t a_Size)
 Parse the client ModList packet of installed Forge mods and versions. More...
 
void SetError (const AString &message)
 Set errored state to prevent further handshake message processing. More...
 

Private Attributes

cClientHandlem_Client
 The client handle undergoing this Forge handshake. More...
 
bool m_Errored
 True if the Forge handshake is in an errored state. More...
 
AString m_Name
 Values saved from BeginForgeHandshake() for continuing the normal handshake after Forge completes. More...
 
Json::Value m_Properties
 
cUUID m_UUID
 

Detailed Description

Definition at line 19 of file ForgeHandshake.h.

Constructor & Destructor Documentation

cForgeHandshake::cForgeHandshake ( cClientHandle client)

Definition at line 47 of file ForgeHandshake.cpp.

Member Function Documentation

void cForgeHandshake::AugmentServerListPing ( Json::Value &  ResponseValue)

Add the registered Forge mods to the server ping list packet.

Definition at line 68 of file ForgeHandshake.cpp.

void cForgeHandshake::BeginForgeHandshake ( const AString a_Name,
const cUUID a_UUID,
const Json::Value &  a_Properties 
)

Begin the Forge Modloader Handshake (FML|HS) sequence.

Definition at line 100 of file ForgeHandshake.cpp.

void cForgeHandshake::DataReceived ( cClientHandle a_Client,
const char *  a_Data,
size_t  a_Size 
)

Process received data from the client advancing the Forge handshake.

Definition at line 333 of file ForgeHandshake.cpp.

void cForgeHandshake::HandleClientHello ( cClientHandle a_Client,
const char *  a_Data,
size_t  a_Size 
)
private

Definition at line 185 of file ForgeHandshake.cpp.

void cForgeHandshake::HandleHandshakeAck ( cClientHandle a_Client,
const char *  a_Data,
size_t  a_Size 
)
private

Definition at line 254 of file ForgeHandshake.cpp.

void cForgeHandshake::HandleModList ( cClientHandle a_Client,
const char *  a_Data,
size_t  a_Size 
)
private

Definition at line 206 of file ForgeHandshake.cpp.

AStringMap cForgeHandshake::ParseModList ( const char *  a_Data,
size_t  a_Size 
)
private

Parse the client ModList packet of installed Forge mods and versions.

Definition at line 143 of file ForgeHandshake.cpp.

void cForgeHandshake::SendServerHello ( )

Send the ServerHello packet in the Forge handshake.

Definition at line 124 of file ForgeHandshake.cpp.

void cForgeHandshake::SetError ( const AString message)
private

Set errored state to prevent further handshake message processing.

Definition at line 58 of file ForgeHandshake.cpp.

Member Data Documentation

cClientHandle* cForgeHandshake::m_Client
private

The client handle undergoing this Forge handshake.

Definition at line 44 of file ForgeHandshake.h.

bool cForgeHandshake::m_Errored
private

True if the Forge handshake is in an errored state.

Definition at line 41 of file ForgeHandshake.h.

bool cForgeHandshake::m_IsForgeClient

True if the client advertised itself as a Forge client.

Definition at line 23 of file ForgeHandshake.h.

AString cForgeHandshake::m_Name
private

Values saved from BeginForgeHandshake() for continuing the normal handshake after Forge completes.

Definition at line 47 of file ForgeHandshake.h.

Json::Value cForgeHandshake::m_Properties
private

Definition at line 49 of file ForgeHandshake.h.

cUUID cForgeHandshake::m_UUID
private

Definition at line 48 of file ForgeHandshake.h.


The documentation for this class was generated from the following files: