Symphony Of Empires
Client Class Reference

#include <client_network.hpp>

Inheritance diagram for Client:
Collaboration diagram for Client:

Public Member Functions

 Client (GameState &gs, std::string host, const unsigned port)
 
 ~Client ()
 
void netloop ()
 
void wait_for_snapshot ()
 Waits to receive the server initial world snapshot. More...
 
- Public Member Functions inherited from Eng3D::Networking::Client
 Client (std::string host, const unsigned port)
 
 ~Client ()
 
void do_netloop (std::function< bool()> cond, std::function< void(const Packet &packet, Eng3D::Deser::Archive &ar)> handler)
 
void send (const Eng3D::Networking::Packet &packet)
 
int get_fd () const
 

Additional Inherited Members

- Public Attributes inherited from Eng3D::Networking::Client
tbb::concurrent_bounded_queue< Eng3D::Networking::Packetpackets
 
std::string username
 
- Protected Attributes inherited from Eng3D::Networking::Client
struct sockaddr_in addr
 
int fd
 

Detailed Description

Definition at line 47 of file client_network.hpp.

Constructor & Destructor Documentation

◆ Client()

Client::Client ( GameState gs,
std::string  host,
const unsigned  port 
)

Definition at line 44 of file client_network.cpp.

Here is the call graph for this function:

◆ ~Client()

Client::~Client ( )

Definition at line 212 of file client_network.cpp.

Member Function Documentation

◆ netloop()

void Client::netloop ( )

Definition at line 60 of file client_network.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ wait_for_snapshot()

void Client::wait_for_snapshot ( )

Waits to receive the server initial world snapshot.

Definition at line 206 of file client_network.cpp.


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