QUESTION: Adding Gold to Farms

Officer Reene

It hates you all
Joined
Jan 21, 2006
Messages
698
Location
In the middle of nowhere
I want to add gold to farm plots and Farm Bonuses

I have edited the XML files to do this... and it works... however

when I add the gold... for some reason it disables the "farm spreads irrigation" and "Farms do not need irrigation" techs :mad:

My workers can not create farms unless they are next to a river... even if I have the respective techs :confused:

this sounds like a python/SDK override issue

(Kinda like the option to make peaks "passable" in XML but no matter what you do to the XML file you can not make peaks "passable" by units)

I was wondering if any you coder wizards have a solution to this problem :mischief:


any help would be greatly appreciated! :goodjob:
 
What exactly have you changed? Did your farms just produce commerce, did they produce the resources gold if they are on a gold tile? Or did they even provide the resource gold if they on a tile without gold?
 
Chamaedrys said:
What exactly have you changed? Did your farms just produce commerce, did they produce the resources gold if they are on a gold tile? Or did they even provide the resource gold if they on a tile without gold?


In the XML file CIV4ImprovementInfos.XML:

I changed:


Code:
			<Type>IMPROVEMENT_FARM</Type>
			<Description>TXT_KEY_IMPROVEMENT_FARM</Description>
			<Civilopedia>TXT_KEY_IMPROVEMENT_FARM_PEDIA</Civilopedia>
			<ArtDefineTag>ART_DEF_IMPROVEMENT_FARM</ArtDefineTag>
			<PrereqNatureYields>
				<iYield>1</iYield>
				<iYield>0</iYield>
				[COLOR="Green"]<iYield>0</iYield>[/COLOR]
			</PrereqNatureYields>
			<IrrigatedYieldChange>
				<iYield>1</iYield>
				<iYield>0</iYield>
				[COLOR="Green"]<iYield>0</iYield>[/COLOR]
			</IrrigatedYieldChange>


to this:

Code:
			<Type>IMPROVEMENT_FARM</Type>
			<Description>TXT_KEY_IMPROVEMENT_FARM</Description>
			<Civilopedia>TXT_KEY_IMPROVEMENT_FARM_PEDIA</Civilopedia>
			<ArtDefineTag>ART_DEF_IMPROVEMENT_FARM</ArtDefineTag>
			<PrereqNatureYields>
				<iYield>1</iYield>
				<iYield>0</iYield>
				[COLOR="Blue"]<iYield>1</iYield>[/COLOR]
			</PrereqNatureYields>
			<IrrigatedYieldChange>
				<iYield>1</iYield>
				<iYield>0</iYield>
				[COLOR="Blue"]<iYield>1</iYield>[/COLOR]
			</IrrigatedYieldChange>


which did change the commerce but disabled the ability to Irrigate or Ignore Irrigation rule :sad:



dont know why it cause that problem.... :confused:
 
I think you don't stop spreading irrigation but ask for 1 commerce for the improvement to be built ... so you need a river to build farm ?

but i'am not sure , try to change only the secong term .

Tcho !
 
It is definitely the PrereqNatureYields that is the problem.

Prereq = Prerequisite = You gotta have that much already before you can do the change.
 
zyphyr said:
It is definitely the PrereqNatureYields that is the problem.

Prereq = Prerequisite = You gotta have that much already before you can do the change.


*slaps head*

Damn I am stupid I should have paid more attention... :mad:

well that and working on the mod for 7 hours straight didnt help :crazyeye:


thx for your help all



EDIT: Tried it and it worked like a charm.... thx again! :D
 
Back
Top Bottom