[Freeciv-Dev] Re: Bug #202 : transporter content shown instead of the t
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
At 2000/03/15 12:14 , Thue Janus Kristensen wrote:
>On Wed, 15 Mar 2000, Jeff Mallatt wrote:
>> At 2000/03/15 11:01 , you wrote:
>> >On Wed, 15 Mar 2000, Jeff Mallatt wrote:
>> >> Oops. Just discovered a bug with this. Units which attack from a
>> >> transporter are not seen by the victim. E.g., put a Marines on a
>> >> Transport, and attack something along the shore with the Marines
directly
>> >> from the Transport. The victim player doesn't see the Marines --
just the
>> >> Transport.
>> >
>> >That would affect ships attacking from a square containing a transport
>> too. :(
>> >I'll have a look.
>
>Ok - new patch attacked.
>To make sure the attacking and defending units were shown on top
>set_unit_focus_no_center was previously used, as it had the sideeffect of
>putting the focus_no_center'ed unit first in the genlist, and so picked by
>get_visible_unit (HACK!).
Yes. Thanks for finding this.
>I introduced 2 new pointers in control.h (is that the
>estetically right place?) named punit_attacking and punit_defending that when
>non-NULL point to units that should be shown on top, and handle them in
>get_visible_unit.
Yes, I believe that's the correct module, but let's make it a little
cleaner than just some global variables...
The attached patch is Thue's, with the following changes:
1. Wrapped the new state variables in a functional interface (see
set_units_in_combat()). Made them private to control.c.
2. I believe the resetting of the combat units was in the wrong place in
the Xaw client. Moved before the tile refreshes.
3. In both clients, I rearranged the setting of the combat units in
decrease_unit_hp_smooth() to account for the case where do_combat_animation
is false.
4. Added ()'s around assignments in if's to silence warnings from my compiler.
5. Swapped the precedence of the focus unit and the attack/defend units in
find_visible_unit(). Since combat is momentary, I think we really want
both combatants visible; the focus unit will pop to the top when combat is
over.
show_transporter_on_top-9.diff
Description: Text document
jjm
- [Freeciv-Dev] Bug #202 : transporter content shown instead of the transport, Thue Janus Kristensen, 2000/03/13
- [Freeciv-Dev] Re: Bug #202 : transporter content shown instead of the transport, Jeff Mallatt, 2000/03/13
- [Freeciv-Dev] Re: Bug #202 : transporter content shown instead of the transport, Jeff Mallatt, 2000/03/13
- [Freeciv-Dev] Re: Bug #202 : transporter content shown instead of the transport, Jeff Mallatt, 2000/03/15
- [Freeciv-Dev] Re: Bug #202 : transporter content shown instead of the transport, Thue Janus Kristensen, 2000/03/15
- Message not available
- [Freeciv-Dev] Re: Bug #202 : transporter content shown instead of the transport, Thue Janus Kristensen, 2000/03/15
- [Freeciv-Dev] Re: Bug #202 : transporter content shown instead of the transport,
Jeff Mallatt <=
- [Freeciv-Dev] Re: Bug #202 : transporter content shown instead of the transport, Sebastian Bauer, 2000/03/16
- [Freeciv-Dev] Re: Bug #202 : transporter content shown instead of the transport, Thue Janus Kristensen, 2000/03/16
- [Freeciv-Dev] Re: Bug #202 : transporter content shown instead of the transport, Jules Bean, 2000/03/16
- [Freeciv-Dev] Re: Bug #202 : transporter content shown instead of the transport, Sebastian Bauer, 2000/03/16
- [Freeciv-Dev] Re: Bug #202 : transporter content shown instead of the transport, Sebastian Bauer, 2000/03/16
- [Freeciv-Dev] Re: Bug #202 : transporter content shown instead of the transport, martin, 2000/03/16
|
|