1880749 Unhappy by defying UN resolutions

Cybah

Emperor
Joined
Jun 22, 2007
Messages
1,481
I guess the problem is somewhere in SDK, not python. Observed since BBAI 0.90x (developer versions, the actual 0.90r seems to be affected too, but I don't know if BBAI is the reason - if yes, this might also be a problem in 0.84 - already reported).

Has anyone else observed this? Which SDK file might be affected?

attachment.php



this cannot be the reason or?

PHP:
	def onCityDoTurn(self, argsList):
		'City Production'
		pCity = argsList[0]
		iPlayer = argsList[1]

# no anger defying UN resolutions start #
		iGovernmentCivicOption = CvUtil.findInfoTypeNum(gc.getCivicOptionInfo,gc.getNumCivicOptionInfos(),'CIVICOPTION_GOVERNMENT')
		iPoliceState = CvUtil.findInfoTypeNum(gc.getCivicInfo,gc.getNumCivicInfos(),'CIVIC_POLICE_STATE')
		pPlayer = gc.getPlayer(iPlayer)
		iGovernmentCivic = pPlayer.getCivics(iGovernmentCivicOption)

		if (iGovernmentCivic == iPoliceState):
			pCity.changeDefyResolutionAngerTimer(pCity.getDefyResolutionAngerTimer())
# no anger defying UN resolutions end #

		CvAdvisorUtils.cityAdvise(pCity, iPlayer)
 
Just a guess as I haven't looked at the code yet, but maybe you want to put a negative (-) in there so that it subtracts the current timer from itself resulting in zero which is what you want according to the comma:

Code:
pCity.changeDefyResolutionAngerTimer([B][COLOR="Red"]-[/COLOR][/B]pCity.getDefyResolutionAngerTimer())
 
Tyvm. I have copied this code from somebody else without looking at the code. Don't know anymore who was it, but he/she will have the error too then.
 
Back
Top Bottom