Zappy Server
C++ game server: world, rules, scheduler, network
Loading...
Searching...
No Matches
ServerConfig Struct Reference

Represents the configuration for the server application, described by: More...

#include <Args.hpp>

+ Collaboration diagram for ServerConfig:

Public Attributes

int port
 
int width
 
int height
 
std::vector< std::string > teamNames
 
int clientsNb
 
int freq
 
unsigned int seed
 

Friends

std::ostream & operator<< (std::ostream &os, const ServerConfig &c)
 

Detailed Description

Represents the configuration for the server application, described by:

  • port: the port number (-p)
  • width: width of the world (-x)
  • height: height of the world (-y)
  • nameX: name of the teams (-n followed by team names)
  • clientsNb: number of clients per team (-c)
  • freq: frequency of the game (-f)
  • seed: seed for the world (-s)

Definition at line 17 of file Args.hpp.

Friends And Related Symbol Documentation

◆ operator<<

std::ostream & operator<< ( std::ostream &  os,
const ServerConfig c 
)
friend

Definition at line 26 of file Args.hpp.

Member Data Documentation

◆ clientsNb

int ServerConfig::clientsNb

Definition at line 22 of file Args.hpp.

Referenced by Args::Args(), and Server::Server().

◆ freq

int ServerConfig::freq

Definition at line 23 of file Args.hpp.

Referenced by Server::_scheduleRespawn(), and Args::Args().

◆ height

int ServerConfig::height

◆ port

int ServerConfig::port

Definition at line 18 of file Args.hpp.

Referenced by Server::_logStartup(), Args::Args(), and Server::Server().

◆ seed

unsigned int ServerConfig::seed

Definition at line 24 of file Args.hpp.

Referenced by Server::_logStartup(), and Args::Args().

◆ teamNames

std::vector<std::string> ServerConfig::teamNames

◆ width

int ServerConfig::width

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