Don't store ship stats in struct shpstr

New shp_armor(), shp_speed(), shp_visib(), shp_frnge(), shp_glim()
replace the struct shpstr members with the same names.
This commit is contained in:
Markus Armbruster 2008-03-04 21:15:59 +01:00
parent ffc5d0cfd7
commit f86d726406
13 changed files with 73 additions and 45 deletions

View file

@ -161,9 +161,9 @@ look_ship(struct shpstr *lookship)
continue;
tmcp = &mchr[(int)sp->shp_type];
if (smcp->m_flags & M_SUB)
vrange = (int)(sp->shp_visib * range / 30.0);
vrange = (int)(shp_visib(sp) * range / 30.0);
else
vrange = (int)(sp->shp_visib * range / 20.0);
vrange = (int)(shp_visib(sp) * range / 20.0);
getsect(sp->shp_x, sp->shp_y, &sect);
if (sect.sct_type != SCT_WATER)
vrange = MAX(1, vrange);