]> git.pond.sub.org Git - empserver/commitdiff
bomb: Fix to reject attempts to bomb unused planes
authorMarkus Armbruster <armbru@pond.sub.org>
Sun, 11 Jan 2015 09:35:22 +0000 (10:35 +0100)
committerMarkus Armbruster <armbru@pond.sub.org>
Mon, 2 Mar 2015 07:20:49 +0000 (08:20 +0100)
Report "not spotted", like we do for unused ships and land units.
Missed in commit 23d52a4, v4.3,16.

Signed-off-by: Markus Armbruster <armbru@pond.sub.org>
src/lib/commands/bomb.c

index b90f3acf6bae672f79f97c5e6d269b328bc04868..5ea899e38bafb5884614077c5dba9011714d9e3f 100644 (file)
@@ -535,7 +535,7 @@ plane_bomb(struct emp_qelem *list, struct sctstr *target)
            n = atoi(q);
            if (n < 0)
                continue;
-           if (getplane(n, &plane) &&
+           if (getplane(n, &plane) && plane.pln_own &&
                plane.pln_x == target->sct_x &&
                plane.pln_y == target->sct_y &&
                plane.pln_ship < 0 && plane.pln_land < 0 &&