6#define _WINSOCK_DEPRECATED_NO_WARNINGS 1
7#ifndef WINSOCK2_IMPORTED
8#define WINSOCK2_IMPORTED
13#include <netinet/in.h>
14#include <sys/socket.h>
139 std::mutex internal_wait;
140 std::thread do_forwarding;
141 bool started =
false;
void broadcast_save_to_clients(sys::state &state, command::payload &c, uint8_t const *buffer, uint32_t length, sys::checksum_key const &k)
dcon::mp_player_id find_country_player(sys::state &state, dcon::nation_id nation)
bool pause_game(sys::state &state)
void place_host_player_after_saveload(sys::state &state)
void write_network_save(sys::state &state)
void update_mp_player_password(sys::state &state, dcon::mp_player_id player_id, sys::player_password_raw &password)
dcon::mp_player_id find_mp_player(sys::state &state, sys::player_name name)
void load_host_settings(sys::state &state)
void clear_socket(sys::state &state, client_data &client)
void broadcast_to_clients(sys::state &state, command::payload &c)
bool unpause_game(sys::state &state)
dcon::mp_player_id create_mp_player(sys::state &state, sys::player_name &name, sys::player_password_raw &password)
dcon::mp_player_id load_mp_player(sys::state &state, sys::player_name &name, sys::player_password_hash &password_hash, sys::player_password_salt &password_salt)
void notify_player_joins(sys::state &state, sys::player_name name, dcon::nation_id nation, sys::player_password_raw password)
void kick_player(sys::state &state, client_data &client)
constexpr short default_server_port
void finish(sys::state &state, bool notify_host)
void switch_player(sys::state &state, dcon::nation_id new_n, dcon::nation_id old_n)
void ban_player(sys::state &state, client_data &client)
void save_host_settings(sys::state &state)
void send_and_receive_commands(sys::state &state)
void init(sys::state &state)
void full_reset_after_oos(sys::state &state)
void log_player_nations(sys::state &state)
struct sockaddr_storage address
std::vector< char > send_buffer
bool is_banned(sys::state &state) const
dcon::nation_id playing_as
size_t save_stream_offset
command::payload recv_buffer
client_handshake_data hshake_buffer
std::vector< char > early_send_buffer
sys::player_name nickname
uint8_t lobby_password[16]
sys::player_password_raw player_password
uint32_t current_save_length
std::vector< char > send_buffer
uint8_t lobby_password[16]
sys::player_password_raw player_password
std::vector< uint8_t > save_data
std::vector< struct in6_addr > v6_banlist
rigtorp::SPSCQueue< command::payload > outgoing_commands
std::vector< char > early_send_buffer
std::array< client_data, 128 > clients
struct sockaddr_storage address
sys::player_name nickname
std::unique_ptr< uint8_t[]> current_save_buffer
sys::checksum_key current_save_checksum
std::vector< struct in_addr > v4_banlist
std::atomic< bool > save_slock
command::payload recv_buffer
server_handshake_data s_hshake
dcon::nation_id assigned_nation
sys::checksum_key save_checksum
sys::checksum_key scenario_checksum
Holds important data about the game world, state, and other data regarding windowing,...