Project Alice
Loading...
Searching...
No Matches
network.hpp File Reference
#include <array>
#include <string>
#include <netinet/in.h>
#include <sys/socket.h>
#include "SPSCQueue.h"
#include "container_types.hpp"
#include "commands.hpp"
Include dependency graph for network.hpp:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  network::client_handshake_data
 
struct  network::server_handshake_data
 
struct  network::client_data
 
struct  network::network_state
 
class  network::port_forwarder
 

Namespaces

namespace  sys
 
namespace  network
 

Typedefs

typedef int network::socket_t
 

Functions

void network::init (sys::state &state)
 
void network::send_and_receive_commands (sys::state &state)
 
void network::finish (sys::state &state, bool notify_host)
 
void network::ban_player (sys::state &state, client_data &client)
 
void network::kick_player (sys::state &state, client_data &client)
 
void network::switch_player (sys::state &state, dcon::nation_id new_n, dcon::nation_id old_n)
 
void network::write_network_save (sys::state &state)
 
void network::broadcast_save_to_clients (sys::state &state, command::payload &c, uint8_t const *buffer, uint32_t length, sys::checksum_key const &k)
 
void network::broadcast_to_clients (sys::state &state, command::payload &c)
 
void network::clear_socket (sys::state &state, client_data &client)
 
void network::full_reset_after_oos (sys::state &state)
 
dcon::mp_player_id network::create_mp_player (sys::state &state, sys::player_name &name, sys::player_password_raw &password)
 
dcon::mp_player_id network::load_mp_player (sys::state &state, sys::player_name &name, sys::player_password_hash &password_hash, sys::player_password_salt &password_salt)
 
void network::update_mp_player_password (sys::state &state, dcon::mp_player_id player_id, sys::player_password_raw &password)
 
dcon::mp_player_id network::find_mp_player (sys::state &state, sys::player_name name)
 
dcon::mp_player_id network::find_country_player (sys::state &state, dcon::nation_id nation)
 
void network::log_player_nations (sys::state &state)
 
void network::place_host_player_after_saveload (sys::state &state)
 
bool network::pause_game (sys::state &state)
 
bool network::unpause_game (sys::state &state)
 
void network::notify_player_joins (sys::state &state, network::client_data &client)
 
void network::notify_player_joins (sys::state &state, sys::player_name name, dcon::nation_id nation)
 
void network::load_host_settings (sys::state &state)
 
void network::save_host_settings (sys::state &state)
 

Variables

constexpr short network::default_server_port = 1984