Complete.Org: Mailing Lists: Archives: freeciv-dev: January 2005:
[Freeciv-Dev] (PR#11601) likely_ocean() cheats
Home

[Freeciv-Dev] (PR#11601) likely_ocean() cheats

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: marko.lindqvist@xxxxxxxxxxx
Subject: [Freeciv-Dev] (PR#11601) likely_ocean() cheats
From: "Jason Short" <jdorje@xxxxxxxxxxxxxxxxxxxxx>
Date: Sun, 2 Jan 2005 16:45:47 -0800
Reply-to: bugs@xxxxxxxxxxx

<URL: http://bugs.freeciv.org/Ticket/Display.html?id=11601 >

> [glip - Sun Jan 02 23:47:13 2005]:
> 
> > [cazfi - Sun Dec 19 12:08:32 2004]:
> > 
> > 
> >   This is no longer true:
> > 
> >     /* If a tile is cardinally adjacent, we can tell if the
> >      * central tile is ocean or not by the appearance of
> >      * the adjacent tile. So, given that we can tell,
> >      * it's fair to look at the actual tile. */
> >          return (is_ocean(map_get_terrain(ptile)) ? 100 : 0);
> 
> Is it because of the isometric mode?
> Then we need "is_edge_adjacent" function.  Jason?

No, it's because there used to be code in freeciv that would send
terrain info to the client for any tiles that were (cardinally) adjacent
to known tiles.  This was, basically, cheating since it gave you extra
information.  It caused problem with client goto which didn't know any
better than to use this information (resulting in weird goto routes) and 
with a little hacking of the client you could see the whole tile -
effectively increasing the vision range of your units (very useful at
the beginning).  Fortunately this whole thing was removed and now there
is no cheating.

The cheat in is_ocean is trying to mimic the old client cheat.

BTW, there is an is_cardinally_adjacent function I think.

jason




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