Freeciv21
Develop your civilization from humble roots to a global empire
report.h File Reference
#include "support.h"
+ Include dependency graph for report.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  history_report
 

Macros

#define REPORT_TITLESIZE   1024
 
#define REPORT_BODYSIZE   (128 * MAX_NUM_PLAYER_SLOTS)
 

Functions

void page_conn (struct conn_list *dest, const char *caption, const char *headline, const char *lines)
 This function pops up a non-modal message dialog on the player's desktop. More...
 
void log_civ_score_init ()
 Initialize score logging system. More...
 
void log_civ_score_free ()
 Free resources allocated for score logging system. More...
 
void log_civ_score_now ()
 Create a log file of the civilizations so you can see what was happening. More...
 
void make_history_report ()
 Produce random history report if it's time for one. More...
 
void send_current_history_report (struct conn_list *dest)
 Send history report of this turn. More...
 
void report_wonders_of_the_world (struct conn_list *dest)
 Send report listing all built and destroyed wonders, and wonders currently being built. More...
 
void report_top_five_cities (struct conn_list *dest)
 Send report listing the "best" 5 cities in the world. More...
 
bool is_valid_demography (const char *demography, int *error)
 Verify that a given demography string is valid. More...
 
void report_demographics (struct connection *pconn)
 Send demographics report; what gets reported depends on value of demographics server option. More...
 
void report_achievements (struct connection *pconn)
 Send achievements list. More...
 
void report_final_scores (struct conn_list *dest)
 Inform clients about player scores and statistics when the game ends. More...
 
struct history_reporthistory_report_get ()
 Return current history report. More...
 

Macro Definition Documentation

◆ REPORT_BODYSIZE

#define REPORT_BODYSIZE   (128 * MAX_NUM_PLAYER_SLOTS)

Definition at line 19 of file report.h.

◆ REPORT_TITLESIZE

#define REPORT_TITLESIZE   1024

Definition at line 18 of file report.h.

Function Documentation

◆ history_report_get()

struct history_report* history_report_get ( )

Return current history report.

Definition at line 1877 of file report.cpp.

Referenced by sg_load_history(), and sg_save_history().

◆ is_valid_demography()

bool is_valid_demography ( const char *  demography,
int *  error 
)

Verify that a given demography string is valid.

See game.demography. If the string is not valid the index of the first invalid character is return as 'error'.

Other settings callback functions are in settings.c, but this one uses static values from this file so it's done separately.

Definition at line 1128 of file report.cpp.

Referenced by demography_callback().

◆ log_civ_score_free()

void log_civ_score_free ( )

Free resources allocated for score logging system.

Definition at line 1474 of file report.cpp.

Referenced by log_civ_score_now(), scorelog_action(), and server_game_free().

◆ log_civ_score_init()

void log_civ_score_init ( )

Initialize score logging system.

Definition at line 1450 of file report.cpp.

Referenced by scorelog_action().

◆ log_civ_score_now()

void log_civ_score_now ( )

Create a log file of the civilizations so you can see what was happening.

Definition at line 1505 of file report.cpp.

Referenced by begin_turn(), and srv_scores().

◆ make_history_report()

void make_history_report ( )

Produce random history report if it's time for one.

Definition at line 1718 of file report.cpp.

Referenced by end_turn().

◆ page_conn()

void page_conn ( struct conn_list *  dest,
const char *  caption,
const char *  headline,
const char *  lines 
)

This function pops up a non-modal message dialog on the player's desktop.

Definition at line 1822 of file report.cpp.

Referenced by report_achievements(), report_demographics(), report_top_five_cities(), and report_wonders_of_the_world().

◆ report_achievements()

void report_achievements ( struct connection pconn)

Send achievements list.

Definition at line 1237 of file report.cpp.

Referenced by handle_report_req().

◆ report_demographics()

void report_demographics ( struct connection pconn)

Send demographics report; what gets reported depends on value of demographics server option.

Definition at line 1175 of file report.cpp.

Referenced by handle_report_req().

◆ report_final_scores()

void report_final_scores ( struct conn_list *  dest)

Inform clients about player scores and statistics when the game ends.

Called only from server/srv_main.c srv_scores()

Definition at line 1741 of file report.cpp.

Referenced by connection_attach_real(), and srv_scores().

◆ report_top_five_cities()

void report_top_five_cities ( struct conn_list *  dest)

Send report listing the "best" 5 cities in the world.

Definition at line 354 of file report.cpp.

Referenced by handle_report_req().

◆ report_wonders_of_the_world()

void report_wonders_of_the_world ( struct conn_list *  dest)

Send report listing all built and destroyed wonders, and wonders currently being built.

Definition at line 433 of file report.cpp.

Referenced by handle_report_req().

◆ send_current_history_report()

void send_current_history_report ( struct conn_list *  dest)

Send history report of this turn.

Definition at line 323 of file report.cpp.

Referenced by establish_new_connection(), and make_history_report().