Gaelan Again

orgonebox

Squidtastic
Joined
Feb 10, 2006
Messages
158
Playing w/ 0.32c ->

Circle of Gaelan isn't founding. I've played through several games and usually am the first to sorcery, if not the first to have KOTE and a mage guild. The event triggers xml looks okay for all that I know. Has anyone had Gaelan trigger with the sorcery tech requirement? I haven't even seen the "willful apprentice" event occur for either me or the ai.
 
Still seems to be dependent on the event-system and thus random (also hadn't it appear already twice).

Shouldnt they happen upon the first civ reaching Sorcery for that civ?
 
On CotD: Interestingly i had that one appear in my first game of 0.32 with Cardith as a neighbor. So maybe my luck on events just went there. :p And my Svartalfar people went really nuts when some of them started to follow the cult...

Now that you say ist: Perhaps there is something wrong with Gaelan + the Catacomb Libralus? Most of the time i built it...

Perhaps its also because the constellations are currently cluttering the events table.
 
Circle of Gaelan does not appear on the outside but only when you look in the city, also it can trigger multiple times a game as a different civ
 
Not sure what you mean, civ king. The event should pop up for you or get mentioned in the event log. In my case, I've been checking all the other civs in the world builder, and most of them don't even have KOTE, much less a mage guild.

I am beginning to think it's a problem with the Catacombs Libralus. I think it was Xienwolf who mentioned changing the Circle spread code so that it recognizes the "bonus" mage guild from the CL instead of only spreading to legitimately built mgs. Previously, when you had to edit the XML so that the 2nd and 3rd Gaelan events were weighted to -1 (which is also the current fix except for the recent sorcery req), building the CL was the sure-fire way to get the event to trigger. However, it might be that the code keeps checking in random cities - not yr capitol, where you're likely to have built the CL - and only finds bunk, imaginary mage guilds.

I'm going to try two things: the first will be to play as Dain the Caswallam (whatever a caswallam is) and build lots of mgs, but NOT the CL. If that doesn't work (and if Tebryn isn't in-game and beelining to Sorcery at the expense of everything else), I'll go into the xml and change the weight of the first event to something ridiculously high.

Will report back later.
 
A Caswallawn is a sort of arch-mage. It's a title indicating that you're the greatest wizard among the Amurites.
Just thought I'd drop that in. It's probably slightly incorrect somehow.
 
A Caswallawn is a sort of arch-mage. It's a title indicating that you're the greatest wizard among the Amurites.
Just thought I'd drop that in. It's probably slightly incorrect somehow.
If I remember correctly, he earned the title by being the first and only to survive the Cave of Ancestors in this age. Not completely sure, though.
EDIT: In either case, it basically means he's badass.
 
In the days of Patria, it was a rank achieved by passing all The Tests. Some of these Tests took place in the the Cave of the Ancestors, but I'm don't know if the last one did. The Final Test was Mortal Combat against the old Cassawallen. Very few mages or Archmages ever dared to go this far.


Dain actually didn't go though this deadly test; since there hadn't been a Cassawallen since before the Age of Ice, there was no one to fight. Presumably, he can still be challenged for this position and would have to defend his title.

The Cassawallen however could never refuse a challenge, for any reason. Cassawallens could be male or female. Either way, they were expected to breed often in order pass on their magical genes and make the next generation of mages stronger. In the case of a male, this means having several dozen wives and concubines. At least one female Cassawallen fought while 9 months pregnant, and gave birth during the battle.
 
I had the circle of gaelan event happen TWICE!!!! as the sheim and then when i switched to hyborem, AGAIN it happened it was awesome to have Gaelan even after i switched civs
 
i thought it linked somehow to alchemist labs building? i am wrong or CoG happens in cities with AL building built??
 
Either way, they were expected to breed often in order pass on their magical genes and make the next generation of mages stronger. In the case of a male, this means having several dozen wives and concubines.

So it should be Dain the Pimp, the polygamist, or the master of the getting-laid gimmick? There should be an aggressive/arcane leader of the Amurites called Murph the Curmudgeon, or an Industrious/Arcane leader called Spanky the Whipper.

Anyway, not making much progress on finding out exactly how CL affects the CoG. I keep getting remarkably crappy starts or bad combinations of events. The RNG deities are not with me on this one. Gaelan isn't much more than a novelty for the Amurites, but for the elves, a sure Gaelan strategy could make a fifty-turn difference in a war schedule, hence my persistance.
 
Okay, I figured it out.

Building the CL or not has no bearing on the CoG. Basically, like the second and third Gaelan events, the first event is now getting lost in the random event chances. I tried increasing the weight of the event to no avail, so I went ahead and changed the iweight tag to -1. This triggers the Gaelan events as soon as you discover sorcery. Obviously, the CoG awards cities that have real mage guilds as opposed to not.

This changes Gaelan to more of a reward for being the first to sorcery, kind of like the Guild of Hammers is a reward for the first to engineering. Came in handy in a recent elfwar when Decius of the Calabim decided to come stomping down with ridiculous numbers of bloodpets. A little maelstrom and his stacks were pudding.

Xienwolf, if you read this thread, will you please post the edit on the spread of CoG w/r/t the getnumreal vs getnum, or whatever the command is?
 
In CvEventManager.py
Code:
	def onCorporationFounded(self, argsList):
		'Corporation Founded'
		iCorporation, iFounder = argsList
		player = PyPlayer(iFounder)
		pPlayer = gc.getPlayer(iFounder)

		iCircle = gc.getInfoTypeForString('CORPORATION_CIRCLE_OF_GAELAN')
		iMageGuild = gc.getInfoTypeForString('BUILDING_MAGE_GUILD')
		if iCorporation == iCircle:
			for i in range(pPlayer.getNumCities()):
				pCity = pPlayer.getCity(i)
[COLOR="Lime"]#Gaelan Catacomb Add Begin
[COLOR="Red"]#				if pCity.getNumRealBuilding(iMageGuild) > 0:[/COLOR]
				if pCity.getNumBuilding(iMageGuild) > 0:
#Gaelan Catacomb Add End[/COLOR]
					pCity.setHasCorporation(iCircle, True, True, True)

		if (not self.__LOG_RELIGION):
			return
		CvUtil.pyPrint('Player %d Civilization %s has founded %s'
			%(iFounder, player.getCivilizationName(), gc.getCorporationInfo(iCorporation).getDescription()))

And

Code:
	def onCityDoTurn(self, argsList):
		'City Production'
		pCity = argsList[0]
		iPlayer = argsList[1]
		pPlot = pCity.plot()
		pPlayer = gc.getPlayer(pCity.getOwner())

		if pCity.getNumRealBuilding(gc.getInfoTypeForString('BUILDING_CITADEL_OF_LIGHT')) > 0:
			iX = pCity.getX()
			iY = pCity.getY()
			eTeam = gc.getTeam(pPlayer.getTeam())
			iBestValue = 0
			pBestPlot = -1
			for iiX in range(iX-2, iX+3, 1):
				for iiY in range(iY-2, iY+3, 1):
					pPlot2 = CyMap().plot(iiX,iiY)
					bEnemy = false
					bNeutral = false
					iValue = 0
					if pPlot2.isVisibleEnemyUnit(iPlayer):
						for i in range(pPlot2.getNumUnits()):
							pUnit = pPlot2.getUnit(i)
							if eTeam.isAtWar(pUnit.getTeam()):
								iValue += 5 * pUnit.baseCombatStr()
							else:
								bNeutral = true
						if (iValue > iBestValue and bNeutral == false):
							iBestValue = iValue
							pBestPlot = pPlot2
			if (pBestPlot != -1 and pPlot.getNumUnits() != 0):
				caster = -1
				for i in range(pPlot.getNumUnits()):
					pUnit = pPlot.getUnit(i)
					if (caster == -1 or pUnit.getLevel() > caster.getLevel()):
						caster = pUnit
				for i in range(pBestPlot.getNumUnits()):
					pUnit = pBestPlot.getUnit(i)
					pUnit.doDamage(10, 30, caster, gc.getInfoTypeForString('DAMAGE_FIRE'), true)
				if (pPlot.getFeatureType() == gc.getInfoTypeForString('FEATURE_FOREST') or pPlot.getFeatureType() == gc.getInfoTypeForString('FEATURE_JUNGLE')):
					if CyGame().getSorenRandNum(100, "Flames Spread") <= gc.getDefineINT('FLAMES_SPREAD_CHANCE'):
						pPlot.setImprovementType(gc.getInfoTypeForString('IMPROVEMENT_SMOKE'))
				CyEngine().triggerEffect(gc.getInfoTypeForString('EFFECT_PILLAR_OF_FIRE'),pBestPlot.getPoint())
[COLOR="Lime"]#Gaelan Catacomb Add Begin
		if CyGame().isCorporationFounded(gc.getInfoTypeForString('CORPORATION_CIRCLE_OF_GAELAN')):
			if CyGame().getHeadquarters(gc.getInfoTypeForString('CORPORATION_CIRCLE_OF_GAELAN')).getOwner() == pCity.getOwner():
				if pCity.getNumBuilding(gc.getInfoTypeForString('BUILDING_MAGE_GUILD')) > 0:
					if pCity.isHasCorporation(gc.getInfoTypeForString('CORPORATION_CIRCLE_OF_GAELAN')) == False:
						pCity.setHasCorporation(gc.getInfoTypeForString('CORPORATION_CIRCLE_OF_GAELAN'), True, True, True)
#Gaelan Catacomb Add End[/color]
		if pCity.isHasCorporation(gc.getInfoTypeForString('CORPORATION_BROTHERHOOD_OF_WARDENS')):
			if CyGame().getSorenRandNum(100, "Brotherhood of Wardens") <= 50:
				bAlert = False
				iX = pCity.getX()
				iY = pCity.getY()



Add the bits in Lime, and don't forget that you are replacing the line in Red

In that last bit, it might make it a little faster if you swap the IF (has Mage Guild) and the IF (Already has CoG)
 
Xienwolf I'm trying to understand python better - I know that getNumRealBuilding() is bts whereas getNumBuilding() is vanilla, but my question is why do you need to use the getNumBuilding() instead of the getNumRealBuilding () for it to work?
 
I think that getNumRealBuilding() returns the number of "real" buildings, meaning those you actually built. This would exclude the free buildings from wonders like the Catacomb Liberalus.
 
Top Bottom