From: Markus Armbruster Date: Sat, 16 Jul 2011 07:10:46 +0000 (+0200) Subject: Fix transport to reject planes loaded on land units X-Git-Tag: v4.3.28~5 X-Git-Url: http://git.pond.sub.org/?p=empserver;a=commitdiff_plain;h=41dc6de306533983b7e4bd546828014343ec1d17 Fix transport to reject planes loaded on land units The transported plane remains on its carrier. When the land unit moves, the plane is teleported right back to it. Broken since Chainsaw 3 added land units. While there, improve the message for planes on ships. --- diff --git a/src/lib/commands/tran.c b/src/lib/commands/tran.c index 849a417fc..47e1b2c61 100644 --- a/src/lib/commands/tran.c +++ b/src/lib/commands/tran.c @@ -170,7 +170,12 @@ tran_plane(void) continue; type = plane.pln_type; if (plane.pln_ship >= 0) { - pr("%s is at sea and can't be transported\n", prplane(&plane)); + pr("%s is stowed on ship #%d, and can't be transported\n", + prplane(&plane), plane.pln_ship); + return RET_FAIL; + } else if (plane.pln_land >= 0) { + pr("%s is stowed on land #%d, and can't be transported\n", + prplane(&plane), plane.pln_land); return RET_FAIL; } else if (plane.pln_harden != 0) { pr("%s has been hardened and can't be transported\n",