]> git.pond.sub.org Git - empserver/blobdiff - src/lib/commands/tran.c
Update copyright notice
[empserver] / src / lib / commands / tran.c
index 6b1e67f6efc86fb9eec50ad56db84327b7eadc88..0fd9f245edee518b0cd22f0743554eb6fc0868c3 100644 (file)
@@ -1,6 +1,6 @@
 /*
  *  Empire - A multi-player, client/server Internet based war game.
- *  Copyright (C) 1986-2011, Dave Pare, Jeff Bailey, Thomas Ruschak,
+ *  Copyright (C) 1986-2016, Dave Pare, Jeff Bailey, Thomas Ruschak,
  *                Ken Stevens, Steve McClure, Markus Armbruster
  *
  *  Empire is free software: you can redistribute it and/or modify
  *
  *  Known contributors to this file:
  *     Steve McClure, 2000
- *     Markus Armbruster, 2006-2009
+ *     Markus Armbruster, 2006-2011
  */
 
 #include <config.h>
 
 #include "commands.h"
-#include "land.h"
+#include "map.h"
 #include "nuke.h"
 #include "plane.h"
-#include "ship.h"
 
-static int tran_pmap(coord curx, coord cury, char *arg);
-static int tran_nmap(coord curx, coord cury, char *arg);
+static int tran_pmap(coord, coord, char *, char *);
+static int tran_nmap(coord, coord, char *, char *);
 static int tran_nuke(void);
 static int tran_plane(void);
 
@@ -169,7 +168,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",
@@ -244,13 +248,13 @@ tran_plane(void)
  */
 /*ARGSUSED*/
 static int
-tran_pmap(coord curx, coord cury, char *arg)
+tran_pmap(coord curx, coord cury, char *arg1, char *arg2)
 {
-    return display_region_map(0, EF_PLANE, curx, cury, arg);
+    return display_region_map(0, EF_PLANE, curx, cury, arg1, arg2);
 }
 
 static int
-tran_nmap(coord curx, coord cury, char *arg)
+tran_nmap(coord curx, coord cury, char *arg1, char *arg2)
 {
-    return display_region_map(0, EF_NUKE, curx, cury, arg);
+    return display_region_map(0, EF_NUKE, curx, cury, arg1, arg2);
 }