]> git.pond.sub.org Git - empserver/blobdiff - src/lib/commands/rada.c
commands: Rename the command functions
[empserver] / src / lib / commands / rada.c
index d21bbebb12e4cc91ba02d71e7fe60a9c9f8559c8..9d08255e696d5d16ac0e5a9e1508f2a761a7faf9 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-2021, Dave Pare, Jeff Bailey, Thomas Ruschak,
  *                Ken Stevens, Steve McClure, Markus Armbruster
  *
  *  Empire is free software: you can redistribute it and/or modify
 #include <config.h>
 
 #include "commands.h"
-#include "optlist.h"
 #include "unit.h"
 
 int
-rada(void)
+c_radar(void)
 {
     return radar(EF_SHIP);
 }
 
 int
-lrad(void)
+c_lradar(void)
 {
     return radar(EF_LAND);
 }
@@ -102,7 +101,13 @@ radar(int type)
                    continue;
                }
                if (item.land.lnd_ship >= 0) {
-                   pr("Units on ships can't use radar!\n");
+                   pr("%s is stowed on ship #%d, and can't use radar!\n",
+                      prland(&item.land), item.land.lnd_ship);
+                   continue;
+               }
+               if (item.land.lnd_land >= 0) {
+                   pr("%s is stowed on land #%d, and can't use radar!\n",
+                      prland(&item.land), item.land.lnd_land);
                    continue;
                }
                spy = lchr[item.land.lnd_type].l_spy;