"0 Wirkungen Siebenmeilentee"
Ausgabe in CR und NR respektiert "leere" attribute.
Issue: 960
This commit is contained in:
Enno Rehling 2006-07-24 20:49:58 +00:00
parent 88ecdd173a
commit 02b012ed47
2 changed files with 12 additions and 8 deletions

View File

@ -266,12 +266,14 @@ print_curses(FILE * F, const faction * viewer, const void * obj, typ_t typ)
}
} else if (a->type==&at_effect && self) {
effect_data * data = (effect_data *)a->data.v;
const char * key = resourcename(data->type->itype->rtype, 0);
if (!header) {
header = 1;
fputs("EFFECTS\n", F);
if (data->value>0) {
const char * key = resourcename(data->type->itype->rtype, 0);
if (!header) {
header = 1;
fputs("EFFECTS\n", F);
}
fprintf(F, "\"%d %s\"\n", data->value, add_translation(key, locale_string(default_locale, key)));
}
fprintf(F, "\"%d %s\"\n", data->value, add_translation(key, locale_string(default_locale, key)));
}
a = a->next;
}

View File

@ -511,13 +511,15 @@ print_curses(FILE *F, const faction *viewer, const void * obj, typ_t typ, int in
}
} else if (a->type==&at_effect && self) {
effect_data * data = (effect_data *)a->data.v;
sprintf(buf, "Auf der Einheit lieg%s %d Wirkung%s %s.",
if (data->value>0) {
sprintf(buf, "Auf der Einheit lieg%s %d Wirkung%s %s.",
(data->value==1 ? "t" : "en"),
data->value,
(data->value==1 ? "" : "en"),
LOC(default_locale, resourcename(data->type->itype->rtype, 0)));
rnl(F);
rparagraph(F, buf, indent, 2, 0);
rnl(F);
rparagraph(F, buf, indent, 2, 0);
}
}
}
}