Complete.Org: Mailing Lists: Archives: freeciv-dev: August 2005:
[Freeciv-Dev] (PR#13683) Reducing the upgrade cost
Home

[Freeciv-Dev] (PR#13683) Reducing the upgrade cost

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: sayenko@xxxxxxxxx
Subject: [Freeciv-Dev] (PR#13683) Reducing the upgrade cost
From: "Guest" <rt-guest@xxxxxxxxxxx>
Date: Tue, 16 Aug 2005 08:50:18 -0700
Reply-to: bugs@xxxxxxxxxxx

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

> [per - Втр. Авг. 16 15:26:04 2005]:
> 
> On Tue, 16 Aug 2005, Alexander Sayenko wrote:
> > This is a new version of the patch that reduces the upgrade cost of
> units.
> 
> I dislike automatic bonuses from researching techs (that you reseach
> anyway - which is most techs). Unless they are put on branches of the
> tech
> tree that is infrequently visited, and therefore increases the number
> of
> viable options while playing, I see no point in them.

Well, the point is that there are many people who want the upgrade cost 
to become smaller and there are many ways to implement it. Besides, 
there are technologies that reduce the loss probability of a trieme. 
Why cannot we have the same kind of technologies for the upgrade price ?

> 
> Leonardo is already very powerful. Making it more so is perhaps not
> the
> best idea.

That was an example, we can introduce another wonder or forget about 
this idea.

> 
> > The unit_upgrade_price () function uses the get_player_bonus()
> function
> > which means that attaching the "Upgrade_Bonus" effect to buildings
> will have
> > no effect. Ideally, the get_city_bonus () function should be used.
> However,
> > there is no way to get a pointer to a city from the
> unit_upgrade_price ()
> > function. As a result, changes in the interface are necessary.
> 
> Not really. Just pick it out from punit->tile->city, if you want the
> city
> it is in, or punit->homecity, if you want its home city.

The problem is that unit_upgrade_price() has neither a pointer to a 
city, nor to a unit. It has only has IDs of units. So, we have to make 
changes anyway.

I have looked at the code from which this function is called and have 
noticed that there are plenty of small problems. For instance, when you 
decide to upgrade all the units from the "Units report" dialog, the 
following message appears: Do you want to upgrade %d units for the 
price %d each ? See, we will have to CHANGE this text since the price 
of the unit will depend on a city it resides. There are plenty of cases 
like this. I am afraid that after I submit the patch you will tell me 
that it cannot be accepted due to the "conceptual changes of the 
game" :-)) And you will be right. Furthermore, we will have to make 
changes in UI of each client.

That is why reducing the upgrade cost by the means of technologies and 
wonders seems to be more feasible from the viewpoint of non-touching 
the UI.

I would like to discuss a little bit about this problem since I do not 
have a desire to write a patch knowing that there is a 100% probability 
that it will be discarded. At least, I have to know that I am working 
in the right direction.



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