diff --git a/src/common/gamecode/laws.c b/src/common/gamecode/laws.c
index f2b0e498a..852bef7fa 100644
--- a/src/common/gamecode/laws.c
+++ b/src/common/gamecode/laws.c
@@ -1173,6 +1173,21 @@ quit(void)
int dropouts[2];
int * age = NULL;
+static void
+nmr_death(faction * f)
+{
+ static int rule = -1;
+ if (rule<0) rule = get_param_int(global.parameters, "rules.nmr.destroy", 0);
+ if (rule) {
+ unit * u;
+ for (u=f->units;u;u=u->nextF) {
+ if (u->building && fval(u, UFL_OWNER)) {
+ remove_building(&u->region->buildings, u->building);
+ }
+ }
+ }
+}
+
static void
parse_restart(void)
{
@@ -1206,6 +1221,7 @@ parse_restart(void)
for (f = factions; f; f = f->next) {
if(fval(f, FFL_NOIDLEOUT)) f->lastorders = turn;
if (NMRTimeout()>0 && turn - f->lastorders >= NMRTimeout()) {
+ nmr_death(f);
destroyfaction(f);
continue;
}
diff --git a/src/res/e3a.xml b/src/res/e3a.xml
index 1f8647267..d64fa0d76 100644
--- a/src/res/e3a.xml
+++ b/src/res/e3a.xml
@@ -165,6 +165,7 @@
+