Complete.Org: Mailing Lists: Archives: freeciv-dev: June 2005:
[Freeciv-Dev] Re: (PR#13360) Choose random tech and future tech
Home

[Freeciv-Dev] Re: (PR#13360) Choose random tech and future tech

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: mstefek@xxxxxxxxx
Subject: [Freeciv-Dev] Re: (PR#13360) Choose random tech and future tech
From: "Jason Short" <jdorje@xxxxxxxxxxxxxxxxxxxxx>
Date: Tue, 28 Jun 2005 14:46:52 -0700
Reply-to: bugs@xxxxxxxxxxx

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

Mateusz Stefek wrote:

> enum tech_state get_invention(const struct player *pplayer,
>                             Tech_type_id tech)
> {
>   assert(tech >= 0 || tech < game.control.num_tech_types);
> 
>   return get_player_research(pplayer)->inventions[tech].state;
> }
> 
> I think the author intended the function to be called only with real 
> techs, but he messed the assertion and for a very long time everything
> looked ok. (Till now)

Ugh.  So how do future techs ever get chosen?

-jason





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