Example #1
0
void scores_write (void *ptr)
{
    scores_init ();
    scores_load ();
    scores_generate_html ();
    while (running)
    {
        if (score_new)
        {
            fprintf (stdout, "New score received\n");
            scores_print ();
            score_new = 0;
        }
    }
}
Example #2
0
File: main.c Project: NatTuck/teg
/* Initialize the server for the first game */
void game_init()
{
	player_init();
	color_init();
	pactos_init();
	scores_init();
	xmlscores_load();
	metaserver_init();

	g_game.connections = 0;
	g_game.players = 0;
	g_game.playing = 0;

	/* default values */
	g_game.fichas = 5;
	g_game.fichas2 = 3;
	g_game.mission = FALSE;
	g_game.cmission = TRUE;
	g_game.reglas = TEG_RULES_TEG;
	g_game.fog_of_war = FALSE;
	g_game.player_fow = NULL;

	game_new();
}