Ausgabe von Helden im Wochenbericht

This commit is contained in:
Enno Rehling 2004-09-12 09:28:43 +00:00
parent 32e18c5f9d
commit 110198f684
3 changed files with 12 additions and 7 deletions

View File

@ -2906,6 +2906,7 @@ typedef struct summary {
int schiffe;
int gebaeude;
int maxskill;
int heroes;
int inhabitedregions;
int peasants;
int nunits;
@ -2994,6 +2995,9 @@ make_summary(boolean count_new)
s->nunits++;
s->playerpop += u->number;
if (u->flags & UFL_HERO) {
s->heroes += u->number;
}
s->spielerpferde += get_item(u, I_HORSE);
s->playermoney += get_money(u);
s->armed_men += armedmen(u);
@ -3318,6 +3322,9 @@ report_summary(summary * s, summary * o, boolean full)
pcomp(s->playerpop, o->playerpop));
fprintf(F, " davon bewaffnet: %s\n",
pcomp(s->armed_men, o->armed_men));
#ifdef HEROES
fprintf(F, " Helden: %s\n", pcomp(s->heroes, o->heroes));
#endif
if (full) {
fprintf(F, "Regionen: %d\n", listlen(regions));

View File

@ -1128,7 +1128,6 @@ unitlist_insert(struct unit_list **ul, struct unit *u)
*ul = rl2;
}
#ifdef HEROES
int
maxheroes(const struct faction * f)
{
@ -1146,4 +1145,3 @@ countheroes(const struct faction * f)
}
return n;
}
#endif

View File

@ -34,7 +34,7 @@ struct skill;
#define UFL_PARTEITARNUNG (1<<4) /* 16 */
#define UFL_DISBELIEVES (1<<5) /* 32 */
#define UFL_WARMTH (1<<6) /* 64 */
/* UFL_HERO, defined below (1<<7) */
#define UFL_HERO (1<<7)
#define UFL_MOVED (1<<8)
#define UFL_FOLLOWING (1<<9)
#define UFL_FOLLOWED (1<<10)
@ -57,11 +57,11 @@ struct skill;
#ifndef HEROES
# define UFL_SAVEMASK (UFL_NOAID | UFL_OWNER | UFL_PARTEITARNUNG | UFL_LOCKED | UFL_HUNGER | FFL_NOIDLEOUT | UFL_TAKEALL)
#else
# define UFL_HERO (1<<7)
# define UFL_SAVEMASK (UFL_NOAID | UFL_OWNER | UFL_PARTEITARNUNG | UFL_LOCKED | UFL_HUNGER | FFL_NOIDLEOUT | UFL_TAKEALL | UFL_HERO)
#endif
extern int maxheroes(const struct faction * f);
extern int countheroes(const struct faction * f);
#endif
typedef struct unit {
struct unit *next; /* needs to be first entry, for region's unitlist */