tend ltend: Improve "cannot hold any" message

Report the exact ship, like

    frg  frigate (#170) cannot hold any uncompensated workers

instead of reporting just the ship type, like

    A frg  frigate cannot hold any uncompensated workers

This is a bit more useful when tending to more than one ship.

Signed-off-by: Markus Armbruster <armbru@pond.sub.org>
This commit is contained in:
Markus Armbruster 2017-09-14 12:18:56 +02:00
parent f4dc2e1e79
commit 6035487287
3 changed files with 6 additions and 8 deletions

View file

@ -90,8 +90,7 @@ ltend(void)
vbase = &mchr[(int)tender.shp_type];
maxtender = vbase->m_item[ip->i_uid];
if (maxtender == 0) {
pr("A %s cannot hold any %s\n",
mchr[(int)tender.shp_type].m_name, ip->i_name);
pr("%s cannot hold any %s\n", prship(&tender), ip->i_name);
continue;
}
if (!snxtitem(&targets, EF_LAND,