Refactor start_new_season_league_changes()

This commit is contained in:
Tom Stellard 2021-03-17 07:21:52 -07:00 committed by Tom Stellard
parent 19d361fb82
commit 7c1fe79763
1 changed files with 4 additions and 5 deletions

View File

@ -866,11 +866,10 @@ start_new_season_league_changes(void)
{
for(j=0;j<lig(i).teams->len;j++)
{
g_array_index(lig(i).teams, Team, j).clid = lig(i).id;
for(k=0;k<g_array_index(lig(i).teams, Team, j).players->len;k++)
g_array_index(g_array_index(lig(i).teams, Team, j).players,
Player, k).team =
&g_array_index(lig(i).teams, Team, j);
Team *team = &g_array_index(lig(i).teams, Team, j);
team->clid = lig(i).id;
for(k=0;k<team->players->len;k++)
g_array_index(team->players, Player, k).team = team;
}
league_season_start(&lig(i));