Latest Posts

Topic: ai doesn't make as many buildings as before

Tibor

Joined: 2009-03-23, 22:24
Posts: 1377
Ranking
One Elder of Players
Location: Slovakia
Posted at: 2016-04-22, 18:52

king_of_nowhere wrote:

Tibor wrote:

king_of_nowhere wrote:

the ai already expanded on all the space it had.

Oh, ok then. It has no place to expand but still not building economy? Did it have a lot of unfinished buildings or shortage of some materials?

I can't say that for sure because i didn't set the game on "all explored". I previously played the same map and found the same behavior, but I just assumed it to be an isolated case at the time. But in this case, I can only see that the number of buildings of the AI reached a peak 6 hours ago, then it decreased; while land size kept growing up to 4 hours ago. My scouts can see several patches of unused terrain, and though the ai has many buildings (some 260) I know more could be made with that land. The previous time when I played the same map with all the map explored I could see clearly that the AI only used maybe one third of its terrain. That time it was playing barbarians, this time empire, so it's not strictly tribe-related.

Just send me savegame next time, it is hard to say from description only


Top Quote
GunChleoc
Avatar
Joined: 2013-10-07, 14:56
Posts: 3324
Ranking
One Elder of Players
Location: RenderedRect
Posted at: 2016-04-23, 09:40

Tibor wrote:

kaputtnik wrote:

Tibor wrote: so it seems there is constant kInvalidWare = 254 and it is returned when ware is invalid for tribe as well as when default target is not set in init.lua ....

This was introduced with bug: Buildings produce more than set in "configure economy". If we set "default_target_quantity" to zero, the icons in configure economy menu appears again...

I already have a workaround, I will test it a bit and propose for merging afterwards...

EDIT:

The workaround is that when value will be kInvalidWare, it will be set to 5, I mean internally, for AI only

The old values ranged between 10 and 14, maybe set it a bit higher?

I think that in line 5823 in function review_wares_targets, you could also check to make sure that the tribe can use the ware: tribe_->has_ware(index).


Busy indexing nil values

Top Quote
king_of_nowhere
Avatar
Topic Opener
Joined: 2014-09-15, 17:35
Posts: 1668
Ranking
One Elder of Players
Posted at: 2016-04-23, 10:03

Tibor wrote:

Just send me savegame next time, it is hard to say from description only

pm me with a mail address to send it, and i will


Top Quote
GunChleoc
Avatar
Joined: 2013-10-07, 14:56
Posts: 3324
Ranking
One Elder of Players
Location: RenderedRect
Posted at: 2016-04-23, 11:17

You have a Launchpad account, so the easiest way is to attach it to a bug. Feel free to create new bugs for this kind of thing face-smile.png


Busy indexing nil values

Top Quote
Tibor

Joined: 2009-03-23, 22:24
Posts: 1377
Ranking
One Elder of Players
Location: Slovakia
Posted at: 2016-04-23, 19:45

GunChleoc wrote:

I think that in line 5823 in function review_wares_targets, you could also check to make sure that the tribe can use the ware: tribe_->has_ware(index).

Good points. I have modified the code that way. I will push new branch to launchpad soon...


Top Quote