(do_mob_land): Simplify fortification. No functional change.
This commit is contained in:
parent
78008c69fa
commit
0e6508c556
1 changed files with 10 additions and 9 deletions
|
@ -392,15 +392,16 @@ do_mob_land(struct lndstr *lp, int etus)
|
|||
if (opt_FUEL == 0 || lp->lnd_fuelu == 0) {
|
||||
value = lp->lnd_mobil + ((float)etus * land_mob_scale);
|
||||
if (value > land_mob_max) {
|
||||
if (!opt_MOB_ACCESS) {
|
||||
/*
|
||||
* provide mobility to be used in lnd_fortify()
|
||||
* without overflowing lnd_mobil
|
||||
* Provide mobility to be used in lnd_fortify()
|
||||
* without overflowing lnd_mobil.
|
||||
*/
|
||||
lp->lnd_mobil = land_mob_max;
|
||||
if (!opt_MOB_ACCESS)
|
||||
lnd_fortify(lp, value - land_mob_max);
|
||||
lp->lnd_mobil = land_mob_max;
|
||||
} else
|
||||
}
|
||||
value = land_mob_max;
|
||||
}
|
||||
lp->lnd_mobil = value;
|
||||
|
||||
} else {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue