• We created a new subforum for the Civ7 reviews, please check them here!

help adapting a script

globosud

Warlord
Joined
Jul 7, 2017
Messages
258
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)
 
Top Bottom