• Our friends from AlphaCentauri2.info are in need of technical assistance. If you have experience with the LAMP stack and some hours to spare, please help them out and post here.

help adapting a script

globosud

Warlord
Joined
Jul 7, 2017
Messages
286
I would need to modify this script, making sure that the attitude changes, not for a different state religion, but only if one of the two players has a specific civic, and player 2 has a state religion. thanks for those who help me
this is script as it is now

if iBuildingType == gc.getInfoTypeForString("BUILDING_XX_XX"):
pPlayer = gc.getPlayer(pCity.plot().getOwner())
iPlayer = pPlayer.getID()
for iLoopPlayer in range(gc.getMAX_CIV_PLAYERS()):
loopPlayer = gc.getPlayer(iLoopPlayer)
if loopPlayer.isAlive() and loopPlayer.getStateReligion() == pPlayer.getStateReligion():
loopPlayer.AI_changeAttitudeExtra(iPlayer, +3)
print "Calling AI_changeAttitudeExtra"
pPlayer.AI_changeAttitudeExtra(iLoopPlayer, +3)
if loopPlayer.isAlive() and loopPlayer.getStateReligion() != pPlayer.getStateReligion():
loopPlayer.AI_changeAttitudeExtra(iPlayer, -3)
pPlayer.AI_changeAttitudeExtra(iLoopPlayer, -3)
 
Back
Top Bottom