"Tarnung und Bilden neuer Einheiten"

Tarn-Status wird vererbt
This commit is contained in:
Enno Rehling 2007-06-07 20:42:00 +00:00
parent 29cfece1f3
commit 4a75e13cb0
3 changed files with 14 additions and 7 deletions

View File

@ -1963,10 +1963,20 @@ create_unit(region * r, faction * f, int number, const struct race *urace, int i
u->ship = creator->ship; u->ship = creator->ship;
} }
/* Temps von parteigetarnten Einheiten sind wieder parteigetarnt */ /* Tarnlimit wird vererbt */
if (fval(creator, UFL_PARTEITARNUNG)) if (fval(creator, UFL_STEALTH)) {
fset(u, UFL_PARTEITARNUNG); attrib * a = a_find(creator->attribs, &at_stealth);
if (a) {
int stealth = a->data.i;
a = a_add(&u->attribs, a_new(&at_stealth));
a->data.i = stealth;
}
}
/* Temps von parteigetarnten Einheiten sind wieder parteigetarnt */
if (fval(creator, UFL_PARTEITARNUNG)) {
fset(u, UFL_PARTEITARNUNG);
}
/* Daemonentarnung */ /* Daemonentarnung */
set_racename(&u->attribs, get_racename(creator->attribs)); set_racename(&u->attribs, get_racename(creator->attribs));
if (fval(u->race, RCF_SHAPESHIFT) && fval(creator->race, RCF_SHAPESHIFT)) { if (fval(u->race, RCF_SHAPESHIFT) && fval(creator->race, RCF_SHAPESHIFT)) {

View File

@ -234,9 +234,6 @@ static lstr lstrs[MAXLOCALES];
struct tnode * struct tnode *
get_translations(const struct locale * lang, int index) get_translations(const struct locale * lang, int index)
{ {
static struct lstr * lnames = NULL;
static const struct locale * lastlang = NULL;
assert(lang->index<MAXLOCALES || "you have to increase MAXLOCALES and recompile"); assert(lang->index<MAXLOCALES || "you have to increase MAXLOCALES and recompile");
if (lang->index<MAXLOCALES) { if (lang->index<MAXLOCALES) {
return lstrs[lang->index].tokens+index; return lstrs[lang->index].tokens+index;