My Project
Public Member Functions | List of all members
System::NetworkSystem Class Reference

NetworkSystem class that handles the communication using queues with the server to send it tasks as packets. More...

#include <NetworkSystem.hpp>

Public Member Functions

 NetworkSystem ()
 Construct a new Network System object.
 
void operator() (Registry &registry, Sparse_array< component::cnetwork_queue_t > &network)
 Function that will be automaticaly called while the client is working (on loop) More...
 
void dispatchToPositionQueue (std::vector< byte > const &bytes, Sparse_array< component::cnetwork_queue_t > &network)
 A method to send informations to the position queue. More...
 
void dispatchToNewEntityQueue (std::vector< byte > const &bytes, Sparse_array< component::cnetwork_queue_t > &network)
 A method to send informations to the new entity queue. More...
 
void dispatchToKillEntityQueue (std::vector< byte > const &bytes, Sparse_array< component::cnetwork_queue_t > &network)
 A method to send informations to the kill entity queue. More...
 
void dispatchToKillEntityTypeQueue (std::vector< byte > const &bytes, Sparse_array< component::cnetwork_queue_t > &network)
 A method to send informations to the kill entity type queue. More...
 
void dispatchToGetLobbiesQueue (std::vector< byte > const &bytes, Sparse_array< component::cnetwork_queue_t > &network)
 A method to send informations to the get lobbies queue. More...
 
void dispatchNbPlayersInLobbyQueue (std::vector< byte > const &bytes, Sparse_array< component::cnetwork_queue_t > &network)
 A method to send informations to the Nb Players in queue. More...
 
void dispatchNetworkClientIdQueue (std::vector< byte > const &bytes, Sparse_array< component::cnetwork_queue_t > &network)
 A method to send informations to the network client id queue. More...
 
void dispatchUpdateEntityHealthQueue (std::vector< byte > const &bytes, Sparse_array< component::cnetwork_queue_t > &network)
 A method to send informations to the update entity health queue. More...
 
void dispatchUpdateEntityScoreQueue (std::vector< byte > const &bytes, Sparse_array< component::cnetwork_queue_t > &network)
 A method to send informations to the update entity score queue. More...
 
void dispatchNewLevelQueue (std::vector< byte > const &bytes, Sparse_array< component::cnetwork_queue_t > &network)
 A method to send informations to the new level queue. More...
 
void dispatchEndGameQueue (std::vector< byte > const &bytes, Sparse_array< component::cnetwork_queue_t > &network)
 A method to send informations to the end Game queue. More...
 

Detailed Description

NetworkSystem class that handles the communication using queues with the server to send it tasks as packets.

Member Function Documentation

◆ dispatchEndGameQueue()

void System::NetworkSystem::dispatchEndGameQueue ( std::vector< byte > const &  bytes,
Sparse_array< component::cnetwork_queue_t > &  network 
)

A method to send informations to the end Game queue.

Parameters
bytesThe bytes to send
networkThe sparse array of network entities

◆ dispatchNbPlayersInLobbyQueue()

void System::NetworkSystem::dispatchNbPlayersInLobbyQueue ( std::vector< byte > const &  bytes,
Sparse_array< component::cnetwork_queue_t > &  network 
)

A method to send informations to the Nb Players in queue.

Parameters
bytesThe bytes to send
networkThe sparse array of network entities

◆ dispatchNetworkClientIdQueue()

void System::NetworkSystem::dispatchNetworkClientIdQueue ( std::vector< byte > const &  bytes,
Sparse_array< component::cnetwork_queue_t > &  network 
)

A method to send informations to the network client id queue.

Parameters
bytesThe bytes to send
networkThe sparse array of network entities

◆ dispatchNewLevelQueue()

void System::NetworkSystem::dispatchNewLevelQueue ( std::vector< byte > const &  bytes,
Sparse_array< component::cnetwork_queue_t > &  network 
)

A method to send informations to the new level queue.

Parameters
bytesThe bytes to send
networkThe sparse array of network entities

◆ dispatchToGetLobbiesQueue()

void System::NetworkSystem::dispatchToGetLobbiesQueue ( std::vector< byte > const &  bytes,
Sparse_array< component::cnetwork_queue_t > &  network 
)

A method to send informations to the get lobbies queue.

Parameters
bytesThe bytes to send
networkThe sparse array of network entities

◆ dispatchToKillEntityQueue()

void System::NetworkSystem::dispatchToKillEntityQueue ( std::vector< byte > const &  bytes,
Sparse_array< component::cnetwork_queue_t > &  network 
)

A method to send informations to the kill entity queue.

Parameters
bytesThe bytes to send
networkThe sparse array of network entities

◆ dispatchToKillEntityTypeQueue()

void System::NetworkSystem::dispatchToKillEntityTypeQueue ( std::vector< byte > const &  bytes,
Sparse_array< component::cnetwork_queue_t > &  network 
)

A method to send informations to the kill entity type queue.

Parameters
bytesThe bytes to send
networkThe sparse array of network entities

◆ dispatchToNewEntityQueue()

void System::NetworkSystem::dispatchToNewEntityQueue ( std::vector< byte > const &  bytes,
Sparse_array< component::cnetwork_queue_t > &  network 
)

A method to send informations to the new entity queue.

Parameters
bytesThe bytes to send
networkThe sparse array of network entities

◆ dispatchToPositionQueue()

void System::NetworkSystem::dispatchToPositionQueue ( std::vector< byte > const &  bytes,
Sparse_array< component::cnetwork_queue_t > &  network 
)

A method to send informations to the position queue.

Parameters
bytesThe bytes to send
networkThe sparse array of network entities

◆ dispatchUpdateEntityHealthQueue()

void System::NetworkSystem::dispatchUpdateEntityHealthQueue ( std::vector< byte > const &  bytes,
Sparse_array< component::cnetwork_queue_t > &  network 
)

A method to send informations to the update entity health queue.

Parameters
bytesThe bytes to send
networkThe sparse array of network entities

◆ dispatchUpdateEntityScoreQueue()

void System::NetworkSystem::dispatchUpdateEntityScoreQueue ( std::vector< byte > const &  bytes,
Sparse_array< component::cnetwork_queue_t > &  network 
)

A method to send informations to the update entity score queue.

Parameters
bytesThe bytes to send
networkThe sparse array of network entities

◆ operator()()

void System::NetworkSystem::operator() ( Registry registry,
Sparse_array< component::cnetwork_queue_t > &  network 
)

Function that will be automaticaly called while the client is working (on loop)

Parameters
registryThe registry of the client
networkThe sparse array of network entities

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