Complete.Org: Mailing Lists: Archives: freeciv-dev: August 2002:
[Freeciv-Dev] Re: [PATCH] city_landlocked_sell_coastal_improvements gene
Home

[Freeciv-Dev] Re: [PATCH] city_landlocked_sell_coastal_improvements gene

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: freeciv-dev@xxxxxxxxxxx
Cc: bugs@xxxxxxxxxxxxxxxxxxx
Subject: [Freeciv-Dev] Re: [PATCH] city_landlocked_sell_coastal_improvements generalisation (PR#1105)
From: Ben Webb <ben@xxxxxxxxxxxxxxxxxxxxxx>
Date: Sat, 31 Aug 2002 10:25:44 -0700 (PDT)

On Fri, Aug 30, 2002 at 06:26:36PM -0700, Per I. Mathisen wrote:
> On Tue, 21 May 2002, Ben Webb wrote:
> >     Here's a modified version of the landlock patch. It now uses the
> > "nice" impr_type_iterate macro to iterate through all improvements (in a
> > recently-landlocked city) that are candidates for auto-selling.
> Why should this be done automatically?

        Why are you asking me? This is what is done in the current code;
I'm merely generalising it. But bear in mind that city improvements in
Freeciv do not have requirements for their activity - only for their
being built in the first place. For example, you need adjacent Ocean
tiles to _build_ a Port, but the code does not later check if you have
adjacent Ocean tiles before agreeing to repair ships in that city.
Getting rid of improvements that no longer have their build requirements
satisfied removes the necessity for such checks in the code - I'm
guessing this is why it was done originally.

> And if it should be done automatically, why should it be sold and not
> lost without compensation?

        Because you could sell the building yourself, in the turn before
the city became landlocked, and get the cash. Having the game penalise
you for forgetting to do this would just be a nuisance.

        Ben
-- 
ben@xxxxxxxxxxxxxxxxxxxxxx           http://bellatrix.pcl.ox.ac.uk/~ben/
"It is a capital mistake to theorize before one has data."
        - Sir Arthur Conan Doyle



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