R-Type
Networked shoot'em up built on Aegis2D
Loading...
Searching...
No Matches
rtype::ServerOptions Struct Reference

Settings of a server run, read from the command line. More...

#include </__w/project-rtype/project-rtype/server/include/rtype/server_options.hpp>

Public Attributes

ServerCommand command = ServerCommand::Run
 What to do; the other fields only matter for ServerCommand::Run.
 
std::uint16_t tcp_port = default_tcp_port
 TCP port of the logins; 0 lets the system pick a free one.
 
std::uint16_t udp_port = default_udp_port
 UDP port of the game; 0 lets the system pick a free one.
 
std::optional< std::filesystem::path > waves
 Waves file to play, or std::nullopt for default_waves_file().
 
std::uint32_t packet_rate = default_packet_rate
 Datagrams accepted per second from one address, 1 to 100000.
 
std::optional< std::size_t > compress_from
 Size from which snapshots and events are sent compressed with LZ4 when that makes them smaller, 1 to 1182 bytes, or std::nullopt (the default) to never compress.
 
std::uint32_t max_rooms = default_max_rooms
 Rooms played at once, 1 to 64, tuning::max_players in each.
 
std::filesystem::path scores {default_scores_file}
 File of the best scores (Scoreboard).
 
std::filesystem::path bans {default_bans_file}
 File of the banned addresses (BanList).
 
std::optional< std::filesystem::path > trace
 File the timings of every tick are written to when the server stops, in the Chrome trace format (Perfetto), or std::nullopt (the default) for none.
 

Detailed Description

Settings of a server run, read from the command line.

Member Data Documentation

◆ bans

std::filesystem::path rtype::ServerOptions::bans {default_bans_file}

File of the banned addresses (BanList).

◆ command

ServerCommand rtype::ServerOptions::command = ServerCommand::Run

What to do; the other fields only matter for ServerCommand::Run.

◆ compress_from

std::optional<std::size_t> rtype::ServerOptions::compress_from

Size from which snapshots and events are sent compressed with LZ4 when that makes them smaller, 1 to 1182 bytes, or std::nullopt (the default) to never compress.

◆ max_rooms

std::uint32_t rtype::ServerOptions::max_rooms = default_max_rooms

Rooms played at once, 1 to 64, tuning::max_players in each.

◆ packet_rate

std::uint32_t rtype::ServerOptions::packet_rate = default_packet_rate

Datagrams accepted per second from one address, 1 to 100000.

◆ scores

std::filesystem::path rtype::ServerOptions::scores {default_scores_file}

File of the best scores (Scoreboard).

◆ tcp_port

std::uint16_t rtype::ServerOptions::tcp_port = default_tcp_port

TCP port of the logins; 0 lets the system pick a free one.

◆ trace

std::optional<std::filesystem::path> rtype::ServerOptions::trace

File the timings of every tick are written to when the server stops, in the Chrome trace format (Perfetto), or std::nullopt (the default) for none.

◆ udp_port

std::uint16_t rtype::ServerOptions::udp_port = default_udp_port

UDP port of the game; 0 lets the system pick a free one.

◆ waves

std::optional<std::filesystem::path> rtype::ServerOptions::waves

Waves file to play, or std::nullopt for default_waves_file().


The documentation for this struct was generated from the following file: