Hell Terrain in World Builder

srmacpherson

Chieftain
Joined
Jun 15, 2008
Messages
73
I'm not getting hell terrain features to work in the worldbuilder.

I've spent many evenings creating a large custom world to use with FFH2 and run into a problem.

I have what I refer to as the "Chaos Wastelands," which I have painted with the Hell-Terrain tiles and have included hell terrain features such as Nightmares, toads, crabgrass, dandelions or whatever those two Hell terrain goodies are. Regardless of what they are, they convert to their normal counterparts upon starting the game.

So in the worldbuilder, I plop down a toad, and when I begin the game, it is now a pig.
Quite frustrating when I'm going for a certain flavour.

In the game, Hell terrain arrives (I'm reading - it has never happened for me) when the infernal arrive. But shouldn't the hell terrain features be able to survive on hell terrain tiles regardless of whether or not the infernal are around?

How do I get the benefits of hell terrain features from the start of my scenario?
 
The Hell Terrain is made by having a high AC. Each plot has it's own AC, and when high enough it turns to hell terrain, along with it's features. If the AC is to low, all features are normal.

So in order to have an Armageddon Sceanario w/ features simply place a bunch of cities and destroy them in WB. Destroy the ruins so they can't be snctified. It's one point for every city. Also, Hyborem must be present for the tile's AC counters to be activated, so give one civ the Infernal Pact tech. (you can take it away later).
 
Tiles are updated each turn to turn to their hell counterparts and back based on the tile's plot counter. A value below 10 is normal terrain and resources, above 10 is the hell counterpart. A tile's plot counter goes up by 1 each turn it is adjacent to a tile with a counter of 10 or more and the AC and alignment restrictions are met.

Hell terrain "arrives with Hyborem" because Infernal territory is always set to have plot counters of 100. (Hell can also start when an Entropy Node flair turns its tile's plot counter to 100.)


The "No Hell Terrain" Game option (actually GAMEOPTION_NO_PLOT_COUNTER) doesn't disable hell terrain, it disables the checks that update terrains and resources based on the plot counter. If you turn this on, your hell resources and terrains will not revert. Hell terrain wil also not spread, and I think that Sanctify won't have any real effect.
 
Tiles are updated each turn to turn to their hell counterparts and back based on the tile's plot counter. A value below 10 is normal terrain and resources, above 10 is the hell counterpart. A tile's plot counter goes up by 1 each turn it is adjacent to a tile with a counter of 10 or more and the AC and alignment restrictions are met. .

So am I to understand that if I place Hell Terrain tiles at the onset, they will each have a starting AC value of 10? Or, because they are artificially placed there in the WB, will they act the same as the normal tileset with an AC of 0?

Because I playtested with a civ that begins in the hell terrain, and after 50 turns, there was still cotton, pigs and farms instead of their hell counterparts. So I'm thinking that without infernal or a collapsed node, the hell terrain is just cosmetic.



The "No Hell Terrain" Game option (actually GAMEOPTION_NO_PLOT_COUNTER) doesn't disable hell terrain, it disables the checks that update terrains and resources based on the plot counter. If you turn this on, your hell resources and terrains will not revert. Hell terrain wil also not spread, and I think that Sanctify won't have any real effect.


So with this disabled, Hell terrain and it's features will appear the same regardless of the AC gameplay mechanics? for example, if I place a broken lands tile featuring a toad on the map, when I play the scenario, it will be a broken lands tile with toads, instead of a broken lands tile with pigs. It just won't spread?
If so, its a viable option, but I enjoy the idea of the spreading hell terrain.
 
The Hell Terrain is made by having a high AC. Each plot has it's own AC, and when high enough it turns to hell terrain, along with it's features. If the AC is to low, all features are normal.

So in order to have an Armageddon Sceanario w/ features simply place a bunch of cities and destroy them in WB. Destroy the ruins so they can't be snctified. It's one point for every city. Also, Hyborem must be present for the tile's AC counters to be activated, so give one civ the Infernal Pact tech. (you can take it away later).

I'm assuming when you suggest to set up cities and destroy them, you're talking about playing the game and advancing a turn prior to their destruction?

1) Can the AC be easily altered prior to turn 1? I haven't reached the point of editing the text files yet, even for Vanilla Civ4.

2) Again, prior to turn 1, has anyone inserted the Hyborem as a civ without giving someone the infernal pact technology?

3) Has anyone tried giving a barbarian Infernal pact to introduce the Hyborem?
 
Or, because they are artificially placed there in the WB, will they act the same as the normal tileset with an AC of 0?

Yes, there is no way to alter the plot counter in Worldbuilder.
So with this disabled, Hell terrain and it's features will appear the same regardless of the AC gameplay mechanics? for example, if I place a broken lands tile featuring a toad on the map, when I play the scenario, it will be a broken lands tile with toads, instead of a broken lands tile with pigs. It just won't spread?

Yes. You could also place Hell resources on normal terrains if you like.


CvEventManager.py:
Code:
	def onBeginGameTurn(self, argsList):
		'Called at the beginning of the end of each turn'
.
.
.

		if CyGame().isOption(gc.getInfoTypeForString('GAMEOPTION_NO_PLOT_COUNTER')) == False:
			cf.doHellTerrain()



In CustomFunctions.py:
Code:
	def doHellTerrain(self):
		iAshenVeil = gc.getInfoTypeForString('RELIGION_THE_ASHEN_VEIL')
		iBurningSands = gc.getInfoTypeForString('TERRAIN_BURNING_SANDS')
		iBanana = gc.getInfoTypeForString('BONUS_BANANA')
		iCotton = gc.getInfoTypeForString('BONUS_COTTON')
		iCorn = gc.getInfoTypeForString('BONUS_CORN')
		iCow = gc.getInfoTypeForString('BONUS_COW')
		iEvil = gc.getInfoTypeForString('ALIGNMENT_EVIL')
		iFarm = gc.getInfoTypeForString('IMPROVEMENT_FARM')
		iFlames = gc.getInfoTypeForString('FEATURE_FLAMES')
		iFlamesSpreadChance = gc.getDefineINT('FLAMES_SPREAD_CHANCE')
		iGulagarm = gc.getInfoTypeForString('BONUS_GULAGARM')
		iHorse = gc.getInfoTypeForString('BONUS_HORSE')
		iInfernal = gc.getInfoTypeForString('CIVILIZATION_INFERNAL')
		iMarble = gc.getInfoTypeForString('BONUS_MARBLE')
		iNeutral = gc.getInfoTypeForString('ALIGNMENT_NEUTRAL')
		iNightmare = gc.getInfoTypeForString('BONUS_NIGHTMARE')
		iPig = gc.getInfoTypeForString('BONUS_PIG')
		iRazorweed = gc.getInfoTypeForString('BONUS_RAZORWEED')
		iRice = gc.getInfoTypeForString('BONUS_RICE')
		iSheep = gc.getInfoTypeForString('BONUS_SHEEP')
		iSheutStone = gc.getInfoTypeForString('BONUS_SHEUT_STONE')
		iSilk = gc.getInfoTypeForString('BONUS_SILK')
		iSnakePillar = gc.getInfoTypeForString('IMPROVEMENT_SNAKE_PILLAR')
		iSugar = gc.getInfoTypeForString('BONUS_SUGAR')
		iToad = gc.getInfoTypeForString('BONUS_TOAD')
		iWheat = gc.getInfoTypeForString('BONUS_WHEAT')
		iCount = CyGame().getGlobalCounter()
		for i in range (CyMap().numPlots()):
			pPlot = CyMap().plotByIndex(i)
			iFeature = pPlot.getFeatureType()
			iTerrain = pPlot.getTerrainType()
			iBonus = pPlot.getBonusType(-1)
			iImprovement = pPlot.getImprovementType()
			bUntouched = true
			if pPlot.isOwned():
				pPlayer = gc.getPlayer(pPlot.getOwner())
				iAlignment = pPlayer.getAlignment()
				if pPlayer.getCivilizationType() == iInfernal:
					pPlot.changePlotCounter(100)
					bUntouched = false
				if (bUntouched and pPlayer.getStateReligion() == iAshenVeil or (iCount >= 50 and iAlignment == iEvil) or (iCount >= 75 and iAlignment == iNeutral)):
					iX = pPlot.getX()
					iY = pPlot.getY()
					for iiX in range(iX-1, iX+2, 1):
						for iiY in range(iY-1, iY+2, 1):
							pAdjacentPlot = CyMap().plot(iiX,iiY)
							if pAdjacentPlot.isNone() == False:
								if pAdjacentPlot.getPlotCounter() > 10:
									pPlot.changePlotCounter(1)
									bUntouched = false
			if (bUntouched and pPlot.isOwned() == false and iCount > 25):
				iX = pPlot.getX()
				iY = pPlot.getY()
				for iiX in range(iX-1, iX+2, 1):
					for iiY in range(iY-1, iY+2, 1):
						pAdjacentPlot = CyMap().plot(iiX,iiY)
						if pAdjacentPlot.isNone() == False:
							if pAdjacentPlot.getPlotCounter() > 10:
								pPlot.changePlotCounter(1)
								bUntouched = false
			iPlotCount = pPlot.getPlotCounter()
			if (bUntouched and iPlotCount > 0):
				pPlot.changePlotCounter(-1)
			if iPlotCount > 9:
				if (iBonus == iSheep or iBonus == iPig):
					pPlot.setBonusType(iToad)
				if (iBonus == iHorse or iBonus == iCow):
					pPlot.setBonusType(iNightmare)
				if (iBonus == iCotton or iBonus == iSilk):
					pPlot.setBonusType(iRazorweed)
				if (iBonus == iBanana or iBonus == iSugar):
					pPlot.setBonusType(iGulagarm)
				if (iBonus == iMarble):
					pPlot.setBonusType(iSheutStone)
				if (iBonus == iCorn or iBonus == iRice or iBonus == iWheat):
					pPlot.setBonusType(-1)
					pPlot.setImprovementType(iSnakePillar)
			if iPlotCount < 10:
				if iBonus == iToad:
					if CyGame().getSorenRandNum(100, "Hell Convert") < 50:
						pPlot.setBonusType(iSheep)
					else:
						pPlot.setBonusType(iPig)
				if iBonus == iNightmare:
					if CyGame().getSorenRandNum(100, "Hell Convert") < 50:
						pPlot.setBonusType(iHorse)
					else:
						pPlot.setBonusType(iCow)
				if iBonus == iRazorweed:
					if CyGame().getSorenRandNum(100, "Hell Convert") < 50:
						pPlot.setBonusType(iCotton)
					else:
						pPlot.setBonusType(iSilk)
				if iBonus == iGulagarm:
					if CyGame().getSorenRandNum(100, "Hell Convert") < 50:
						pPlot.setBonusType(iBanana)
					else:
						pPlot.setBonusType(iSugar)
				if (iBonus == iSheutStone):
					pPlot.setBonusType(iMarble)
				if iImprovement == iSnakePillar:
					pPlot.setImprovementType(iFarm)
					iCount = CyGame().getSorenRandNum(100, "Hell Convert")
					if  iCount < 33:
						pPlot.setBonusType(iCorn)
					else:
						if iCount < 66:
							pPlot.setBonusType(iRice)
						else:
							pPlot.setBonusType(iWheat)
			if iTerrain == iBurningSands:
				if pPlot.isCity() == False:
					if pPlot.isPeak() == False:
						if CyGame().getSorenRandNum(100, "Flames") <= iFlamesSpreadChance:
							pPlot.setFeatureType(iFlames, 0)
 
I'm assuming when you suggest to set up cities and destroy them, you're talking about playing the game and advancing a turn prior to their destruction?

1) Can the AC be easily altered prior to turn 1? I haven't reached the point of editing the text files yet, even for Vanilla Civ4.

It would take a python routine to do that. Which would mean you would need to include a modmod, not just a scenario.

2) Again, prior to turn 1, has anyone inserted the Hyborem as a civ without giving someone the infernal pact technology?

If you did (and had hell terrain on) hell terrain would immediatly spread to all his lands. But the AC would need to increase before you would see it spreading into other areas.

3) Has anyone tried giving a barbarian Infernal pact to introduce the Hyborem?

Ive never tried that.

Bascially I think you have 2 options:

1. Introduce Hyborem early, once the AC gets high enough hell terrain will start spreading. You may want to play with the end days option on to double the ac movements.

2. Disable hell terrain and place it manually at the begining (thats what Im doing for the fane of lessers). It wont spread but you want have to worry about it flipping.
 
Quote:
2) Again, prior to turn 1, has anyone inserted the Hyborem as a civ without giving someone the infernal pact technology?


If you did (and had hell terrain on) hell terrain would immediatly spread to all his lands. But the AC would need to increase before you would see it spreading into other areas..

How does one insert Hyborem as an independant Civ?


Quote:
3) Has anyone tried giving a barbarian Infernal pact to introduce the Hyborem?



Ive never tried that.
..


I did tonight and play-tested a Civ for about a hundred turns. The barbarians became 2 Hyborem civs as far as I could tell. I accidently allowed myself to be slaughtered to the last before I could dump into the World Builder to take a better look. However at the end, there were two Hyborem civs.
 
Just confirming that. I'm tooling around with a Middle Earth map, and wanted the Infernals as a starting civ in Barad Dur. I created them as a starting civ, giving them only the Infernal Pact tech. The game immediately ran the "you have brought the Infernals into the world" script, and created a second Infernal civ.

It may be possible to get around this in a save: let the second Infernal civ be created, play a turn, go into WB and manually reset the position of all units to their starts, and remove the second Infernal civ. Save at this point and play on. However, I'm not sure you could use this as the basis of scenario, and it's pretty laborious.

Shame, but there you go. If anyone can figure how to get around this without scripting, I'd certainly be interested to know.
 
Just confirming that. I'm tooling around with a Middle Earth map, and wanted the Infernals as a starting civ in Barad Dur. I created them as a starting civ, giving them only the Infernal Pact tech. The game immediately ran the "you have brought the Infernals into the world" script, and created a second Infernal civ.

It may be possible to get around this in a save: let the second Infernal civ be created, play a turn, go into WB and manually reset the position of all units to their starts, and remove the second Infernal civ. Save at this point and play on. However, I'm not sure you could use this as the basis of scenario, and it's pretty laborious.

Shame, but there you go. If anyone can figure how to get around this without scripting, I'd certainly be interested to know.

I ended up going into a text editor



BeginTeam
TeamID=11
Tech=TECH_ANCIENT_CHANTS
Tech=TECH_MYSTICISM
ContactWithTeam=11
RevealMap=0
EndTeam
BeginPlayer
Team=11
LeaderType=LEADER_HYBOREM
LeaderName=TXT_KEY_LEADER_HYBOREM
CivDesc=TXT_KEY_CIV_INFERNAL_DESC
CivShortDesc=TXT_KEY_CIV_INFERNAL_SHORT_DESC
CivAdjective=TXT_KEY_CIV_INFERNAL_ADJECTIVE
FlagDecal=Art/Interface/TeamColor/Infernalflag.dds
WhiteFlag=0
CivType=CIVILIZATION_INFERNAL
Color=PLAYERCOLOR_INFERNAL
ArtStyle=ARTSTYLE_BARBARIAN
PlayableCiv=0
MinorNationStatus=0
StartingGold=0
StateReligion=
StartingEra=ERA_MEDIEVAL
RandomStartLocation=false
CivicOption=CIVICOPTION_GOVERNMENT, Civic=CIVIC_DESPOTISM
CivicOption=CIVICOPTION_CULTURAL_VALUES, Civic=CIVIC_RELIGION
CivicOption=CIVICOPTION_LABOR, Civic=CIVIC_TRIBALISM
CivicOption=CIVICOPTION_ECONOMY, Civic=CIVIC_DECENTRALIZATION
CivicOption=CIVICOPTION_COMPASSION, Civic=CIVIC_BASIC_CARE
CivicOption=CIVICOPTION_MEMBERSHIP, Civic=CIVIC_NO_MEMBERSHIP
AttitudePlayer=6, AttitudeExtra=-1
AttitudePlayer=9, AttitudeExtra=3
Handicap=HANDICAP_NOBLE
EndPlayer
 
But I suspect the infernals would later be added (again) if someone researches infernal pact. For which you could either disable the ashen veil religion, or select compact enforced option which would prevent the mercurians as well (unless also preadded).
 
But I suspect the infernals would later be added (again) if someone researches infernal pact. For which you could either disable the ashen veil religion, or select compact enforced option which would prevent the mercurians as well (unless also preadded).

A strong point. I'll have to remember to give the infernal pact and perhaps an acolyte of the religion to hyboream as well. That should prevent another civ from discovering it, and hopefully push the religion on the infernal.
 
That's what I'd done: created the Infernals as a starting team with the Infernal Pact tech. Starting the scenario immediately spawned another Infernal team. I presume it's scripted to do that when Infernal Pact is first researched, even if it's the start of a game. I'm reasonably happy hacking the map file, but scripting is beynd me, unfortunately.

EDIT: Ok, I have a solution, but it's not perfect. Create the Infernals as a starting team (as per srmacpherson's post above), and use the "Compact Enforced" game option. Voila, researching Infernal Pact will no longer spawn the Infernals, but since they're a starting team, they and their somewhat charred landscapes are in the game. The downside though, is the Mercurian Gate is now just an impressive garden feature, since the Mercurians can't be spawned either. That doesn't matter for my game, but may be critical to you.
 
Top Bottom