The AI autoplay needs some fixing.

NotSoGood

Emperor
Joined
Jan 25, 2009
Messages
1,077
Location
Finland
I usually use the AI autoplay to check if there's any bugs in my mod. (Great feature :goodjob:) But I have noticed that when the mod crashes and the AI autoplay is running, and you load the auto save and press enter, the AI autoplay continues running to the crash you were supposed to debug. :mad: Could the AI autoplay be reset when saving in the save file? I don't know how the AI autoplay works but I don't like it running after saving and loading. This would make my debugging a lot easier.
 
You could just edit the variables to not save. In CvPlayer, just comment out the read/write lines for m_bDisableHuman. That should make it reset when you load a save.
 
I can't find m_bDisableHuman from CvPlayer's read/write functions. :confused:

Oh yeah, that's only for RevDCM. AI AutoPlay shouldn't be being continued after loading a save then. Better AI doesn't add any new data to saves, so it can't happen.
 
Better AI doesn't add any new data to saves, so it can't happen.

Technically not true since version 0.80 broke save file compatibility, though as far as I know that was only for the speed enhancement stuff.
 
Technically not true since version 0.80 broke save file compatibility, though as far as I know that was only for the speed enhancement stuff.

Yeah, but I believe he used the trick with the uIFlag's to keep compatibility between BTS and .80+. I looked at the Better AI source code and it doesn't save the m_bDisabledHuman flag like RevDCM does.
 
If you reload the save, and then press CTRL-ALT-X, and then cancel, and then press enter, doesn't that cancel the autoplay?
 
One trick that I use is reloading the last save, opening up the Python window and then setting the AIAutoPlay to 1 turn. It's kind of klutzy because the python window doesn't respond quickly while the AI is playing, but if you can get in the command change before it hits the crash point, then it will stop at the end of the current turn.
 
Back
Top Bottom