View Full Version : Python problems => Python solutions


Fabrysse
Nov 30, 2006, 02:30 AM
I open this new thread where we could list python problems and then explain the solutions we found...


Some python problems... :crazyeye:


Is there a python way to force civs to sign a permanent alliance ?
How could I set that a team knows all map (with cities) ? Exactly : I dynamically create a new civ at turn 'N', and I want it to acquire the same map than an other civ that knows all map... I have this new civ in the map file with no alive unit in game. When I set in map file reveal map for this team, it is automatically set to "0" by the game (because the player is dead, I suppose... Is there a way to put back this value to "1" when the new civ appears really in game ?

jdog5000
Nov 30, 2006, 10:48 PM
For permanent alliances, use the CyTeam addTeam function. Basically a permanent alliance puts the two civs on the same team.

Don't know a good way for the plots ... you could just loop over all plots in game and use CyPlot::setRevealed.

Fabrysse
Dec 01, 2006, 02:17 AM
Thanks, I'll try that.

Note : I used your DLL to change human player : it's great ! It works very very well. :goodjob: