(doship, doplane, dounit): Fix warnings introduced by previous rev.

This commit is contained in:
Markus Armbruster 2004-05-16 14:24:57 +00:00
parent c2debd73fc
commit a28c6e4373

View file

@ -848,7 +848,8 @@ doship(s_char op, int arg, s_char *p, struct shpstr *ship)
break; break;
case 'T': case 'T':
shp_set_tech(ship, shp_set_tech(ship,
errcheck(arg, mchr[ship->shp_type].m_tech, SHRT_MAX)); errcheck(arg,
mchr[(int)ship->shp_type].m_tech, SHRT_MAX));
break; break;
case 'E': case 'E':
ship->shp_effic = errcheck(arg, SHIP_MINEFF, 100); ship->shp_effic = errcheck(arg, SHIP_MINEFF, 100);
@ -972,7 +973,8 @@ dounit(s_char op, int arg, s_char *p, float farg, struct lndstr *land)
break; break;
case 't': case 't':
lnd_set_tech(land, lnd_set_tech(land,
errcheck(arg, lchr[land->lnd_type].l_tech, SHRT_MAX)); errcheck(arg,
lchr[(int)land->lnd_type].l_tech, SHRT_MAX));
break; break;
case 'a': case 'a':
if (p[0] == '~') if (p[0] == '~')
@ -1113,7 +1115,8 @@ doplane(s_char op, int arg, s_char *p, struct plnstr *plane)
break; break;
case 't': case 't':
pln_set_tech(plane, pln_set_tech(plane,
errcheck(arg, plchr[plane->pln_type].pl_tech, SHRT_MAX)); errcheck(arg,
plchr[(int)plane->pln_type].pl_tech, SHRT_MAX));
break; break;
case 'w': case 'w':
if (p[0] == '~') if (p[0] == '~')