jojoweb
Chimpa-Z
Very good idea, you're a boss ^_^ (python is so hard !). I will use it for my mod.
bye
bye
N3pomuk said:good idea, but is ther a cap to the max that they can get? after all training can only do so much.
Houman said:Hello Roger,
I really like your idea and would like to implement it into my mod. The code is still quite a lot mentioning the drydock even though you have changed the traning to Harbor instead of Drydock. The variables and some messages etc are still mentioning drydock.
It is a bit confusing, since I don't understand the whole code.
Thanks
Houman
if (pPlayer.getStateReligionKey() == "TXT_KEY_RELIGION_VAALKAZISM"):
barracksChance = barracksChance -3
harborChance = harborChance -3
barracksMaxExp = barracksMaxExp +3
harborMaxExp = harborMaxExp +3
civGovernment = pPlayer.getCivics(0)
if ( civGovernment == gc.getInfoTypeForString('CIVIC_POLICE_STATE')):
barracksChance = barracksChance -1
harborChance = harborChance -1
civLegal = pPlayer.getCivics(1)
if ( civLegal == gc.getInfoTypeForString('CIVIC_NATIONHOOD')):
barracksChance = barracksChance -1
harborChance = harborChance -1
if ( civLegal == gc.getInfoTypeForString('CIVIC_VASSALAGE')):
barracksChance = barracksChance -1
harborChance = harborChance -1
civReligion = pPlayer.getCivics(4)
if ( civLegal == gc.getInfoTypeForString('CIVIC_PACIFISM')):
barracksChance = barracksChance +4
harborChance = harborChance +4
if (barracksChance < 1):
barracksChance = 1
if (barracksMaxExp < 1):
barracksMaxExp = 1
if (harborChance < 1):
harborChance = 1
if (harborMaxExp < 1):
harborMaxExp = 1
if (pPlayer.getCivilizationDescriptionKey() == "TXT_KEY_CIV_JAPAN_DESC"):
barracksChance = barracksChance -1
harborChance = harborChance -2
barracksMaxExp = barracksMaxExp +1
harborMaxExp = harborMaxExp +2
if (pPlayer.hasTrait(gc.getInfoTypeForString("TRAIT_AGGRESSIVE"))):
barracksChance = barracksChance -2
harborChance = harborChance -2
barracksMaxExp = barracksMaxExp +2
harborMaxExp = harborMaxExp +2
Fachy said:I just love this mod, but I couldn't merge it with mine! Could you point out the exact changes please so we could all enjoy fusing it into our composite mods?![]()
Fachy said:I have no "onBeginPlayerTurn" line in my CvCustomEventManager.py!!
Also, my CvCustomEventManager file is only 6 kb, while yours is 10 kb. Does this have to do anything with me not being able to work it out or find the BeginPlayer thingy? Excuse me but I just began teaching myself python yesterday to merge mods![]()
Fachy said:I'm not sure what you mean.. I'm totally programming illetrate! I think you want me to copy this paragraph:
def onBeginPlayerTurn(self, argsList):
'Called at the beginning of a players turn'
self.parent.onBeginPlayerTurn(self, argsList);
Into my file right?
Fachy said:Roger I did that but it's still giving me errors at the game startup
My CvCustomEventManager.py file: http://www.savefile.com/files/8651175