forked from github/server
I don't really believe that this is going to work, but let's see where it fails.
This commit is contained in:
parent
04624179ce
commit
50eba2d308
1 changed files with 5 additions and 3 deletions
|
@ -332,7 +332,6 @@ void destroyfaction(faction ** fp)
|
||||||
{
|
{
|
||||||
faction * f = *fp;
|
faction * f = *fp;
|
||||||
unit *u = f->units;
|
unit *u = f->units;
|
||||||
faction *ff;
|
|
||||||
|
|
||||||
*fp = f->next;
|
*fp = f->next;
|
||||||
fset(f, FFL_QUIT);
|
fset(f, FFL_QUIT);
|
||||||
|
@ -394,7 +393,8 @@ void destroyfaction(faction ** fp)
|
||||||
}
|
}
|
||||||
|
|
||||||
handle_event(f->attribs, "destroy", f);
|
handle_event(f->attribs, "destroy", f);
|
||||||
/* alliedgroup and others should check sf.faction.alive before using a faction from f.allies
|
#if 0
|
||||||
|
faction *ff;
|
||||||
for (ff = factions; ff; ff = ff->next) {
|
for (ff = factions; ff; ff = ff->next) {
|
||||||
group *g;
|
group *g;
|
||||||
ally *sf, **sfp;
|
ally *sf, **sfp;
|
||||||
|
@ -421,7 +421,8 @@ void destroyfaction(faction ** fp)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
*/
|
#endif
|
||||||
|
|
||||||
if (f->alliance && f->alliance->_leader == f) {
|
if (f->alliance && f->alliance->_leader == f) {
|
||||||
setalliance(f, 0);
|
setalliance(f, 0);
|
||||||
}
|
}
|
||||||
|
@ -431,6 +432,7 @@ void destroyfaction(faction ** fp)
|
||||||
/* units of other factions that were disguised as this faction
|
/* units of other factions that were disguised as this faction
|
||||||
* have their disguise replaced by ordinary faction hiding. */
|
* have their disguise replaced by ordinary faction hiding. */
|
||||||
if (rule_stealth_other()) {
|
if (rule_stealth_other()) {
|
||||||
|
// TODO: f.alive should be tested for in get_otherfaction
|
||||||
region *rc;
|
region *rc;
|
||||||
for (rc = regions; rc; rc = rc->next) {
|
for (rc = regions; rc; rc = rc->next) {
|
||||||
for (u = rc->units; u; u = u->next) {
|
for (u = rc->units; u; u = u->next) {
|
||||||
|
|
Loading…
Reference in a new issue