[Freeciv-Dev] Re: Reproducable core dump (PR#1051)
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
Raimar Falke wrote:
And another version. Changes:
- unified "safe", "empty" and "usable" to "safe"
- various changes in comments
- style changes (extra {} and such)
I now understand and like the function ;)
The changes look good.
+ /* Planes _always_ use SINLGE_MOVE a time so here we can just
+ use 1 instead of SINGLE_MOVE */
SINGLE_MOVE is misspelled here. (Also, I don't quite understand this
comment. If it were up to me I'd say "planes _always_ use 1 move at a
time so we must use 1 instead of SINGLE_MOVE", but I don't understand
the relevant code as much as Gregory. It also seems to me that this 1
should be #defined somewhere, perhaps as
#define AIR_SINGLE_MOVE 1
Off-topic: This assumes planes fly at the same rate over all terrain.
Seems reasonable. We might be tempted to also say
#define SEA_SINGLE_MOVE 1
but sea units do _not_ travel at the same rate over all terrain in the
SMAC ruleset.
jason
|
|