Factor out land unit firing range calculation into lnd_fire_range()
This commit is contained in:
parent
ad5f8e8904
commit
76830b5b98
5 changed files with 15 additions and 6 deletions
|
@ -1137,7 +1137,7 @@ lnd_support(natid victim, natid attacker, coord x, coord y, int defending)
|
|||
/* are we in range? */
|
||||
dist = mapdist(land.lnd_x, land.lnd_y, x, y);
|
||||
|
||||
range = roundrange(effrange(land.lnd_frg, land.lnd_tech));
|
||||
range = roundrange(lnd_fire_range(&land));
|
||||
if (dist > range)
|
||||
continue;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue