1
1
mirror of https://github.com/tstellar/bygfoot.git synced 2024-12-17 18:59:10 +01:00

Added omit_from_history property to leagues and cups.

This commit is contained in:
gyboth 2008-11-24 12:09:06 +00:00
parent 945c4d1093
commit 32ce54a2aa
2 changed files with 22 additions and 12 deletions

View File

@ -147,7 +147,10 @@ main_parse_cl_arguments(gint *argc, gchar ***argv)
} }
if(deb_level != -1) if(deb_level != -1)
{
option_set_int("int_debug", &constants, deb_level); option_set_int("int_debug", &constants, deb_level);
window_create(WINDOW_DEBUG);
}
if(deb_writer != -1) if(deb_writer != -1)
option_set_int("int_debug_writer", &constants, deb_writer); option_set_int("int_debug_writer", &constants, deb_writer);

View File

@ -184,6 +184,8 @@ stat_create_season_stat(void)
ChampStat new_champ; ChampStat new_champ;
for(i=0;i<ligs->len;i++) for(i=0;i<ligs->len;i++)
{
if(!query_league_cup_has_property(lig(i).id, "omit_from_history"))
{ {
for(j = 0; j < lig(i).tables->len; j++) for(j = 0; j < lig(i).tables->len; j++)
{ {
@ -191,19 +193,24 @@ stat_create_season_stat(void)
new_champ.team_name = new_champ.team_name =
g_strdup(g_array_index(g_array_index(lig(i).tables, Table, j).elements, TableElement, 0).team->name); g_strdup(g_array_index(g_array_index(lig(i).tables, Table, j).elements, TableElement, 0).team->name);
g_array_append_val(new.league_champs, new_champ); g_array_append_val(new.league_champs, new_champ);
} }
g_array_append_val(new.league_stats, lig(i).stats); g_array_append_val(new.league_stats, lig(i).stats);
lig(i).stats = stat_league_new(lig(i).name, lig(i).symbol); lig(i).stats = stat_league_new(lig(i).name, lig(i).symbol);
} }
}
for(i=0;i<acps->len;i++) for(i=0;i<acps->len;i++)
{
if(!query_league_cup_has_property(acp(i)->id, "omit_from_history"))
{ {
new_champ.cl_name = g_strdup(acp(i)->name); new_champ.cl_name = g_strdup(acp(i)->name);
new_champ.team_name = new_champ.team_name =
g_strdup(cup_get_winner(acp(i))->name); g_strdup(cup_get_winner(acp(i))->name);
g_array_append_val(new.cup_champs, new_champ); g_array_append_val(new.cup_champs, new_champ);
} }
}
g_array_append_val(season_stats, new); g_array_append_val(season_stats, new);
} }