diff --git a/src/lib/subs/land.c b/src/lib/subs/land.c index 034393a5..e56846f6 100644 --- a/src/lib/subs/land.c +++ b/src/lib/subs/land.c @@ -28,7 +28,7 @@ * * Known contributors to this file: * Steve McClure, 1996 - * Markus Armbruster, 2004-2016 + * Markus Armbruster, 2004-2018 */ #include @@ -95,6 +95,8 @@ lnd_prewrite(int n, void *old, void *new) lp->lnd_land = land; if (!own || lp->lnd_x != oldlp->lnd_x || lp->lnd_y != oldlp->lnd_y) unit_update_cargo((struct empobj *)lp); + if (ship >= 0 || land >= 0) + lp->lnd_harden = 0; } char * diff --git a/src/lib/subs/plane.c b/src/lib/subs/plane.c index 21f3f3df..076dc887 100644 --- a/src/lib/subs/plane.c +++ b/src/lib/subs/plane.c @@ -29,7 +29,7 @@ * Known contributors to this file: * Dave Pare, 1989 * Steve McClure, 1996 - * Markus Armbruster, 2006-2016 + * Markus Armbruster, 2006-2018 */ #include @@ -95,6 +95,8 @@ pln_prewrite(int n, void *old, void *new) pp->pln_land = land; if (!own || pp->pln_x != oldpp->pln_x || pp->pln_y != oldpp->pln_y) unit_update_cargo((struct empobj *)pp); + if (ship >= 0 || land >= 0) + pp->pln_harden = 0; } char * diff --git a/tests/actofgod/final.xdump b/tests/actofgod/final.xdump index 34ac59b5..302ec834 100644 --- a/tests/actofgod/final.xdump +++ b/tests/actofgod/final.xdump @@ -191,7 +191,7 @@ uid owner xloc yloc type effic mobil off tech opx opy mission radius wing range 8 1 0 0 0 10 0 0 90 0 0 none 0 "" 9 0 -1 -1 () 0 0.00000 12 1 0 0 28 10 0 0 145 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000 13 1 0 0 28 10 0 0 145 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000 -14 1 1 -1 28 10 0 0 145 1 -1 none 0 "" 0 127 4 -1 () 0 0.00000 +14 1 1 -1 28 10 0 0 145 1 -1 none 0 "" 0 0 4 -1 () 0 0.00000 15 1 0 0 28 10 0 0 145 0 0 none 0 "" 0 127 -1 -1 () 0 0.00000 49 0 0 0 0 0 0 0 0 0 0 none 0 "" 0 0 -1 -1 () 0 0.00000 /config @@ -201,7 +201,7 @@ uid owner xloc yloc type effic mobil off tech opx opy mission radius army ship h 1 98 1 -1 6 10 0 0 100 0 0 none 0 "" -1 0 42 () "" 0 0 0 0 0 0 0 0 0 0 0 0 0 0 healthy 0 -1 0 2 2 3 -1 6 10 -127 0 50 0 0 none 0 "" -1 0 0 (group) "" 0 1 1 1 1 1 1 1 1 0 1 1 0 0 healthy 0 -1 0 3 3 1 -1 6 10 -127 0 50 0 0 none 0 "a" 3 0 0 (injured) "jj" 0 0 0 0 0 0 0 0 0 0 0 0 0 0 healthy 0 -1 0 -4 3 3 -1 6 100 127 0 32767 0 0 none 0 "" 2 127 100 () "" 0 25 0 0 0 0 0 0 0 0 0 0 0 0 healthy 0 -1 0 +4 3 3 -1 6 100 127 0 32767 0 0 none 0 "" 2 0 100 () "" 0 25 0 0 0 0 0 0 0 0 0 0 0 0 healthy 0 -1 0 5 3 1 -1 6 100 127 0 32767 0 0 none 0 "" -1 127 100 () "" 0 25 0 0 0 0 0 0 0 0 0 0 0 0 healthy 0 -1 0 6 1 0 0 11 10 0 0 100 0 0 none 0 "" -1 0 0 () "" 0 0 0 10 0 0 0 0 0 0 0 0 0 0 healthy 0 -1 0 49 0 0 0 0 0 0 0 0 0 0 none 0 "" -1 0 0 () "" 0 0 0 0 0 0 0 0 0 0 0 0 0 0 healthy 0 -1 0 diff --git a/tests/actofgod/geninput.pl b/tests/actofgod/geninput.pl index ce595139..a6e0f9d9 100755 --- a/tests/actofgod/geninput.pl +++ b/tests/actofgod/geninput.pl @@ -343,11 +343,9 @@ edit('plane', 4, 'l', '5,1'); # special case: load teleports to carrier # (previous loads already zapped fortification) -# BUG: fortification not zapped edit('land', 4, 'S', 2); # special case: load teleports to carrier and zaps fortification -# BUG: fortification not zapped edit('plane', 14, 's', 4); # interactive edit