-
[BI] Adding a new religion
Hey there, I snooped around in the BI files and put some energy into adding a new religion.
By the way: I'm the first how-to for BI ;)
Ok, what I will do in this how-to is add Judaism to the game as a minority religion in the city of Rome, add a synagogue building and create some traits and ancillaries for it. I won't edit most graphics though.
I am no jew, so sorry if I offend anyone with this, I don't know too much alltogether about Judaism, so just drop an answer or send me a PM if you feel offended and tell me what you want changed.
//edit (10/22/05): It seems that newly added religions don't cause unrest or civil order. This is currently being researched, but don't assume that you did something wrong if your newly added religion doesn't make your people feel unhappy ;)
Step one: Get comfortable with data/descr_beliefs.txt
Adding a new faith is a no-brainer. Just copy an existing one ~:handball:
Code:
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
judaism
data/ui/pips/pip_religion_judaism_positive.tga
data/ui/pips/pip_religion_judaism_negative.tga
data/ui/pips/pip_religion_judaism.tga
JEWISH_LABEL
JEWISH_UNREST
JEWISH_ORDER
The pips have to be 24-bit TGA files with 16x16 pixels size. The directory information is resolved to the original R:TW base directory, so you have to create a folder called "Rome: Total War/data/ui/" then create a folder called "pips" inside this folder and put the images in there. You can see the images I used for the jewish religion below (you can't see them in the screenshots because this part was discovered by Andreas, big thanks, and I didn't keep my edited files):
https://img376.imageshack.us/img376/...symbols6nx.gif
(edited 10/25/05)
Step two: Adding the labels to data/text/expanded_bi.txt
Just append the following:
Code:
{JEWISH_LABEL} Judaism
{JEWISH_ORDER} Judaism is improving public order in this settlement
{JEWISH_UNREST} Judaism is causing unrest in this settlement
Step three: Giving Rome faith in data/world/maps/campaign/barbarian_invasion/descr_regions.txt
Copy /data/world/maps/base/descr_regions.txt to the campaign folder first.
Then edit the Northern Italy entry:
Code:
Northern_Italy
legion: Italica
Rome
empire_west
Latins
52 13 198
pottery, iron, slaves, marble, rome
5
7
christianity 50 pagan 25 judaism 25
As you can see, I weakened the christian majority to 50% and included a strong jewish minority with 25%. This is probably historically inaccurate but what the hell ~:cool:
Also change the Palaestina entry to this (see below):
Code:
Palaestina
legion: Palaestinae
Jerusalem
empire_east
Judaeans
244 13 29
olive_oil, wine, slaves, purple_dye, camels, berber, jerusalem
5
8
christianity 95 zoroastrian 5
Don't forget to delete map.rwm in the campaign folder before you start the game ;)
This is basically all there is to it. Read further for an additional account on what else you can do:
Step four: Creating synagogue buildings in data/export_descr_buildings.txt and data/export_descr_buildings_enums.txt
Add the following to data/export_descr_buildings.txt (I made it available to the Romans only as an off. belief):
Code:
building temple_synagogue
{
levels tefilah beit_midrash beit_knesset jewish_temple
{
tefilah requires factions { roman, }
{
capability
{
happiness_bonus bonus 1
religious_belief judaism 1
}
construction 1
cost 400
settlement_min town
upgrades
{
beit_midrash
}
}
beit_midrash requires factions { roman, }
{
capability
{
happiness_bonus bonus 2
religious_belief judaism 2
law_bonus bonus 1
}
construction 2
cost 800
settlement_min large_town
upgrades
{
beit_knesset
}
}
beit_knesset requires factions { roman, }
{
capability
{
happiness_bonus bonus 3
religious_belief judaism 3
law_bonus bonus 2
}
construction 3
cost 1600
settlement_min city
upgrades
{
jewish_temple
}
}
jewish_temple requires factions { roman, } and hidden_resource jerusalem
{
capability
{
happiness_bonus bonus 4
religious_belief judaism 4
law_bonus bonus 4
}
construction 5
cost 3200
settlement_min large_city
upgrades
{
}
}
}
plugins
{
}
}
Add the hidden_resource jerusalem at the beginning:
Code:
hidden_resources rome britain bosphoran berber slav sughdian
Then add this to data/export_descr_buildings_enums.txt:
Code:
tefilah
tefilah_desc
tefilah_desc_short
beit_midrash
beit_midrash_desc
beit_midrash_desc_short
beit_knesset
beit_knesset_desc
beit_knesset_desc_short
jewish_temple
jewish_temple_desc
jewish_temple_desc_short
Step 4.1: Describing the buildings in data/text/export_buildings.txt
Code:
{tefilah} Tefilah
{tefilah_desc}
The Tefilah is the most basic religious building of the Jews. Translated it means "House of Worship", so this is a place for prayer only.
{tefilah_desc_short}
The Tefilah is the basic Jewish religious building.
{beit_midrash} Beit Midrash
{beit_midrash_desc}
Beit Midrash means "House of Study". This improves the Tefilah with additional rooms to offer learning capabilities.
{beit_midrash_desc_short}
The Beit Midrash is an advanced Jewish religious building adding scholars to your Tefilah.
{beit_knesset} Beit K'nesset
{beit_knesset_desc}
The Beit K'nesset, more commonly referred to as a "Synagogue", which is just the Greek translation of the name, further enhances the Beit Midrash and is a magnificent place for learning and devotion.
{beit_knesset_desc_short}
The Beit K'nesset is a large Jewish building that provides its city with an advanced religious infrastructure.
{jewish_temple} Jewish Temple
{jewish_temple_desc}
The Jewish Temple is a uniquely beautiful and marvelous building. It is built similar to the great Temple of Salomo, which was destroyed by Roman forces in 70 AD after the second Jewish rebellion. The Jews belief that it will be rebuilt when the Messiah arrived, thus it is only available in Jerusalem.
{jewish_temple_desc_short}
This is the Temple of Salomo rebuilt, the most advanced religious building available for a Jewish settlement.
Step five: Adding Jewish ancillaries in data/export_descr_ancillaries.txt and data/export_descr_ancillary_enums.txt
In data/export_descr_ancillaries.txt add this:
Code:
;------------------------------------------
Ancillary jewish_gabbai
Image roman_official_ancillary.tga
ExcludeCultures barbarian, carthaginian, eastern, hun, nomad
Description jewish_gabbai_desc
EffectsDescription jewish_gabbai_effects_desc
Effect Influence 1
Effect Unrest -1
;------------------------------------------
Ancillary jewish_rabbi
Image roman_official_ancillary.tga
ExcludeCultures barbarian, carthaginian, eastern, hun, nomad
Description jewish_rabbi_desc
EffectsDescription jewish_rabbi_effects_desc
Effect Squalor -1
Effect Unrest -1
Effect Influence 1
Religious_Belief judaism 1
;------------------------------------------
Ancillary jewish_high_priest
Image roman_official_ancillary.tga
ExcludeCultures barbarian, carthaginian, eastern, hun, nomad
Description jewish_high_priest_desc
EffectsDescription jewish_high_priest_effects_desc
Effect Influence 3
Effect Unrest -3
Religious_Belief judaism 2
And these triggers:
Code:
;------------------------------------------
Trigger trigger_jewish_gabbai
WhenToTest CharacterTurnEnd
Condition EndedInSettlement
and RemainingMPPercentage = 100
and Trait Jew >= 1
and SettlementBuildingExists >= tefilah
and IsGeneral
AcquireAncillary jewish_gabbai chance 5
;------------------------------------------
Trigger trigger_jewish_rabbi
WhenToTest CharacterTurnEnd
Condition EndedInSettlement
and RemainingMPPercentage = 100
and Trait Jew >= 1
and SettlementBuildingExists >= beit_midrash
and IsGeneral
AcquireAncillary jewish_rabbi chance 3
;------------------------------------------
Trigger trigger_jewish_high_priest
WhenToTest CharacterTurnEnd
Condition EndedInSettlement
and RemainingMPPercentage = 100
and Trait Jew >= 1
and SettlementBuildingExists >= tefilah
and IsGeneral
and not FactionWideAncillaryExists jewish_high_priest
AcquireAncillary jewish_high_priest chance 2
Step 5.1: Describing the ancillaries in data/text/export_ancillaries.txt
Code:
{jewish_gabbai} Gabbai
{jewish_gabbai_desc}
A Gabbai is a person with profound knowledge of the lecture of the Torah. He has the honour of reciting or chanting passages of the Torah at religious services.
{jewish_gabbai_effects_desc}
+1 to influence, -1 to unrest
{jewish_rabbi} Rabbi
{jewish_rabbi_desc}
This is a man who was trained in Jewish religious practice and the lecture of the Torah for long years, as such he is able to teach others parts of his knowledge.
{jewish_rabbi_effects_desc}
+5% Jewish conversion, -1 to squalor, -1 to unrest, +1 to influence
{jewish_high_priest} Kohein
{jewish_high_priest_desc}
The Kohein are direct descendants of Aaron. They undertake important parts of the religious service in the Jewish temple.
{jewish_high_priest_effects_desc}
+10% Jewish conversion, -3 to unrest, +3 to influence
Step six: Adding the "Jewish" character traits to data/export_descr_character_traits.txt and data/export_descr_VnVs_enums.txt
First add this:
Code:
;------------------------------------------
Trait Jew
Characters all
AntiTraits Pagan, Zoroastrian, Christian
Level Jew
Description Jew_desc
EffectsDescription Jew_effects_desc
Threshold 1
Religious_Belief judaism 1
Now if you want a satisfying experience, you should search for "Christian" and then "Pagan" and everywhere they appear in AntiTraits, you should add "Jew" to the list (like this:)
Code:
;------------------------------------------
Trait Pagan
Characters all
AntiTraits Christian, Zoroastrian, Jew
Level Pagan
Description Pagan_desc
EffectsDescription Pagan_effects_desc
Threshold 1
Religious_Belief pagan 1
Then search in the file for "birth_religion_roman_1" and after this trigger insert a new one:
Code:
;------------------------------------------
Trigger birth_religion_roman_3
WhenToTest CharacterComesOfAge
Condition CultureType roman
and Trait Pagan = 0
and Trait Christian = 0
and Trait Zoroastrian = 0
Affects Jew 1 Chance 10
Now every (born) Roman faction member will have a chance of 10% to become a Jew.
Add to data/export_descr_VnVs_enums.txt
Code:
Jew
Jew_desc
Jew_effects_desc
Step 6.1: Describing the trait in data/text/export_VnVs.txt
Code:
{Jew} Jew
{Jew_desc}
This man is a Jew.
{Jew_effects_desc}
+5% Jewish conversion
Step seven: Making a character a Jew and adding a synagogue building in data/world/maps/campaign/barbarian_invasion/descr_strat.txt
I used the WRE faction leader to test these and modified him like this:
Code:
character Valentinianus Flavius, named character, leader, age 62, , x 95, y 71
traits LoyaltyStarter 1 , RomanFactionLeader 1, Jew 1 , Anger 3 , PoliticsSkill 2 , Corrupt 1 , ExpensiveTastes 2 , BadTrader 3
ancillaries elder_senator, famous_warrior, historian, jewish_gabbai, jewish_rabbi, jewish_high_priest
army
unit imperial german bodyguard exp 2 armour 1 weapon_lvl 1
unit comitatenses exp 1 armour 0 weapon_lvl 0
unit comitatenses exp 1 armour 0 weapon_lvl 0
unit roman priest exp 0 armour 0 weapon_lvl 0
unit comitatenses exp 1 armour 0 weapon_lvl 0
unit comitatenses exp 1 armour 0 weapon_lvl 0
unit comitatenses exp 1 armour 0 weapon_lvl 0
unit western archer exp 0 armour 0 weapon_lvl 0
unit bucellarii exp 0 armour 0 weapon_lvl 0
unit foederati cavalry exp 0 armour 0 weapon_lvl 0
unit foederati cavalry exp 0 armour 0 weapon_lvl 0
Replace the Northern_Italy entry with this:
Code:
settlement
{
level huge_city
region Northern_Italy
year_founded 363
population 50491
plan_set default_set
faction_creator empire_west
building
{
type core_building imperial_palace
}
building
{
type defenses epic_stone_wall
}
building
{
type barracks city_barracks
}
building
{
type equestrian hippodrome
}
building
{
type missiles siege_engineer
}
building
{
type market great_forum
}
building
{
type smith foundry
}
building
{
type port_buildings shipwright
}
building
{
type health aqueduct
}
building
{
type hinterland_farms farms+1
}
building
{
type hinterland_roads paved_roads
}
building
{
type academic scriptorium
}
building
{
type amphitheatres great_amphitheatre
}
building
{
type temple_synagogue beit_knesset
}
}
Voilà, you have added Judaism to the game.
I think you will be able to figure out the rest yourselves so go ahead ~D
Note, however, that there is a limit of 10 different religions at the maximum, of which you should only use 9 because the tenth pip collides with a text string on the settlement details scroll.
Here are a few screenshots of the in-game result:
https://img394.imageshack.us/img394/...ail15cb.th.jpg
https://img394.imageshack.us/img394/...ree11ds.th.jpg
https://img394.imageshack.us/img394/...ree25cw.th.jpg
https://img394.imageshack.us/img394/...oll18du.th.jpg
https://img394.imageshack.us/img394/...oll21ht.th.jpg
https://img394.imageshack.us/img394/...oll16xk.th.jpg
https://img394.imageshack.us/img394/...oll10xy.th.jpg
https://img394.imageshack.us/img394/...lem10yw.th.jpg
-
Re: [BI] Adding a new religion
Excellent! This was going to be the next thing I was going to work (having just learnt alot about loyalty and how it can be used), but you beat me to it.
Just from this and what I have done it seems as if the new features are alot more flexible then I initially expected (though not entirely sadly).
-
Re: [BI] Adding a new religion
Very nice idea making this a tutorial, nicely written and easy to understand too~:)
-
Re: [BI] Adding a new religion
Great! So you can have more than three religions?
-
Re : [BI] Adding a new religion
-
Re: [BI] Adding a new religion
Quote:
Originally Posted by Lonely Soldier
Great! So you can have more than three religions?
Yes you can :)
I don't know if there's a limit but judging from the interface there might.
I'll look into that today.
/edit: There's a limit of 10 different beliefs
-
Re: [BI] Adding a new religion
Wow, great work alpaca! Very useful, someone should try to find out if there's a hardcode limit on religions.
-
Re: [BI] Adding a new religion
I already did ;)
It's 10.
If you add more, the game crashes.
-
Re: [BI] Adding a new religion
Oh sorry :embarassed:
I didn't read every detail, i'd just woken up. ~;)
-
Re: [BI] Adding a new religion
-
Re: [BI] Adding a new religion
Is it possible to add religions to vanilla RTW?
You could have hellenism, celtic (or barbaric), zoroastrianism and phoenicians. Romans might as well be hellenistic. They preyed to the same gods.
-
Re: [BI] Adding a new religion
I don't think so. You could however convert Vanilla R:TW to BI and then add religions.
-
Re: [BI] Adding a new religion
Quote:
Originally Posted by alpaca
I don't think so. You could however convert Vanilla R:TW to BI and then add religions.
What I meant was, would it be possible to add religions to 1.4 RTW campaign? :) (1.4 being RTW with BI installed)
-
Re: [BI] Adding a new religion
I can currently not test this as I'll have to reinstall the game for R:TW to work ;) But I still don't think so because I believe that R:TW with BI is the same as R:TW 1.3
-
Re: [BI] Adding a new religion
Very nice. I am growing more pleased with CA as more things become moddable.
-
Re: [BI] Adding a new religion
Well I'm growing angry with them because they still impose tons of problems on us modders...
Just think about the hardcoded RB-emergence, the map_heights.hgt problem, ...
-
Re: [BI] Adding a new religion
Wow, it looks like I will have to buy BI to play with this Religion issue~D But first I most move to the new place.
:charge: :charge: :charge: :charge: :charge: :charge: :charge:
-
Re: [BI] Adding a new religion
Quote:
Originally Posted by alpaca
Well I'm growing angry with them because they still impose tons of problems on us modders...
Just think about the hardcoded RB-emergence, ...
? RB-emergence isnt hardcoded at all...
-
Re: [BI] Adding a new religion
Well it is tied to the "Britain" resource, but the above post was made before I found that out.
The condition is hardcoded, though.
Or if it isn't, please tell us where to find it...
-
Re: [BI] Adding a new religion
-
Re: [BI] Adding a new religion
Lol, did you smoke some bad stuff?
A few explaining words would be good, and Magic colors don't have anything to do with religion (except for white and green o'course)
-
Re: [BI] Adding a new religion
Quote:
Originally Posted by alpaca
Well it is tied to the "Britain" resource, but the above post was made before I found that out.
The condition is hardcoded, though.
Or if it isn't, please tell us where to find it...
well what I mean is the Romano British dont have to emerge at all...
-
Re: [BI] Adding a new religion
I just had an idea for war of the wizards mod. decided to test and was overjoyed. Probably illegal to use mtg material so i will stop there in using theirs, as for religion... that can be viewed as alignment to a certain way of thinking about the world, which it is, so red, white etc could be effectively thought of as religions for game purposes
Wanted to thank you for your great find
-
Re: [BI] Adding a new religion
Nice tutorial! But how do I change the icons, for example "pip_religion_zoroastrian_positive.tga". I can't seem to find those files anywhere, are they packed somewhere (windows search feature doesn't work)?
I also wonder if anyone else has noticed this, but when I added a religion Judaism and three other religions following only steps one and two, for some reason the game said there was 10 percent Judaism in Antioch (I found out when I looked around for good screenshots of the work so far, so I wanted a settlement with mixed orthodox and catholic, i.e. with mixed in-game zoroastra and christianity, which with the BI vanilla map made Antioch a candidate) even though I hadn't yet touched the descr_regions.txt (because I'm working on the vanilla BI map, and waiting for another mod team member to finish the real map before editing the descr_regions.txt). Perhaps a bug? I made catholicism from Christianity and converted Zoroastrianism to Orthodox, then made Pagan into Viking Paganism / Asatrú. However, Judaism, Sunni, Shia and Steppe shamanism were added following steps one and two, but no other changes were made. It might be just me...
-
Re: [BI] Adding a new religion
Hmm ok:
You should be able to just create the icons and put them in the appropriate folder. However I guess they must have a certain size and a certain bit-rate.
I don't know which these are, though. The currently used pips are probably stored somewhere in a ui-pack.
That incidence you describe is quite strange really, I guess you can reproduce it?
-
Re: [BI] Adding a new religion
Hi
Thanks for a very good description. However I don´t get step three fully. Sorry if the questions are somewhat stupid but I am not so familiar with modding.
You wrote:
"Step three: Giving Rome faith in data/world/maps/campaign/barbarian_invasion/descr_regions.txt
Copy /data/world/maps/base/descr_regions.txt to the campaign folder first.
Then edit the Northern Italy entry:"
I wonder what this mean. What should I copy and why? Isn´t it enough to alter regions.txt in BI?
Another question. What was the change for "Jerusalem" in Palestinae and what does "Jerusalem as hidden resource" mean?
cheers,
~:) BoC
-
Re: [BI] Adding a new religion
@alpaca: I've reproduced it once, just to be sure it wasn't some temporary error. But I never checked if any other settlements were affected. In the files, antioch has:
- christianity 85 pagan 5 zoroastrian 10
I got christianity (=catholic) 85 zoroastrianism (=orthodox) 5 judaism 10.
Wait, I think I've discovered something. I changed the order in which the religions appear in the descr_beliefs. Zoroastrianism now comes 2nd, and Judaism 3rd. That means the engine perhaps can't handle them coming in the wrong order. I'll try something and will be back with more info.
-
Re: [BI] Adding a new religion
I've now tested, and it seems like newly added religions must be added last in the file in order to not confuse the engine. For example with descr_sm_factions.txt you can change the order of the factions if you want their icons in the menu to appear in a different order, but for religions this isn't possible without confusing the engine. So if you want the icons in a specific order, you may need to convert the existing religions. i.e., in my case:
christianity -> catholc
pagan -> orthodox
zoroastrianism -> judaism
then add the remaining ones below.
but the problem with icons I haven't solved yet. apparently, userfriendly has solved it judging from his screenshot...
@userfriendly: could you tell how you managed to change the icons for the religions in the settlement details scroll? Where can the files be found?
-
Re: [BI] Adding a new religion
@Bernhard: The change to the Palaestina enty is to add the jerusalem hidden resource to it.
This resource is used to make The Temple available only in Jerusalem.
You should copy the descr_regions.txt file from your world/base directory to your world/campaign/barbarian_invasion directory. This is not necessary, but I usually prefer having the files directly in the campaign dir instead of the base folder.
@Legio: interesting, so the game uses the adress somewhere instead of an id.
-
Re: [BI] Adding a new religion
Alpaca thanks for the answer. I have tried to add arianism and manichaeism to the game (two important religions at the time) so far without success. I will double and triple check my changes though so hopefully I will be able to add the religions~:)