[Freeciv-Dev] Re: (PR#3973) [PATCH] Patch which creates new "novice" ski
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
On Fri, 11 Apr 2003, sam+civ@xxxxxxxxxxxxxxxxxxxx wrote:
> This patch incorporates both Gregory's and Per's suggestions and
> feedback for a patch which gives the AI a tech penalty. In line
> with Greg's suggestions, the science penalty is level-dependent.
> Additionally, it is in a style similiar to the set_ai_level_directer
> function, and the penalty is in the pplayer->at struct.
>
> Additionally, this patch incorperates Per's suggestion to only have
> the science penalty apply for a new "novice" skill level (which also
> has a "fuzzy" of 400 as opposed to Easy's "fuzzy" of 300). The science
> penalty is 250%, which means it costs the AI 2.5 as many bulbs to
> get a given tech.
Looks very nice!
Few comments on the patch:
1. You should also give novice AI the handicaps of easy, otherwise it will
use diplomats agressively and cheat in setting rates. This is done in
handicap_of_skill_level
2(nitpick). In
int expand; /* percentage factor to value new cities */
+ int science_cost; /* Cost in bulbs to get new tech, relative
+ to non-AI players (100: Equal cost) */
please make sure the new comment is formatted like the old ones.
3. This
+ if (pplayer->ai.control && pplayer->ai.science_cost > 0 &&
+ pplayer->ai.science_cost != 100) {
+ float fcost, factor;
+ fcost = cost;
+ factor = pplayer->ai.science_cost;
+ fcost *= (factor / 100);
+ cost = fcost;
+ }
is unnecessary. Just do
if (pplayer->ai.control) {
cost = (cost * pplayer->ai.science_cost) /100;
}
4. To apply your patch to the development tree, we need a patch
against the current state of the code. Please see
http://www.freeciv.org/contribute.html
for details. You can of course keep a version of your patch applicable to
1.14 on your website, for those who don't want to download CVS version or
wait until 1.15.
5. Please try to send the patch as an attachment, rather then
incorporating it into the email body. Makes it easier to save it and try
it.
> I also have a version of this patch without the new "Novice" level
> that applies the 2.5x bulb cost to the "Easy" skill level.
I think "Novice" is good.
Unless there is vehement opposition to this patch, I will apply it once it
is made against CVS and I am reasonably sure it is bug-free.
G.
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Freeciv-Dev] Re: (PR#3973) [PATCH] Patch which creates new "novice" skill level,
Gregory Berkolaiko <=
|
|