mirror of
https://github.com/tstellar/bygfoot.git
synced 2025-01-22 11:53:08 +01:00
Newspaper progressing.
This commit is contained in:
parent
255b765fd9
commit
3ab4b46194
@ -70,6 +70,7 @@ bygfoot_SOURCES = \
|
|||||||
xml_loadsave_league_stat.c file.h misc.h stat.h team.h xml.h xml_loadsave_league_stat.h \
|
xml_loadsave_league_stat.c file.h misc.h stat.h team.h xml.h xml_loadsave_league_stat.h \
|
||||||
xml_loadsave_live_game.c cup.h file.h fixture.h league.h live_game.h misc.h option.h variables.h xml.h xml_loadsave_live_game.h \
|
xml_loadsave_live_game.c cup.h file.h fixture.h league.h live_game.h misc.h option.h variables.h xml.h xml_loadsave_live_game.h \
|
||||||
xml_loadsave_misc.c bet_struct.h cup.h file.h fixture.h free.h misc.h variables.h xml.h xml_loadsave_cup.h xml_loadsave_league.h xml_loadsave_misc.h \
|
xml_loadsave_misc.c bet_struct.h cup.h file.h fixture.h free.h misc.h variables.h xml.h xml_loadsave_cup.h xml_loadsave_league.h xml_loadsave_misc.h \
|
||||||
|
xml_loadsave_newspaper.c file.h free.h variables.h xml.h xml_loadsave_newspaper.h \
|
||||||
xml_loadsave_players.c misc.h player.h team.h xml.h xml_loadsave_players.h \
|
xml_loadsave_players.c misc.h player.h team.h xml.h xml_loadsave_players.h \
|
||||||
xml_loadsave_season_stats.c file.h free.h misc.h stat.h variables.h xml.h xml_loadsave_league_stat.h xml_loadsave_season_stats.h \
|
xml_loadsave_season_stats.c file.h free.h misc.h stat.h variables.h xml.h xml_loadsave_league_stat.h xml_loadsave_season_stats.h \
|
||||||
xml_loadsave_table.c file.h misc.h team.h xml.h xml_loadsave_table.h \
|
xml_loadsave_table.c file.h misc.h team.h xml.h xml_loadsave_table.h \
|
||||||
|
@ -69,6 +69,7 @@ am_bygfoot_OBJECTS = bet.$(OBJEXT) callback_func.$(OBJEXT) \
|
|||||||
xml_loadsave_leagues_cups.$(OBJEXT) \
|
xml_loadsave_leagues_cups.$(OBJEXT) \
|
||||||
xml_loadsave_league_stat.$(OBJEXT) \
|
xml_loadsave_league_stat.$(OBJEXT) \
|
||||||
xml_loadsave_live_game.$(OBJEXT) xml_loadsave_misc.$(OBJEXT) \
|
xml_loadsave_live_game.$(OBJEXT) xml_loadsave_misc.$(OBJEXT) \
|
||||||
|
xml_loadsave_newspaper.$(OBJEXT) \
|
||||||
xml_loadsave_players.$(OBJEXT) \
|
xml_loadsave_players.$(OBJEXT) \
|
||||||
xml_loadsave_season_stats.$(OBJEXT) \
|
xml_loadsave_season_stats.$(OBJEXT) \
|
||||||
xml_loadsave_table.$(OBJEXT) xml_loadsave_teams.$(OBJEXT) \
|
xml_loadsave_table.$(OBJEXT) xml_loadsave_teams.$(OBJEXT) \
|
||||||
@ -269,6 +270,7 @@ bygfoot_SOURCES = \
|
|||||||
xml_loadsave_league_stat.c file.h misc.h stat.h team.h xml.h xml_loadsave_league_stat.h \
|
xml_loadsave_league_stat.c file.h misc.h stat.h team.h xml.h xml_loadsave_league_stat.h \
|
||||||
xml_loadsave_live_game.c cup.h file.h fixture.h league.h live_game.h misc.h option.h variables.h xml.h xml_loadsave_live_game.h \
|
xml_loadsave_live_game.c cup.h file.h fixture.h league.h live_game.h misc.h option.h variables.h xml.h xml_loadsave_live_game.h \
|
||||||
xml_loadsave_misc.c bet_struct.h cup.h file.h fixture.h free.h misc.h variables.h xml.h xml_loadsave_cup.h xml_loadsave_league.h xml_loadsave_misc.h \
|
xml_loadsave_misc.c bet_struct.h cup.h file.h fixture.h free.h misc.h variables.h xml.h xml_loadsave_cup.h xml_loadsave_league.h xml_loadsave_misc.h \
|
||||||
|
xml_loadsave_newspaper.c file.h free.h variables.h xml.h xml_loadsave_newspaper.h \
|
||||||
xml_loadsave_players.c misc.h player.h team.h xml.h xml_loadsave_players.h \
|
xml_loadsave_players.c misc.h player.h team.h xml.h xml_loadsave_players.h \
|
||||||
xml_loadsave_season_stats.c file.h free.h misc.h stat.h variables.h xml.h xml_loadsave_league_stat.h xml_loadsave_season_stats.h \
|
xml_loadsave_season_stats.c file.h free.h misc.h stat.h variables.h xml.h xml_loadsave_league_stat.h xml_loadsave_season_stats.h \
|
||||||
xml_loadsave_table.c file.h misc.h team.h xml.h xml_loadsave_table.h \
|
xml_loadsave_table.c file.h misc.h team.h xml.h xml_loadsave_table.h \
|
||||||
@ -418,6 +420,7 @@ distclean-compile:
|
|||||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/xml_loadsave_leagues_cups.Po@am__quote@
|
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/xml_loadsave_leagues_cups.Po@am__quote@
|
||||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/xml_loadsave_live_game.Po@am__quote@
|
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/xml_loadsave_live_game.Po@am__quote@
|
||||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/xml_loadsave_misc.Po@am__quote@
|
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/xml_loadsave_misc.Po@am__quote@
|
||||||
|
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/xml_loadsave_newspaper.Po@am__quote@
|
||||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/xml_loadsave_players.Po@am__quote@
|
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/xml_loadsave_players.Po@am__quote@
|
||||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/xml_loadsave_season_stats.Po@am__quote@
|
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/xml_loadsave_season_stats.Po@am__quote@
|
||||||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/xml_loadsave_table.Po@am__quote@
|
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/xml_loadsave_table.Po@am__quote@
|
||||||
|
@ -40,12 +40,13 @@
|
|||||||
#include "xml_loadsave_league.h"
|
#include "xml_loadsave_league.h"
|
||||||
#include "xml_loadsave_leagues_cups.h"
|
#include "xml_loadsave_leagues_cups.h"
|
||||||
#include "xml_loadsave_misc.h"
|
#include "xml_loadsave_misc.h"
|
||||||
|
#include "xml_loadsave_newspaper.h"
|
||||||
#include "xml_loadsave_season_stats.h"
|
#include "xml_loadsave_season_stats.h"
|
||||||
#include "xml_loadsave_transfers.h"
|
#include "xml_loadsave_transfers.h"
|
||||||
#include "xml_loadsave_users.h"
|
#include "xml_loadsave_users.h"
|
||||||
#include "xml.h"
|
#include "xml.h"
|
||||||
|
|
||||||
#define PROGRESS_MAX 8
|
#define PROGRESS_MAX 9
|
||||||
|
|
||||||
/** Save the game to the specified file. */
|
/** Save the game to the specified file. */
|
||||||
void
|
void
|
||||||
@ -139,6 +140,18 @@ load_save_save_game(const gchar *filename)
|
|||||||
|
|
||||||
xml_loadsave_jobs_write(prefix);
|
xml_loadsave_jobs_write(prefix);
|
||||||
|
|
||||||
|
if(debug > 60)
|
||||||
|
g_print("load_save_save newspaper \n");
|
||||||
|
|
||||||
|
gui_show_progress(
|
||||||
|
((PROGRESS_MAX * gtk_progress_bar_get_fraction(
|
||||||
|
GTK_PROGRESS_BAR(
|
||||||
|
lookup_widget(window.progress, "progressbar")))) + 1) / PROGRESS_MAX,
|
||||||
|
_("Saving newspaper..."),
|
||||||
|
PIC_TYPE_SAVE);
|
||||||
|
|
||||||
|
xml_loadsave_newspaper_write(prefix);
|
||||||
|
|
||||||
if(debug > 60)
|
if(debug > 60)
|
||||||
g_print("load_save_save misc \n");
|
g_print("load_save_save misc \n");
|
||||||
|
|
||||||
@ -296,6 +309,18 @@ load_save_load_game(const gchar* filename, gboolean create_main_window)
|
|||||||
|
|
||||||
xml_loadsave_jobs_read(dirname, prefix);
|
xml_loadsave_jobs_read(dirname, prefix);
|
||||||
|
|
||||||
|
if(debug > 60)
|
||||||
|
g_print("load_save_load newspaper \n");
|
||||||
|
|
||||||
|
gui_show_progress(
|
||||||
|
((PROGRESS_MAX * gtk_progress_bar_get_fraction(
|
||||||
|
GTK_PROGRESS_BAR(
|
||||||
|
lookup_widget(window.progress, "progressbar")))) + 1) / PROGRESS_MAX,
|
||||||
|
_("Loading newspaper..."),
|
||||||
|
PIC_TYPE_LOAD);
|
||||||
|
|
||||||
|
xml_loadsave_newspaper_read(dirname, prefix);
|
||||||
|
|
||||||
if(debug > 60)
|
if(debug > 60)
|
||||||
g_print("load_save_load misc \n");
|
g_print("load_save_load misc \n");
|
||||||
|
|
||||||
|
@ -73,6 +73,11 @@ news_generate_match(const LiveGame *live_game, const Fixture *fix)
|
|||||||
new_article.subtitle_id = subtitle_id;
|
new_article.subtitle_id = subtitle_id;
|
||||||
// printf("%s / %s -- %d %d\n", title, subtitle, title_id, subtitle_id);
|
// printf("%s / %s -- %d %d\n", title, subtitle, title_id, subtitle_id);
|
||||||
g_array_append_val(newspaper.articles, new_article);
|
g_array_append_val(newspaper.articles, new_article);
|
||||||
|
|
||||||
|
/* gint i; */
|
||||||
|
/* for(i = 0; i < newspaper.articles->len; i++) */
|
||||||
|
/* printf("%s\n%s\n", g_array_index(newspaper.articles, NewsPaperArticle, i).title, */
|
||||||
|
/* g_array_index(newspaper.articles, NewsPaperArticle, i).subtitle); */
|
||||||
}
|
}
|
||||||
|
|
||||||
news_free_tokens();
|
news_free_tokens();
|
||||||
|
@ -73,6 +73,7 @@ enum XmlTags
|
|||||||
#define TAG_START_LEAGUES_CUPS 12000
|
#define TAG_START_LEAGUES_CUPS 12000
|
||||||
#define TAG_START_TRANSFERS 20000
|
#define TAG_START_TRANSFERS 20000
|
||||||
#define TAG_START_JOBS 21000
|
#define TAG_START_JOBS 21000
|
||||||
|
#define TAG_START_NEWS_PAPER 22000
|
||||||
|
|
||||||
#define xml_write_g_string(fil, gstring, tag, indent) xml_write_string(fil, (gstring)->str, tag, indent)
|
#define xml_write_g_string(fil, gstring, tag, indent) xml_write_string(fil, (gstring)->str, tag, indent)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user