This is the mail archive of the xconq7@sources.redhat.com mailing list for the Xconq project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: The selective fire-at command


On Tue, 17 Aug 2004, Hans Ronne wrote:

> You will notice that the pixel coordinates are converted to (x, y) by
> nearest_cell, and these cell coordinates are then passed on to
> common_fire_at. What this means is that all information about what unit
> within the cell you were trying to target is lost.

Right, and that caused problems later on when one needed more 
information in the 'common_fire_at' routine.

>         if (unit->side != side_n(uview->siden)) {
>             other = uview->unit;
>             /* Assume we have the right target. (Bad assumption,
>                but what else can one do with the info presently available?) */

I think the comment says it all. The function did what it could 
with the info available.

> Now, two comments. First, the fire-at command does work in the Mac
> interface since the pixel coordinates are passed on and the unit under the
> cursor is identified. 

I think that when I was working on the Dec 29 fix, I wanted to fix 
this as well, but wasn't sure how to go about it because I didn't 
know the Tcl/Tk interface code all that well. In retrospect, I 
should have looked at the attack code for guidance.

Eric


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]