[Freeciv-Dev] Re: (PR#14443) city walls not visible (effects problem)
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
<URL: http://bugs.freeciv.org/Ticket/Display.html?id=14443 >
On 11/20/05, Vasco Alexandre da Silva Costa <vasco.costa@xxxxxxxxx> wrote:
> On 11/20/05, Vasco Alexandre da Silva Costa <vasco.costa@xxxxxxxxx> wrote:
> Now I notice those are *defender* units, not the attacker unit. Blech.
>
> Shouldn't the EFT_DEFEND_BONUS effects queries be passed the defender unit,
> rather than the attacking unit, like effects.c says? They are defender
> modifiers after
> all, no?
Bah, I looked at it again and what I said makes no sense. :-)
Barring passing dummy units to the EFT_DEFEND_BONUS query, or reverting that
piece, I have another quite evil idea...
We make yet another effects query function which gets passed a struct
unit_class pointer:
get_city_defense_bonus(defending_city, attacking_unit_class, effect_type).
You use it like this:
get_city_defense_bonus(pcity, UCL_LAND, EFT_DEFEND_BONUS)
The rest is a matter of creative coding...
We can worry about making unit effects better later...
I believe we did not think the problem right last time and a proper
fix will be complex
enough that it should be for post 2.1.
Is EFT_DEFEND_BONUS the only one with a problem here?
- [Freeciv-Dev] Re: (PR#14628) City walls gone, Jason Short, 2005/11/17
- [Freeciv-Dev] (PR#14443) city walls not visible (effects problem), Jason Short, 2005/11/18
- [Freeciv-Dev] Re: (PR#14443) city walls not visible (effects problem), Per I. Mathisen, 2005/11/19
- [Freeciv-Dev] Re: (PR#14443) city walls not visible (effects problem), Jason Short, 2005/11/19
- [Freeciv-Dev] Re: (PR#14443) city walls not visible (effects problem), Vasco Alexandre da Silva Costa, 2005/11/20
- [Freeciv-Dev] Re: (PR#14443) city walls not visible (effects problem), Vasco Alexandre da Silva Costa, 2005/11/20
- [Freeciv-Dev] (PR#14443) city walls not visible (effects problem), Vasco Alexandre da Silva Costa, 2005/11/20
- [Freeciv-Dev] Re: (PR#14443) city walls not visible (effects problem), Vasco Alexandre da Silva Costa, 2005/11/20
- [Freeciv-Dev] Re: (PR#14443) city walls not visible (effects problem),
Vasco Alexandre da Silva Costa <=
- [Freeciv-Dev] Re: (PR#14443) city walls not visible (effects problem), Jason Short, 2005/11/20
- [Freeciv-Dev] Re: (PR#14443) city walls not visible (effects problem), Jason Short, 2005/11/20
- [Freeciv-Dev] (PR#14443) effects queries give useless results when not passed appropriate parameters, Jason Short, 2005/11/21
|
|