Complete.Org: Mailing Lists: Archives: freeciv-dev: August 2003:
[Freeciv-Dev] (PR#4718) topology cleanup for client autocenter code
Home

[Freeciv-Dev] (PR#4718) topology cleanup for client autocenter code

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: undisclosed-recipients: ;
Subject: [Freeciv-Dev] (PR#4718) topology cleanup for client autocenter code
From: "Jason Short" <jdorje@xxxxxxxxxxxxxxxxxxxxx>
Date: Mon, 4 Aug 2003 14:03:25 -0700
Reply-to: rt@xxxxxxxxxxxxxx

[rwetmore@xxxxxxxxxxxx - Sun Aug  3 06:14:47 2003]:

> I think you quit reading again ... I have reposted the fix supplied
> with
> explanation to kickstart the process.

Indeed.  When you quote the entire original message there is a tendancy
to skip over the parts that you don't reply to.  Sometimes there's a
reply hidden in there.

> Note, your fix to the fix is wrong as you admit.

Err, what?

> It is the case that (xm + ym) will always cover the full map, while
> the
> MAX of either one will fail in iso-native topologies. The sum is also
> more efficient than the compare, and one should never write bad code
> when
> good is trivially available.

This is the case, but it's a hack to hard-code it in this code.  The
original patch had a map_std_xsize() and map_std_ysize() functions that
returns the dimensions of the map in "map" coordinates - this is exactly
what your code does.  But IMO we're better off without these functions,
since then there would be the temptation to use them and this is the
only place that "needs" them.

Note, "needs" is in quotations since this piece of code probably doesn't
have to exist at all.  It's just a 4th-level backup for finding
something to center on.

jason



[Prev in Thread] Current Thread [Next in Thread]