Complete.Org: Mailing Lists: Archives: freeciv-dev: February 2000:
[Freeciv-Dev] Re: Bug with worklists and auto-upgrading unit targets
Home

[Freeciv-Dev] Re: Bug with worklists and auto-upgrading unit targets

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: ½²«íµØ <iquin@xxxxxxxxxx>
Cc: freeciv-dev@xxxxxxxxxxx
Subject: [Freeciv-Dev] Re: Bug with worklists and auto-upgrading unit targets
From: Corin Anderson <corin@xxxxxxxxxx>
Date: Wed, 9 Feb 2000 22:18:36 -0800 (PST)

On Thu, 10 Feb 2000, [ISO-8859-1] ½²«íµØ wrote:

> If I'm not mistaken, can_eventually_build_improvement() is a
> redundant copy of could_build_improvement() with many "B_"s in it.

No, these functions serve two different roles:

can_eventually_build_improvement() is meant to test if a city will ever be
able to build an improvement.  Never mind if a prerequisite building has
been built, or if the tech has been researched yet -- just return 1 iff
the city can -eventually- build the improvement.

could_build_improvement() tests if a city can build an improvement *right
now*.  This function tests if prerequisite improvements (such as a library
for a university) exist, if the tech exists now, etc.

Corey




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