Complete.Org: Mailing Lists: Archives: freeciv-dev: May 2003:
[Freeciv-Dev] Re: (PR#4267) Update unitproduction when new tech is resea
Home

[Freeciv-Dev] Re: (PR#4267) Update unitproduction when new tech is resea

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: ue80@xxxxxxxxxxxxxxxxxxxxx
Subject: [Freeciv-Dev] Re: (PR#4267) Update unitproduction when new tech is researched
From: "Per I. Mathisen" <per@xxxxxxxxxxx>
Date: Wed, 28 May 2003 14:20:35 -0700
Reply-to: rt@xxxxxxxxxxxxxx

On Tue, 20 May 2003, ue80@xxxxxxxxxxxxxxxxxxxxx wrote:
> Ok, i've looked in the code ... the server only has updated when it
> was possible to build "unit_types[id].obsoleted_by". That check was
> wrong.

Yes. Good catch. I'll commit your fix.

> What i don't like is that in unittype.c is can_upgrade_unittype which is
> nearly the same as unit_upgrades_to from cityturn.c, why 2 functions?

They check different things. The one in unittype.c checks if _player_ can
build the unit, while the check in cityturn.c checks if _city_ can build
it. This might be important eg if we upgrade a ground unit into a sea
unit.

  - Per




[Prev in Thread] Current Thread [Next in Thread]
  • [Freeciv-Dev] Re: (PR#4267) Update unitproduction when new tech is researched, Per I. Mathisen <=