宗教模组制作

(重定向自Religion_modding)
2.7· 约 25 分钟阅读

本页面所适用的版本可能已经过时,最后更新于 v2.7。

v2.7

宗教与宗教组被定义于/common/religions文件夹。

宗教组[编辑]

每个宗教都属于一个宗教组,例如:

  • Catholic 与 Orthodox 属于基督教组。
  • Sunni 与 Shiite 属于伊斯兰教组。

请注意,某些行为是根据原版宗教组硬编码的:

  • 原版宗教组: 未改革的原始宗教不能要求宗教皈依

宗教组定义为带有字母数字 ID 的组标签。一个宗教组必须定义有 graphical_culture和一个或多个宗教。

宗教组定义(包含宗教)的一个例子是:

zoroastrian_group = { has_coa_on_barony_only =yes graphical_culture = muslimgfx

   #religions go here

}

下面列出了可为宗教组设置的所有参数。

属性

类型

描述

举例

color

color

用于每个宗教团体在地图模式下的颜色

color = { 0.25 0.5 0.75 }

graphical_culture

ID

仅用于地图上显示CoA框架

graphical_culture = norsegfx

has_coa_on_barony_only

boolean

这行决定宗教是否在男爵级别以上使用随机图形:

  • has_coa_on_barony_only = yes: 为男爵生成随机CoA,但使用gfx/flags/为更高的级别。
  • has_coa_on_barony_only = no: 为所有级别生成随机CoA,并完全忽略gfx/flags/。

has_coa_on_barony_only = yes

hostile_within_group

bool

决定宗教团体中的圣职者是否会与同一团体内的其他宗教作战,也会阻止团体内的跨信仰婚姻。

crusade_cb

ID

定义一个宗教团体是否可以进行十字军东征/圣战。在原版CKII中,这只适用于基督教、伊斯兰教和以色列宗教团体。

crusade_cb = crusade

playable

boolean

定义该宗教的角色是否可玩。不适用于“穆斯林”团体,因为它只能由伊斯兰之剑启用。

playable = yes

ai_peaceful

boolean

将使部落在转换为这种宗教后失去其超强攻击性

ai_peaceful = yes

ai_fabricate_claims

boolean

ai_fabricate_claims = no

merge_republic_interface

boolean

决定宗教是否会尝试将其界面与共和国界面合并。如果是,那么在共和国寻找其宗教界面的纹理时,他们将查找 _republic 并使用该版本的纹理,而不是宗教的正常纹理。默认设置为no。

merge_republic_interface = yes

宗教[编辑]

以下是可为宗教设置的所有参数列表。请注意,从“investiture”开始及以下的内容均为可选项。

Attribute

Type

Description

Example

ai_convert_same_group

int

决定 AI 是否派遣宫廷牧师对同一宗教组的宗教进行传教:

  • 0: 从不尝试转换
  • 1: 如果 ai_zeal 高则尝试转换
  • 2: 总是尝试转换

ai_convert_same_group = 2

ai_convert_other_group

int

决定 AI 是否派遣宫廷牧师对其他宗教组进行传教:

  • 0: 从不尝试转换
  • 1: 如果 ai_zeal 高则尝试转换
  • 2: 总是尝试转换

ai_convert_other_group = 1

graphical_culture

ID

仅用于地图上显示 CoA 框架

graphical_culture = norsegfx

icon

int

定义游戏中用于宗教的图标。异端图标的值会被忽略(除非异端成为主流宗教),而使用父宗教的异端图标。

icon = 1

color

color

绘制宗教地图模式时使用的颜色,RGB 格式范围为 0.0-1.0。要确定 RGB 的值,只需除以 255,例如 180 ÷ 255 = 0.7

color = { 0.25 0.5 0.75 }

crusade_name

key

定义宗教十字军东征名称的本地化键。仅适用于crusade_cb = crusade的宗教团体。

crusade_name = "CRUSADE"

scripture_name

key

定义宗教圣书的本地化键。

scripture_name = THE_BIBLE

god_names

list

定义宗教神灵的本地化键,使用大括号括起来,并用空格分隔。

god_names = { GOD_GOD GOD_THE_LORD }

high_god_name

key

高级神的本地化键

high_god_name = GOD_GOD

evil_god_names

list

定义宗教邪恶神灵的本地化键,使用大括号括起来,并用空格分隔。

evil_god_names = { SATAN LUCIFER THE_DEVIL }

piety_name

key

定义宗教虔诚度的本地化键。

piety_name = KARMA

priest_title

key

定义寺庙持有者的本地化键。

priest_title = PRIEST

investiture

bool

决定是否可以任命主教。受任命法修改,仅适用于基督教团体,不能与自主教区结合使用。

investiture = yes

can_demand_religious_conversion

bool

决定该宗教的角色是否可以要求其他角色皈依。政府也必须允许。

can_demand_religious_conversion = yes

can_excommunicate

bool

决定宗教领袖是否可以将成员绝罚。

can_excommunicate = yes

can_grant_divorce

bool

决定宗教领袖是否可以允许离婚

can_grant_divorce = yes

can_grant_invasion_cb

cb

决定宗教领袖是否可以授予宣战理由

can_grant_invasion_cb = invasion

can_grant_claim

bool

决定宗教领袖是否可以授予宣称(实际不起作用)

can_grant_claim = yes

can_call_crusade

bool

决定宗教领袖是否可以号召十字军

can_call_crusade = yes

can_have_antipopes

bool

启用对立教宗

can_have_antipopes = yes

can_retire_to_monastery

bool

启用宣誓效忠

can_retire_to_monastery = yes

parent

religion

使宗教成为其父宗教的异端。父宗教必须先定义。注意:改革后的原始宗教可以有异端,但需要在改革后和未改革的宗教定义之后。

parent = catholic

priests_can_marry

bool

决定神职人员是否可以结婚。

priests_can_marry = yes

priests_can_inherit

bool

决定神职人员是否有继承权。

priests_can_inherit = no

feminist

bool

取消对女性统治者或女性继承人的负面意见修饰符。

feminist = yes

pacifist

bool

表示宗教具有减少的侵略性和稳定的领域。仅在玩家没有Rajas of India时适用于耆那教。

pacifist = yes

bs_marriage

bool

允许兄妹结婚。

bs_marriage = yes

pc_marriage

bool

允许父母与子女结婚。

pc_marriage = yes

psc_marriage

bool

不允许叔侄和姨甥结婚。

psc_marriage = no

cousin_marriage

bool

不允许表亲结婚。

cousin_marriage = no

matrilineal_marriages

bool

禁止母系婚姻

matrilineal_marriages = no

intermarry

religion

指定成员是否倾向于与特定其他宗教/宗教团体成员结婚

intermarry = norse_pagan_reformed

max_wives

int

确定宗教成员可以有的妻子最大数量,以及自动生成的潜在妻子的数量

max_wives = 4

allow_viking_invasion

bool

允许“准备入侵”的外交行动

allow_viking_invasion = yes

allow_looting

bool

允许掠夺

allow_looting = yes

seafarer

bool

AI在掠夺时会优先选择沿海省份

seafarer = yes

allow_rivermovement

bool

允许河流航行

allow_rivermovement = yes

female_temple_holders

bool

允许女性神庙附庸

female_temple_holders = yes

male_temple_holders

bool

允许男性神庙附庸。默认值为yes。

male_temple_holders = no

short_reign_opinion_year_mult

integer

短期统治年的意见惩罚乘数。覆盖定义SHORT_REIGN_OPINION_MULT = 2。

short_reign_opinion_year_mult = 3

aggression

double

AI侵略因子

aggression = 1.5

max_consorts

int

最大配偶/妾的数量

max_consorts = 3

religious_clothing_head

int

用于宗教头部服装和头饰的帧索引。参见portrait modding.

religious_clothing_head = 3

religious_clothing_priest

int

用于牧师服装和头饰的帧索引。参见portrait modding.

religious_clothing_priest = 3

secondary_event_pictures

[]

secondary_event_pictures = norse_pagan

autocephaly

bool

自主教会

autocephaly = yes

pentarchy

bool

自主教会主教 行为. Implies autocephaly = yes.

pentarchy = yes

divine_blood

bool

Sacred Xwedodah close-kin marriage mechanics

divine_blood = yes

has_heir_designation

bool

允许指定继承人

has_heir_designation = yes

defensive_attrition

bool

省份防御性损耗

defensive_attrition = yes

ignores_defensive_attrition

bool

用于没有防御性损耗的宗教,但仍不会对这些宗教产生惩罚。

ignores_defensive_attrition = yes

heresy_icon

int

异端图标。注意,这必须在父宗教中设置,而不是在异端级别。

heresy_icon = 7

independence_war_score_bonus

int

覆盖定义CONTESTED_TITLE_OCCUPIED_WARSCORE_BONUS_INDEP

independence_war_score_bonus = 30

peace_prestige_loss

bool

和平时失去声望

peace_prestige_loss = yes

peace_piety_gain

double

和平时获得虔诚度(每月的虔诚度)

peace_piety_gain = 1.0

raised_vassal_opinion_loss

bool

决定是否在提高附庸征兵时会对领主产生负面意见。

raised_vassal_opinion_loss = no

reformed

religion

注意:改革后的宗教需要在文件中位于未改革宗教之前。

reformed = aztec_reformed

reformer_head_of_religion

bool

使改革此宗教的角色成为新改革信仰的领袖。必须在改革宗教中设置。

  • 改革宗教的头衔 (d_) 不能有 primary = yes,否则会导致游戏结束。landless = yes可能不是问题[?]
  • 你还需要进行government modding,否则角色将处于无政府状态。在government potentials中将NOT = { religion = norse_pagan_reformed } 替换为更通用的NOT = { primary_title = { is_landless_type_title = no } }

reformer_head_of_religion = yes

pre_reformed

bool

使原始宗教处于改革前状态。注意,这些宗教不会出现在统计中。

pre_reformed = yes

unit_modifier

unit modifiers

单位的修正

unit_home_modifier

unit modifiers

本土单位的修正

character_modifier

character modifiers

对所有该宗教角色的修正

character_modifier = { learning = 4 }

expel_modifier

modifiers

[]

expel_modifier = expelled_jewish

landed_kin_prestige_bonus

bool

给予拥有国王头衔作为附庸的声望加成。

landed_kin_prestige_bonus = yes

allow_in_ruler_designer

bool

防止该宗教出现在角色设计器,通常是改革后的原始宗教。

allow_in_ruler_designer = no

dislike_tribal_organization

bool

如果领主增加部落组织度,附庸会不满并形成派系。通常用于未改革的原始宗教,应该首先转换为一神教再尝试封建化。

dislike_tribal_organization = yes

uses_decadence

bool

如果宗教和政府允许则使用腐化

uses_decadence = yes

uses_jizya_tax

bool

启用异教徒税

uses_jizya_tax = yes

attacking_same_religion_piety_loss

bool

攻击同宗教损失虔诚

attacking_same_religion_piety_loss = yes

hard_to_convert

bool

Checked via is_hard_to_convert character/province trigger.

hard_to_convert = yes

men_can_take_consorts

bool

如果设置,男性可以纳妾。默认是yes。如果 max_consorts 为0则无效。

men_can_take_consorts = yes

women_can_take_consorts

bool

如果设置,女性可以纳男宠。默认是no。如果 max_consorts 为0则无效。

women_can_take_consorts = yes

interface_skin

interface

该宗教提供的界面

interface_skin = { pagan_interface }

castes

bool

是否使用种姓制度。

castes = yes

caste_opinions

bool

是否使用种姓意见修正。

caste_opinions = yes

has_coa_on_barony_only

bool

与同名宗教团体参数的工作方式相同。如果设置,则覆盖宗教团体的设置。

has_coa_on_barony_only = yes

join_crusade_if_bordering_hostile

bool

如果设置为yes,AI不会因为与异教/异端领地接壤而避免参加十字军东征。

join_crusade_if_bordering_hostile = yes

merge_republic_interface

boolean

决定宗教是否会尝试将其界面与共和国界面合并。如果是,那么在共和国寻找其宗教界面的纹理时,他们将查找 _republic 并使用该版本的纹理,而不是宗教的正常纹理。默认是no。如果设置,覆盖宗教团体的值。

merge_republic_interface = yes

rel_head_defense

boolean

如果设置为yes,该宗教的人在其宗教领袖被不同宗教攻击时可能会加入防御。

rel_head_defense = yes

例子[编辑]

christian = { has_coa_on_barony_only = yes graphical_culture = westerngfx crusade_cb = crusade playable = yes ai_peaceful = yes # Will make Hordes lose their super aggressiveness

catholic = { graphical_culture = westerngfx

icon = 1 color = { 0.8 0.8 0.6 }

crusade_name = "CRUSADE" scripture_name = THE_BIBLE god_names = { GOD_GOD GOD_THE_LORD GOD_JESUS GOD_THE_BLESSED_VIRGIN }

investiture = yes can_excommunicate = yes can_grant_divorce = yes can_grant_invasion_cb = invasion can_grant_claim = yes can_call_crusade = yes } } }

本地化[编辑]

  • : 宗教的简短名称。使用 [Religion.GetName]
  • _DESC: 宗教工具提示中的描述
  • _full: 较长的名称,显示在地图和大多数用户界面中,以及 [Religion.GetFullName]

添加图标[编辑]

添加新的宗教图标是一个相对简单的过程。首先,你需要修改CKII\gfx\interface 文件夹中的 religion_icon_strip.dds和 religion_icon_strip_small.dds文件。在religion_icon_strip.dds 中,将图像画布向右扩展32像素以添加每一个新图标;在religion_icon_strip_small.dds文件中,每添加一个新图标将画布扩展20像素。 一旦添加了新的图标,你需要编辑CKII\interface中的 "generalstuff.gfx" 文件,增加 noOfFrames = 行的数字增加的数量为你添加的图标数。完成这些步骤后,你就可以在你的宗教中使用这些新的图标,从左到右编号为1-X。

spriteType = { name = "GFX_religion_icon_strip" texturefile = "gfx\\interface\\religion_icon_strip.tga" noOfFrames = 10 }

spriteType = { name = "GFX_religion_icon_strip_small" texturefile = "gfx\\interface\\religion_icon_strip_small.tga" noOfFrames = 10 }

宗教领袖[编辑]

宗教领袖可以通过头衔模组制作 条目来建立。你必须首先创建一个任何等级的头衔,并在该头衔条目中添加变量 controls_religion = X。例如:

k_coptic = { color={RGB} color2={RGB} capital = 1 religion = monophysite controls_religion = monophysite }

以上头衔的持有者将被视为一性论宗教/异端的宗教领袖。建议添加religion = monophysite 行,以确保为该头衔随机生成的任何/所有角色都是同一宗教的。如果没有这行代码,而设置 capital = 变量的省份是天主教的,你可能会得到一个基督一性论的天主教宗教领袖。

圣地[编辑]

圣地在伯爵级通过头衔模组制作。

c_koln = {
holy_site = catholic
}

为了维护,最好只覆盖伯爵级, 并在 /common/landed_titles/ 下通过单独的文件标记圣地,而不复制到landed_titles.txt。也可以为异端定义圣地,不过如果未使用,游戏会回退到父宗教的圣地。

十字军目标权重[编辑]

十字军#十字军目标权重位于common/landed_titles/landed_titles.txt。

k_lotharingia = {
catholic = 5000
}

请注意,如果该宗教没有目标权重,AI 永远不会发起十字军。

教宗继承[编辑]

将宗教添加到succ_papal_succession 继承法并定义一些宗教头衔时,打开宗教标签会导致游戏崩溃。需要进行一些界面模组制作以使其正常工作。

改革[编辑]

如果一个宗教在其代码中有一个改革版,它将继承改革的行动。

如果你想更改改革的界面,你可以编辑 "religion_features"文件夹中的文件,并搜索"buttons" 进行更改。然后你需要更改设置在'\common\religion_features'的"religion_reformation.gui"文件中的UI。

例如,你可以更改

religion_doctrine = {
buttons = { doctrine1 doctrine2 }

and change it to:

religion_doctrine = {
buttons = { doctrine1 doctrine2 doctrine3 }

in the "00_feature.txt" and then add:

windowType = {
name = "doctrine3"
position = { x=487 y=190 }
moveable = 0
fullScreen = no
Orientation = "UPPER_LEFT"

guiButtonType = {
name = "picture"
position = { x=0 y=15}
quadTextureSprite ="GFX_religion_feature_primitive"
clicksound = bookmark_click
pdx_tooltip = "REFORMATION_SELECT_FEATURE"
}
instantTextBoxType = {
name = "feature_label"
position = { x = 10 y = 150 }
font = "vic_22_black"
text = "feature_uncertain"
maxWidth = 173
maxHeight = 20
fixedsize = yes
format = centre
}
}

in the "religion_reformation.gui" in order to set third doctrine in the Reformation.

界面[编辑]

在3.0版本补丁中,特定信仰对应的界面可以通过添加变量 interface_skin = { x }. 进行修改。X 代表 gfx/interface 中界面文件夹的名称。可以混合多种界面,在原版游戏中,这种情况发生在祆教、印度教(2个界面)、尊教、非洲宗教和道教(3个界面),以及苯教(4个界面)。

See also[编辑]