You need to do both of these things. Doing only one will help a little. Doing both eliminates 95% of the lag.
DarthMod relies on startpos scripting to enhance AI. For the Ottomans, this can cause logjams as the AI processes the complex geopolitics of the Balkans and Middle East. empire total war darthmod ottoman turn lag fix
Method: The empire.lua Edit
This method forces the game to skip specific non-essential script checks during the AI turn. You need to do both of these things
scripting.lua or empire.lua (depending on the specific DM version).scripting_backup.lua. Store it somewhere safe.ottoman or generic IO events.Tick function. You can safely comment out "flavor" events for the first 20 turns to speed up the early game.
If you don't want to use sub-mods, you must perform surgery on your save file or the master startpos. This is the root fix. Look for a file named scripting
The Theory: The lag is caused by the Ottoman AI trying to build too many units in one province. Specifically, the "Istanbul" region has a governor's building that allows 6 recruitment slots. The AI queues 20 units, runs out of money, gets stuck in a loop.
The Fix (Using ESF Editor):
Why this works: A bankrupt AI cannot queue units. With no units to pathfind, the turn cycles in seconds. The Ottomans will recover in 10 turns, but by then, you’ve usually conquered them.