/*
* Empire - A multi-player, client/server Internet based war game.
- * Copyright (C) 1986-2008, Dave Pare, Jeff Bailey, Thomas Ruschak,
+ * Copyright (C) 1986-2010, Dave Pare, Jeff Bailey, Thomas Ruschak,
* Ken Stevens, Steve McClure
*
* This program is free software; you can redistribute it and/or modify
* ---
*
* shi.c: Show a list of your ships
- *
+ *
* Known contributors to this file:
* Steve McClure, 2000
*/
int
shi(void)
{
- int nships, noff;
+ int nships, noff, npln, nch, nxl;
struct nstr_item ni;
struct shpstr ship;
while (nxtitem(&ni, &ship)) {
if (!player->owner || ship.shp_own == 0)
continue;
- count_planes(&ship);
- count_units(&ship);
if (nships++ == 0) {
if (player->god)
pr("own ");
pr("%4d", ship.shp_item[I_UW]);
pr("%4d", ship.shp_item[I_FOOD]);
- pr("%3d", ship.shp_nplane);
- pr("%3d", ship.shp_nchoppers);
- pr("%3d", ship.shp_nxlight);
- pr("%3d", ship.shp_nland);
+ npln = shp_nplane(&ship, &nch, &nxl, NULL);
+ pr("%3d%3d%3d", npln - nch - nxl, nch, nxl);
+ pr("%3d", shp_nland(&ship));
pr("%4d", ship.shp_mobil);
pr("%5d\n", ship.shp_tech);
if (ship.shp_name[0] != 0) {