Specific Bug Reports

Great! Let me know how it goes ...

All went well. :) Although we haven't actually finished the game yet and will continue next weekend, overseas colonies have been created without any problem, so I am pretty sure MP is fixed.

In order to make this post something other than a 'nothing to report' post, I'll mention one quirk I noticed while playing a single player game with the latest build: the Barbarian AI sent a worker into my territory. I didn't wait long enough to watch where it was heading/what it was trying to connect, I simply thought thanks very much! So, I am not complaining. :)
 
I'm not exactly sure why but this line in CvPlayer.cpp is causing compilation to fail.

Commenting it out makes the thing compile just fine...

Code:
logBBAI("Player %d (%S) setTurnActive for turn %d", getID(), getCivilizationDescription(0), GC.getGameINLINE().getGameTurn() );

It's under CvPlayer::setTurnActive.
 
Did you add the two new BetterBTSAI files to your Makefile/project?

That line should read:

Code:
if( gPlayerLogLevel > 0 ) logBBAI("Player %d (%S) setTurnActive for turn %d", getID(), getCivilizationDescription(0), GC.getGameINLINE().getGameTurn() );

so please try that and let me know whether that fixes things for your setup.

FYI for you modders, if you want to compile with AI logging enabled, add the compiler option LOG_AI. In a makefile I think you'd add something like /DLOG_AI, look for something to mimic like /DDEBUG.

When LOG_AI is set, then a file called BBAI.log will appear in your My Games/BTS/Logs folder. The contents should be understandable ... it doesn't log every AI decision obviously, but city build decisions, some settler choices, trades, war, and other stuff are in there right now.
 
There's the problem then. In the source it looks like this:
Code:
logBBAI("Player %d (%S) setTurnActive for turn %d", getID(), getCivilizationDescription(0), GC.getGameINLINE().getGameTurn() );
			if( gPlayerLogLevel >= 2 )
			{
Those are the full lines.
 
Yeah, sorry I meant that the "if( gPlayerLogLevel > 0 )" should be added, I know it wasn't there. Does that solve your compilation problem?
EDIT...
I haven't got time to test the compiling at the moment. Will try tomorrow but I'm pretty sure it will work. All the other logging code worked just fine.
 
In CvUnitAI::AI_spreadReligion(), this condition:
if (bHasAnyHolyCity && !bHasHolyCity)
is nested within this condition:
if (bHasHolyCity)
so the code will never fire.
 
I'm not sure I agree it's unnecessary, at least in a rewritten form.

One can argue that if all your own cities have your state religion, yet you still have a missionary of that religion walking around for some reason, you might as well spread the religion to another civ for the diplomatic benefits that sharing state religions give, even if you don't own the state religion's holy city. Why not remove the "if (bHasHolyCity)" condition, and change the one at the end to "if (!bHasHolyCity)"?

Also I wonder about line 11630:
if (0 == (GET_PLAYER((PlayerTypes)iI).getNonStateReligionHappiness()))

Why should the guy spreading his religion care if that causes unhappiness in the target civ? That unhappiness simply is another reason for the target civ to switch state religions to the religion of the source civ.
 
3 possible bugs in BBAI 0.82

1) AI produce Archer in 1725 AD after researched feudalism many turns ago.

2) Apostolic Palace Election 35 turns after UN construction and regular UN election

3) in 1725 AD when I receive two city by cultural flipping, two warrior were spawned in this cities instead of two rifleman.

Sorry but I forget to save the game at these points.
 
1) and 3) look like possible bugs, but 2) most likely it isn't . AP has nil to do with UN and only obsoletes when the civ that controls it gets mass media , not when someone else gets it ;)
 
1) and 3) look like possible bugs, but 2) most likely it isn't . AP has nil to do with UN and only obsoletes when the civ that controls it gets mass media , not when someone else gets it ;)

About 2) I don't know this. Thanks for the info. Regarding 1) and 3) I'll try to play another game and try to save the game at bug point.
 
Something to look into: I once had the AI build as many missionaries as it could even though it had only one city - which was the holy city - and no open boarders with anyone, no other teammembers and thus not even one city to spread the religion to.
What made matters worse that time is that everyone else had at least 3 cities by then, opportunistic wonder build stonehenge plus 3 missionaries that were just staying in the city afterwards until he got open boarders with someone (took a while I think).
If not fixable, at least worth considering for centralized building imo.
 
Top Bottom