Snark
01-30-2003, 10:11
CTD-Bug identified, Avoidance possible
I could identify the problem with my ctd and it is definitely a game bug, but it can be avoided.
I was able to track the problem, to everyone whos interested, here's the long story, those who're only interested in the conclusion may read just the last lines http://www.totalwar.org/forum/non-cgi/emoticons/wink.gif
Well, the problem was the following:
I was playing Almohads, starting early and was in the year 1289, having conquered near all of Europe. Every time I tried end of the year, the game crashed to Desktop. I installed it on my Windows 2 K (the game normally running on 98SE) and the same happened, despite different driver-versions and OS.
I then wrote a message here and got the tip to clear all my building and training queues.
Now, something really interesting happened. I was stepping through my provinces, deleting everything from the building and training queue. When I came to castilia I tried to access the training queue and the game CTDed. Hmmmm Very strange. I tried it again, same result. I couldn't even open the training queue window without crashing the game.
I loaded my savegame from the year 1288 and tried to access the queue, which worked. However, when I tried to drop the Ghulam Bodyguard unit which was the only unit in the Queue, the game CTDed. Loading again, opening the queue, right clicking the unit, I got information shown for the unit. It was Sultan Khalil the first, with 0 men.
Hmmmm. Well, I admit at first I thought the problem was, that I was trying to train my leader and that this didn't work somehow. Then suddenly it dawned on me, that my leaders are called 'Khaliff', not 'Sultan'. How very, very strange Why am I training enemy units ?
I then loaded the game from 1287 and everything became clear.
I had placed my Prince Mohammed II in the training queue in 1287 and it was the only unit n the queue. However, during end of the year, my Khaliff died and Mohammed II became the new Khaliff. He was therefore removed from the training queue and put into a province as the new Khaliff. It seems as if the training queue did not really work from that point on, pointing to more or less random unit data. Probably the game tried to remove the unit twice from the queue, once because he became Khaliff and was placed in a province and once because the training ended. So the queue ended up outside its valid area, because of decrementing twice with only one unit in the queue, pointing to some other factions units.
So what happened was that due to the double removal from the queue in 1288 the game had invalid data in the training queue, which was the reason why I couldn't drop the unit from the queue. And why it showed unit data from an enemy unit in my training queue. But wait, why didn't the game crash when I did end of the year in 1288, the year this happened, but only the year after ?
Thats easy. I was running out of funds in 1288. Because of this, the unit wasn't trained and removed from the queue, maybe the training queue data for Castilia wasn't even accessed by the game. But in 1289 I had funds and the game probably tried to remove the (now, after 2 turns maybe even no longer existing) random unit from the training queue, resulting in the crash.
So, to the conclusion: If you're training a heir in a province and your king/sultan/Khaliff/whatever dies and the heir unit becomes the new leader, this may crash your game, even years later in unlucky circumstances. This is not neccessarily fatal, I can solve it by myself by loading a game 2 turns earlier, but well, you may have to fight battles again. In very unlucky circumstances you may loose more turns, before you notice the problem.
How to avoid this problem: Be aware that it can happen and don't train heirs, when you plan to use your Leader in battle. If you're training heirs check immediately at the next turn if they are really removed from the training queue.
One last word: This description might be a more detailled description of the bug, for which someone (Storm?) gave me a tip in another thread. The tip was to clear the building queue and training queue, to stop the game from CTDing. It may well be the same error, because clearing the heir from the training queue definitely helped. This would be nice, because the solution to only remove the heir from the training queue is clearly preferrable to having to clear everything and abandon the construction of buildings which might well waste 19 years of time.... So if you encounter a CTD in the campaign, check your heirs http://www.totalwar.org/forum/non-cgi/emoticons/wink.gif
Well, hope it helped and the description while this bug isn't prone to happen too often, I hope it will be fixed in the next patch.
I could identify the problem with my ctd and it is definitely a game bug, but it can be avoided.
I was able to track the problem, to everyone whos interested, here's the long story, those who're only interested in the conclusion may read just the last lines http://www.totalwar.org/forum/non-cgi/emoticons/wink.gif
Well, the problem was the following:
I was playing Almohads, starting early and was in the year 1289, having conquered near all of Europe. Every time I tried end of the year, the game crashed to Desktop. I installed it on my Windows 2 K (the game normally running on 98SE) and the same happened, despite different driver-versions and OS.
I then wrote a message here and got the tip to clear all my building and training queues.
Now, something really interesting happened. I was stepping through my provinces, deleting everything from the building and training queue. When I came to castilia I tried to access the training queue and the game CTDed. Hmmmm Very strange. I tried it again, same result. I couldn't even open the training queue window without crashing the game.
I loaded my savegame from the year 1288 and tried to access the queue, which worked. However, when I tried to drop the Ghulam Bodyguard unit which was the only unit in the Queue, the game CTDed. Loading again, opening the queue, right clicking the unit, I got information shown for the unit. It was Sultan Khalil the first, with 0 men.
Hmmmm. Well, I admit at first I thought the problem was, that I was trying to train my leader and that this didn't work somehow. Then suddenly it dawned on me, that my leaders are called 'Khaliff', not 'Sultan'. How very, very strange Why am I training enemy units ?
I then loaded the game from 1287 and everything became clear.
I had placed my Prince Mohammed II in the training queue in 1287 and it was the only unit n the queue. However, during end of the year, my Khaliff died and Mohammed II became the new Khaliff. He was therefore removed from the training queue and put into a province as the new Khaliff. It seems as if the training queue did not really work from that point on, pointing to more or less random unit data. Probably the game tried to remove the unit twice from the queue, once because he became Khaliff and was placed in a province and once because the training ended. So the queue ended up outside its valid area, because of decrementing twice with only one unit in the queue, pointing to some other factions units.
So what happened was that due to the double removal from the queue in 1288 the game had invalid data in the training queue, which was the reason why I couldn't drop the unit from the queue. And why it showed unit data from an enemy unit in my training queue. But wait, why didn't the game crash when I did end of the year in 1288, the year this happened, but only the year after ?
Thats easy. I was running out of funds in 1288. Because of this, the unit wasn't trained and removed from the queue, maybe the training queue data for Castilia wasn't even accessed by the game. But in 1289 I had funds and the game probably tried to remove the (now, after 2 turns maybe even no longer existing) random unit from the training queue, resulting in the crash.
So, to the conclusion: If you're training a heir in a province and your king/sultan/Khaliff/whatever dies and the heir unit becomes the new leader, this may crash your game, even years later in unlucky circumstances. This is not neccessarily fatal, I can solve it by myself by loading a game 2 turns earlier, but well, you may have to fight battles again. In very unlucky circumstances you may loose more turns, before you notice the problem.
How to avoid this problem: Be aware that it can happen and don't train heirs, when you plan to use your Leader in battle. If you're training heirs check immediately at the next turn if they are really removed from the training queue.
One last word: This description might be a more detailled description of the bug, for which someone (Storm?) gave me a tip in another thread. The tip was to clear the building queue and training queue, to stop the game from CTDing. It may well be the same error, because clearing the heir from the training queue definitely helped. This would be nice, because the solution to only remove the heir from the training queue is clearly preferrable to having to clear everything and abandon the construction of buildings which might well waste 19 years of time.... So if you encounter a CTD in the campaign, check your heirs http://www.totalwar.org/forum/non-cgi/emoticons/wink.gif
Well, hope it helped and the description while this bug isn't prone to happen too often, I hope it will be fixed in the next patch.