Hi All,
I have been playing with this problem for some time now, and I have now figured out how to do it. To illustrate I will include some code from Nordicus' Trade Goods Mod from the Terrain.txt file.
The code included in the Terrain.txt file looks like the following. It is the entry from Good1 for the Plains Terrain Type. In Nordicus' Mod that good is Wheat.
###Wheat###
GOOD1 {
GOOD_INDEX 1
PROBABILITY 0.5
GOOD_CAN_DIE
ENV_BASE {
ENV_SCORE 386 }
TRANSFORM_REMOVE 1
TRANSFORM_ADD 1 400
TRANSFORM_ADD_ADVANCE ADVANCE_TOOLMAKING
TRANSFORM_REMOVE_ADVANCE ADVANCE_TOOLMAKING
}
This is the code as it is originally. The following code is the change that I have made.
###Wheat###
GOOD1 {
GOOD_INDEX 1
PROBABILITY 0.5
GOOD_CAN_DIE
ENV_BASE {
ENV_SCORE 386
ENV_FOOD 20 }
TRANSFORM_REMOVE 1
TRANSFORM_ADD 1 400
TRANSFORM_ADD_ADVANCE ADVANCE_TOOLMAKING
TRANSFORM_REMOVE_ADVANCE ADVANCE_TOOLMAKING
}
You will notice that I added the code "ENV_FOOD 20" after the "ENV_SCORE" code in front of the closing "}" bracket. What this does is changes the base food for this Terrain Type from 10, which is what Nordicus set it to, to 20. This results it the base food for all Plains Terrain Types with the Wheat Good on them to change from a base of 10 food to a base of 20 food. All the terrain improvements after this will then add there bonuses to the food base of 20 instead of the food base of 10 that regular Plains Terrain Types have. These changes must always come after the "ENV_BASE" command and within the two "{...}" brackets that define the variable of the "ENV_BASE" command or it will not work. If you don't put it in this specific location, CTP will come back with a Terrain.txt error when you try to load it and the computer will not load CTP.
Here is an example. Plains have a food base of 10. When you add a Farm it adds 10 to the food base and thus gives you 20 food units from this Terrain Type instead of the usual 10. Once you add the Advance Farm improvement you will then get 25 food units instead of 10. With Hydroponic Farms you will get 35 food units. Now using the code I have demonstrated here, will result in all the cumlitive food units from the Terrain Improvements to start at a base of 20 instead of 10 if the Plains Terrain Type has Wheat present. Thus, Farms now yeild 30 Food Units, Advance Farms yield 35 Food Units, and Hydroponic Farms will yield 45 food units, but only if Wheat is present on the Plains Terrain Tile.
This method also works for Production with ENV_SHIELD in place of ENV_FOOD. ENV_GOLD can be added to change the base Gold when a specific Good is present. The addive values of the other Terrain Improvements will work just like the farms in their repsective areas.
One thing that it is important to remember in regards to ENV_GOLD is that the Gold Trade value will be whatever is put in the Goods.txt, no matter what the base Gold is changed to. Thus, if you change the Base Gold for Apples to 50, but you leave the Gold value in Goods.txt at Nordicus' default of 5, then when you establish a trade route with Apples, only 5 Gold will be traded. The rest of the Gold will stay in the originial city.
Another thing you can do is add combinations of SHIELD, FOOD, and GOLD to a specific Good. Thus, for example Spices can have both a FOOD and a SHIELD bonus by changing the Terrain Base value for these two areas when the good Spices is present.
Well, I hope ya'll find this interesting and helpful in your Mod making.
Regards,
Timothy Pintello
Note: There are Tab spaces between the ENV_XXXX varible/commands and the number value to be added to them that this screen does not show.
[This message has been edited by Pintello (edited January 28, 2000).]
I have been playing with this problem for some time now, and I have now figured out how to do it. To illustrate I will include some code from Nordicus' Trade Goods Mod from the Terrain.txt file.
The code included in the Terrain.txt file looks like the following. It is the entry from Good1 for the Plains Terrain Type. In Nordicus' Mod that good is Wheat.
###Wheat###
GOOD1 {
GOOD_INDEX 1
PROBABILITY 0.5
GOOD_CAN_DIE
ENV_BASE {
ENV_SCORE 386 }
TRANSFORM_REMOVE 1
TRANSFORM_ADD 1 400
TRANSFORM_ADD_ADVANCE ADVANCE_TOOLMAKING
TRANSFORM_REMOVE_ADVANCE ADVANCE_TOOLMAKING
}
This is the code as it is originally. The following code is the change that I have made.
###Wheat###
GOOD1 {
GOOD_INDEX 1
PROBABILITY 0.5
GOOD_CAN_DIE
ENV_BASE {
ENV_SCORE 386
ENV_FOOD 20 }
TRANSFORM_REMOVE 1
TRANSFORM_ADD 1 400
TRANSFORM_ADD_ADVANCE ADVANCE_TOOLMAKING
TRANSFORM_REMOVE_ADVANCE ADVANCE_TOOLMAKING
}
You will notice that I added the code "ENV_FOOD 20" after the "ENV_SCORE" code in front of the closing "}" bracket. What this does is changes the base food for this Terrain Type from 10, which is what Nordicus set it to, to 20. This results it the base food for all Plains Terrain Types with the Wheat Good on them to change from a base of 10 food to a base of 20 food. All the terrain improvements after this will then add there bonuses to the food base of 20 instead of the food base of 10 that regular Plains Terrain Types have. These changes must always come after the "ENV_BASE" command and within the two "{...}" brackets that define the variable of the "ENV_BASE" command or it will not work. If you don't put it in this specific location, CTP will come back with a Terrain.txt error when you try to load it and the computer will not load CTP.
Here is an example. Plains have a food base of 10. When you add a Farm it adds 10 to the food base and thus gives you 20 food units from this Terrain Type instead of the usual 10. Once you add the Advance Farm improvement you will then get 25 food units instead of 10. With Hydroponic Farms you will get 35 food units. Now using the code I have demonstrated here, will result in all the cumlitive food units from the Terrain Improvements to start at a base of 20 instead of 10 if the Plains Terrain Type has Wheat present. Thus, Farms now yeild 30 Food Units, Advance Farms yield 35 Food Units, and Hydroponic Farms will yield 45 food units, but only if Wheat is present on the Plains Terrain Tile.
This method also works for Production with ENV_SHIELD in place of ENV_FOOD. ENV_GOLD can be added to change the base Gold when a specific Good is present. The addive values of the other Terrain Improvements will work just like the farms in their repsective areas.
One thing that it is important to remember in regards to ENV_GOLD is that the Gold Trade value will be whatever is put in the Goods.txt, no matter what the base Gold is changed to. Thus, if you change the Base Gold for Apples to 50, but you leave the Gold value in Goods.txt at Nordicus' default of 5, then when you establish a trade route with Apples, only 5 Gold will be traded. The rest of the Gold will stay in the originial city.
Another thing you can do is add combinations of SHIELD, FOOD, and GOLD to a specific Good. Thus, for example Spices can have both a FOOD and a SHIELD bonus by changing the Terrain Base value for these two areas when the good Spices is present.
Well, I hope ya'll find this interesting and helpful in your Mod making.
Regards,
Timothy Pintello
Note: There are Tab spaces between the ENV_XXXX varible/commands and the number value to be added to them that this screen does not show.
[This message has been edited by Pintello (edited January 28, 2000).]
Comment