I got this error:
Traceback (most recent call last):
File "BugGameUtils", line 342, in callHandler
File "BugGameUtils", line 297, in <lambda>
File "FinalFrontierGameUtils", line 845, in AI_unitUpdate
File "CvAI", line 2997, in doConstructionShipAI
File "CvAI", line 2884, in doStationConstructionAI
File "CvAI", line 2926, in canConstructStarbase
UnboundLocalError: local variable 'iX' referenced before assignment
The problem is that a civilization without a capital has a construction ship trying to build a starbase. I thought I had fixed this earlier but my fix doesn't work on larger maps.
New fix:
add
else:
iDistanceFromCapital = 1#Aradziem this disables optimization, so a few stranded construction ships on large maps may severely affect performance.
after line
if (pPlayer.getCapitalCity().plot()!=None):#Aradziem bugfix(looks like was always true)
iDistanceFromCapital = CyMap().calculatePathDistance(pPlayer.getCapitalCity().plot(), pLoopPlot)
(line 3200 in CvAI.py)
As said in the comment this may affect performance in some cases.