Complete.Org: Mailing Lists: Archives: freeciv-dev: April 2002:
[Freeciv-Dev] Re: tech bug fixes (PR#1330)
Home

[Freeciv-Dev] Re: tech bug fixes (PR#1330)

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: "Per I. Mathisen" <Per.Inge.Mathisen@xxxxxxxxxxx>
Cc: freeciv-dev@xxxxxxxxxxx, bugs@xxxxxxxxxxxxxxxxxxx
Subject: [Freeciv-Dev] Re: tech bug fixes (PR#1330)
From: Raimar Falke <hawk@xxxxxxxxxxxxxxxxxxxxxxx>
Date: Thu, 4 Apr 2002 21:21:27 +0200
Reply-to: rf13@xxxxxxxxxxxxxxxxxxxxxx

On Mon, Mar 18, 2002 at 06:11:40AM -0800, Per I. Mathisen wrote:
> -  int saved_bulbs;
> +  int saved_bulbs = 0;

I moved saved_bulbs althogether.

> -    if (saving_bulbs) {
> +    if (saving_bulbs != 0) {

Not needed since it is a bool.

>  void update_tech(struct player *plr, int bulbs)
>  {
>    int missing = total_bulbs_required(plr) - plr->research.bulbs_researched;
> -
> -  assert(missing > 0);

See attached patch. It is shorter and also removed the limit that you
can only research N techs/turn where N is the number of cities you
have.

        Raimar

-- 
 email: rf13@xxxxxxxxxxxxxxxxx
  "With a PC, I always felt limited by the software available.
   On Unix, I am limited by my knowledge."
    -- Peter J. Schoenster <pschon@xxxxxxxxxxxxxxxxx>

Attachment: techupdatefix2.patch
Description: Text document


[Prev in Thread] Current Thread [Next in Thread]
  • [Freeciv-Dev] Re: tech bug fixes (PR#1330), Raimar Falke <=