[Freeciv-Dev] Re: (PR#7213) is_attack_unit(punit)
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
<URL: http://rt.freeciv.org/Ticket/Display.html?id=7213 >
On Thu, Jan 08, 2004 at 12:59:06PM -0800, Jason Short wrote:
>
> <URL: http://rt.freeciv.org/Ticket/Display.html?id=7213 >
>
> Raimar Falke wrote:
> > <URL: http://rt.freeciv.org/Ticket/Display.html?id=7213 >
>
> >>- if (is_military_unit(punit) && unit_type(punit)->attack_strength > 0
> >>- && map_get_city(punit->x, punit->y))
> >>+ }
> >>+ if (is_attack_unit(punit) && map_get_city(punit->x, punit->y)) {
> >> return TRUE;
> >>+ }
> >
> >
> > This doesn't seem an equivalent transformation.
>
> is_attack_unit implies is_military_unit.
Because?
> But some military units may
> have 0 attack.
>
> What if a non-military unit had nonzero attack rating?
Exactly such questions should be answered in the function
headers. Just list all the implications of an attack-unit and a
military-unit.
Raimar
--
email: rf13@xxxxxxxxxxxxxxxxx
"brand memory are for windows users that think their stability
problems come from the memory"
-- bomek in #freeciv
|
|