Mercurian Gate & Capitals

Luckmann

Esusian Epicure
Joined
Sep 21, 2007
Messages
527
Location
The Towers of Amur.
I'm sure there's a reasonable explanation, but I found myself wondering, so I just have to ask; Why can't the Mercurian Gate be built in a capital? When playing as the Bannor, preparing to summon the Mercurians, I made sure to center a lot on my capital, wanting to build the Mercurian Gate there. When I finally had the opportunity, I had no idea why I couldn't build the gate. A little bit later I figure out that it can be the Palace interfering, so I move my Palace and SHAZAM, I can build the Mercurian Gate in my "prime" city.

All I'm wondering is why?
 
Probably has something to do with the fact that they take the city that builds the gate, and you can't gift your capital. If it was possible, I can see the possibility of "suicide by gatebuilding" if you only have one city and you build the gate.
 
I would guess that Kael doesn't think people would want to have Basium steal their capital city. You can't gift your capital though diplomacy, so maybe he thought it was inappropriate to be able to give it away this way.

It could also be that Kael simply did not want to let anyone to be able to build the gate before building a second city. If Basium used his spell to take your only city and the Require Complete Kills option was not on, then you would lose the game immediately before even being offered the chance to change. Of course, it would not be hard to instead block building the gate unless you have at least 2 cities.



(In my version, I remove this block, and also changed Basium's Convert City spell so that it can be cast in any city owned by any other member of the caster's team. It however lost its high AI weighting and the Allow AI tag, so if you don't change teams you'll probably want to gift them a city. I should probably make some exception to let an AI Basium get some cities if summoned by an AI too, but haven't figures out how I want to code it so as not to make the Mercurians eliminate their allies entirely.)
 
[...]

It could also be that Kael simply did not want to let anyone to be able to build the gate before building a second city. If Basium used his spell to take your only city and the Require Complete Kills option was not on, then you would lose the game immediately before even being offered the chance to change. Of course, it would not be hard to instead block building the gate unless you have at least 2 cities.

[...]
I have a feeling that this is it, because of the potential to kill yourself off before having a chance to change. But yes, I'd really prefer if it was changed to block the building of the gate unless you have at least two cities.

I think the odds of reaching Fanaticism without having at least a single city is so abysmal you'd probably not even have to note it in the Civilopedia. Thanks for the ideas, both of you. I just found it wierd and couldn't come up with a reasonable explanation on hand. :)
 
It may seem unlikely, but I've done it plenty of times. That is mostly when I'm trying to get my capital to be the holy city of every religion and then can't find much room to expand, but sometimes it is if I try playing with the a One City Challenge or No Settlers Game Options turned on.



Anyway, to allow it in the capital so long as you have another city that could become your civ's new capital, go to def cannotConstruct(self,argsList): in CvGameUtils.py and change this
Code:
		if eBuilding == gc.getInfoTypeForString('BUILDING_MERCURIAN_GATE'):
			if gc.getGame().isOption(GameOptionTypes.GAMEOPTION_NO_HYBOREM_OR_BASIUM):
				return True
			if pPlayer.getStateReligion() == gc.getInfoTypeForString('RELIGION_THE_ASHEN_VEIL'):
				return True
			if pCity.isCapital():
				return True
			if pPlayer.isHuman() == False:
				if pPlayer.getAlignment() == gc.getInfoTypeForString('ALIGNMENT_EVIL'):
					return True
to this
Code:
		if eBuilding == gc.getInfoTypeForString('BUILDING_MERCURIAN_GATE'):
			if gc.getGame().isOption(GameOptionTypes.GAMEOPTION_NO_HYBOREM_OR_BASIUM):
				return True
			if pPlayer.getStateReligion() == gc.getInfoTypeForString('RELIGION_THE_ASHEN_VEIL'):
				return True
			if pPlayer.getNumCities() < 2:
				return True
			if pPlayer.isHuman() == False:
				if pPlayer.getAlignment() == gc.getInfoTypeForString('ALIGNMENT_EVIL'):
					return True
 
To make that change, go to def cannotConstruct(self,argsList): in CvGameUtils.py and change this
Code:
		if eBuilding == gc.getInfoTypeForString('BUILDING_MERCURIAN_GATE'):
			if gc.getGame().isOption(GameOptionTypes.GAMEOPTION_NO_HYBOREM_OR_BASIUM):
				return True
			if pPlayer.getStateReligion() == gc.getInfoTypeForString('RELIGION_THE_ASHEN_VEIL'):
				return True
			if pCity.isCapital():
				return True
			if pPlayer.isHuman() == False:
				if pPlayer.getAlignment() == gc.getInfoTypeForString('ALIGNMENT_EVIL'):
					return True
to this
Code:
		if eBuilding == gc.getInfoTypeForString('BUILDING_MERCURIAN_GATE'):
			if gc.getGame().isOption(GameOptionTypes.GAMEOPTION_NO_HYBOREM_OR_BASIUM):
				return True
			if pPlayer.getStateReligion() == gc.getInfoTypeForString('RELIGION_THE_ASHEN_VEIL'):
				return True
			if pPlayer.getNumCities() < 2:
				return True
			if pPlayer.isHuman() == False:
				if pPlayer.getAlignment() == gc.getInfoTypeForString('ALIGNMENT_EVIL'):
					return True

You amaze me.
 
Actually, now that I think it it, it might be better just remove the if pCity.isCapital(): block in CvGameUtils.py and instead add a block in Basium's spell's python prereq. That way, you could still summon Basium in a One City Challenge or No Settlers game, but he would have to use his starting settler to found his own city rather than taking yours.


If you only want to allow the player to bring in Basium when those game options are on, you'd want to open CvSpellInterface.py and change this

Code:
def reqConvertCityBasium(caster):
	pPlot = caster.plot()
	pCity = pPlot.getPlotCity()
	if pCity.getOwner() == caster.getOwner():
		return False
	return True
to this
Code:
def reqConvertCityBasium(caster):
	pPlot = caster.plot()
	pCity = pPlot.getPlotCity()
	if pCity.getOwner() == caster.getOwner():
		return False
	if pCity.isCapital():
		return False
	return True


If you want to let him take the capital if you chose to build it there, then you should instead change it to this
Code:
def reqConvertCityBasium(caster):
	pPlot = caster.plot()
	pCity = pPlot.getPlotCity()
	iPlayer = pCity.getOwner()
	pPlayer = gc.getPlayer(iPlayer)
	if iPlayer == caster.getOwner():
		return False
	if pPlayer.getNumCities() < 2:
		return False
	return True
 
Wow. Thanks again, MC. You continue to amaze in both helpfulness and resourcefulness again and again.
 
Top Bottom