模组制作:修订间差异

本页面所适用的版本可能已经过时,最后更新于3.2
无编辑摘要
→‎游戏结构:​ 汉化
 
(未显示3个用户的22个中间版本)
第1行: 第1行:
{{version|3.2}}
{{version|3.2}}
'''Modding''', 或称为“模组制作”, is the act of modifying the behavior of the base game (often referred as ''vanilla''), either for personal use, or to release publicly to other players, for instance via the [[Steam Workshop]].
'''Modding''', 或称为“模组制作”, 是修改基本游戏(即原版)的行为, 无论是供个人使用,或者是公开发布给其他玩家,比如发布到[[Steam 创意工坊]]


 就所有p社游戏而言 ,ck2 的模组制作有很大开放性,可以很显著的延伸游戏的内容,增强游戏的可玩性。
 就所有p社游戏而言 ,[[王国风云II|ck2]] 的模组制作有很大开放性,可以很显著的延伸游戏的内容,增强游戏的可玩性。
mod制作者的动机各不相同:更好的翻译成母语,更多的事件及决议,更棒的地图,亦或游戏整体大修改等等。
mod制作者的动机各不相同:更好的翻译成母语,更多的事件及决议,更棒的地图,亦或游戏整体大修改等等。


第11行: 第11行:
*'''使用优质的文本编辑器''' 来编辑文件并搜索多个文件。请参见[[#文本编辑器|文本编辑器]]。
*'''使用优质的文本编辑器''' 来编辑文件并搜索多个文件。请参见[[#文本编辑器|文本编辑器]]。
*'''验证你的mod''' 使用[[The Validator]],它将为您节省许多麻烦和时间,以解决崩溃和错误。
*'''验证你的mod''' 使用[[The Validator]],它将为您节省许多麻烦和时间,以解决崩溃和错误。
*'''尽量减少 对Vanilla 文件的覆盖''' 通过添加单独的文件或尽可能地[[#游戏结构|从文件夹加载]],以改善mod兼容性和维护。
*'''尽量减少 对原版 文件的覆盖''' 通过添加单独的文件或尽可能地[[#游戏结构|从文件夹加载]],以改善mod兼容性和维护。
*'''使用适当的合并工具''' 以便在[[合并指南|文件夹之间合并]],并将修改后 的Vanilla 文件更新为新的Vanilla补丁。
*'''使用适当的合并工具''' 以便在[[合并指南|文件夹之间合并]],并将修改后 的原版 文件更新为新的Vanilla补丁。
*'''备份您的工作''' 以避免丢失一切。如果是一个MOD制作组,请考虑使用诸 如GitHub 之类的源代码控制系统充当备份并管理协作。
*'''备份您的工作''' 以避免丢失一切。如果是一个MOD制作组,请考虑使用诸 如[https://github.com/ GitHub] 之类的源代码控制系统充当备份并管理协作。
*'''使用ANSI(Windows-1252)编码''' 用于文本文件。
*'''使用ANSI(Windows-1252)编码''' 用于文本文件。
*'''适当缩进''' 以轻松发现未闭合的花括号 。Vanilla 使用1个制表符来缩进而不是空格。
*'''适当缩进''' 以轻松发现未闭合的花括号 。原版 使用1个制表符来缩进而不是空格。
* '''使用注释''' 以#字符开头,来记住编写棘手内容的原因。
* '''使用注释''' 以#字符开头,来记住编写棘手内容的原因。


第22行: 第22行:
 以下是支持CK2编程语言的文本编辑器:
 以下是支持CK2编程语言的文本编辑器:


* [http://notepad-plus-plus.org/ Notepad++]: [[forum:745679|CKII 语言文件]]
*[http://notepad-plus-plus.org/ Notepad++]: [[forum:745679|CKII 语言文件]]
* [https://www.sublimetext.com/ Sublime Text]: [[forum:1084658|Sublime Text 3语法高亮]]
*[https://www.sublimetext.com/ Sublime Text]: [[forum:1084658|Sublime Text 3语法高亮]]
* [https://atom.io/ Atom]: [https://atom.io/packages/language-crusader-kings--i-i language-crusader-kings--i-i]
*[https://atom.io/ Atom]: [https://atom.io/packages/language-crusader-kings--i-i language-crusader-kings--i-i]


==Mod结构==
==Mod结构==


{{Ambox|type=notice|text=如果你是第一次创作mod,请看引导[[creating a mod]].}}
{{Ambox|type=notice|text=如果你是第一次创作mod,请看引导[[ 创建模组]].}}
mod文件被放置在 ''~\Paradox Interactive\Crusader Kings II\mod'', 里面必须包含:
mod文件被放置在 ''~\Paradox Interactive\Crusader Kings II\mod'', 里面必须包含:
* .mod 文件, 告诉启动器如何加载你的mod
*.mod 文件, 告诉启动器如何加载你的mod
* 包含mod数据好的文件夹或者是zip压缩包。mod数据的文件结构必须和本体[[#Game structure|file and folder structure]]相同,注意文件夹和文件的名称大小写在Mac和Linux上 敏感的,这意味着 Abc 和 abc 会被视为两个mod。
*包含mod数据好的文件夹或者是zip压缩包。mod数据的文件结构必须和本体 [[# 游戏结构| 游戏结构]]相同,注意文件夹和文件的名称大小写在Mac和Linux上 敏感的,这意味着 Abc 和 abc 会被视为两个mod。


.mod 文件的文件名不能包含任何空格,否则在启动器重启的时候,不会被自动选中。
.mod 文件的文件名不能包含任何空格,否则在启动器重启的时候,不会被自动选中。
第50行: 第50行:
|path
|path
|'''Yes'''
|'''Yes'''
| 定义 个文件夹是你的mod文件夹。 其路径是相对于''~\Documents\Paradox Interactive\Crusader Kings II\'' .
|定义 个文件夹是你的mod文件夹。 其路径是相对于''~\Documents\Paradox Interactive\Crusader Kings II\'' .
|path = "mod/MyMod"
|path = "mod/MyMod"
|-
|-
第61行: 第61行:
|archive
|archive
|No
|No
|定义一个zip压缩包来代替文件夹。设置它的路径,路径是相对于 ''~\Documents\Paradox Interactive\Crusader Kings II\'' 的。这是从[[Steam Workshop]]下载的mod使用的格式,但是在将mod上传 到Workshop 时,必须使用path结构。
|定义一个zip压缩包来代替文件夹。设置它的路径,路径是相对于 ''~\Documents\Paradox Interactive\Crusader Kings II\'' 的。这是从[[Steam 创意工坊]]下载的mod使用的格式,但是在将mod上传 到创意工坊 时,必须使用path结构。
|archive = "mod/mymod.zip"
|archive = "mod/mymod.zip"
|-
|-
|replace_path
|replace_path
|No
|No
|告诉启动器覆盖对应文件夹 所有内容,并且只从mod中的指定路径加载。 This is the only way to effectively remove stuff from vanilla, and is most often used for total conversion mods.
|告诉启动器覆盖对应文件夹 所有内容,并且只从mod中的指定路径加载。 这是删除原版东西的唯一有效方式,而这经常被完全改动类mod所使用。
Notes: 
Notes: 
*'''replace_path works with folders, not files'''. To overwrite a file, just create a file with the same name in the mod.
*'''replace_path 作为文件夹工作,而不是文件'''. ,覆盖一个文件,只需要在mod中创建一个同名文件。
*'''replace_path only affects files in the specified folder, not files in sub-folders within that folder'''. For instance, replacing "history" does not replace "history/characters" as well.
*'''replace_path 只对对应文件夹中的文件有效,其子文件夹中的文件无效'''. 例如,覆盖“history”并不会覆盖“history/characters ”。
*To reduce mod size and improve mod compatibility, it is usually best to minimize the amount of folders that are replace_path.
* 为了缩小mod体积、增强mod兼容性,尽可能少用replace_path.
*replace_path is ignored when installing mod in the old Crusader Kings II\mod folder, hence why user mod folder must be used.
* 在旧版本中,replace_path在被安装到CK2安装目录/mod 时通常被忽视,因此必须放入使用者文件。(见[[创建模组#创建CK2的模组目录|CK2模组目录]])
*Unless you are sure you '''do''' need replace_path, you almost certainly don't.
* 除非你''' 确实''' 需要使用replace_path才使用,通常不用。
|replace_path = "history" <br/>
|replace_path = "history" <br />
replace_path = "history/characters"
replace_path = "history/characters"
|-
|-
|dependencies
|dependencies
|No
|No
|Tells the launcher that another mod has to be loaded before this one. The other mod will be loaded first, allowing the 2nd mod to override some files (otherwise the 1st mod would win). A dependency is not a hard requirement; you do not need a dependency loaded if the mod has one set. This is simply a way for the mod file to tell the launcher which files should be loaded first.
| 告诉启动器,在此mod之前必须加载另一个mod。另一个模组将首先加载,允许另一个模组覆盖某些文件(否则第一个模组将先加载)。一个dependencies不是必要的;如果mod有一个集,则不需要加载dependencies。这只是 .mod 文件告诉启动器应首先加载哪些文件的一种方式。<br />
|dependencies = { "Another Mod" "Yet Another Mod" }
如果dependencies里的mod的名称包含空格,则必须将其括在转义引号中。<code>"\"Mod with space in name\""</code>
|dependencies = { "MyMod" "\"Another Mod\"" }
|-
|-
|picture
|picture
|No
|No
|Image under mod folder to serve as banner for [[Steam Workshop]] (will be displayed as 268px × 268px JPEG)
| 模组文件夹下的图像可用作[[Steam 创意工坊]] 的展示图片。(将显示为 268 像素 × 268 像素 JPEG
|picture = "MyMod.jpg"
|picture = "MyMod.jpg"
|-
|-
|tags
|tags
|No
|No
|List of tags for [[Steam Workshop]]. Warning: don't forget quotes for tags that contain spaces.
|[[Steam 创意工坊]] 的标签列表。警告: 不要忘记包含空格的标签的引号。
|tags = { "Tag1" "Tag 2" }
| tags = { "Tag1" "Tag 2" }
|-
|-
|supported_checksums
|supported_checksums
|No
|No
|List of expected checksums for which scripting condition <code>supported_checksums</code> will evaluate to true. This can be used in [[event modding]] to display a warning to the player.
| 脚本条件将计算为true的预期校验和列表。这可以在[[事件模组制作]]中使用,以向玩家显示警告。<code>supported_checksums</code>
|supported_checksums = { ABCD EFGH }
|supported_checksums = { ABCD EFGH }
|-
|-
|}
|}


Below are some examples mod files, depending on the category of the mod:
以下是一些示例模组文件,具体取决于模组的类别:


===小型mod===
===小型mod===


 小 型 mod 更常见一些,为了保证和其它小型mod 的兼容性,请不要使用<code>user_dir</code>或者是<code>replace_path</code>。
 小 型mod 更常见一些,为了保证和其它小型mod的兼容性,请不要使用<code>user_dir</code>或者是<code>replace_path</code>。


<pre>
<pre>
第113行: 第114行:
===大型mod===
===大型mod===


Overhaul mods typically use <code>user_dir</code> as saves wouldn't be loadable outside of the mod anyway.
大型模组通常使用 <code>user_dir</code> 使保存内容无论如何都无法在开启此mod前加载。对于[[ 彻底转换指南| 总转化]] 模组, <code>replace_path</code> 用于完全覆盖在模组中没有意义的原版文件夹(histroy,flags等)。
For [[Total_conversion_guide|total conversion]] mods, <code>replace_path</code> can be used to completely ignore vanilla directories that don't make sense in the context of the mod (history, flags, ...)


<pre>
<pre>
第127行: 第127行:
===子mod===
===子mod===


 主mod 的子mod 通常用 <code>dependencies</code> 来覆盖主mod 的文件。
 主mod的子mod通常用 <code>dependencies</code> 来覆盖主mod的文件。


<pre>
<pre>
  name = "Sub Mod"
  name = "Sub Mod"
  path = "mod/SubMod"
  path = "mod/SubMod"
  dependencies = { "Main Mod" }
  dependencies = { "\"Main Mod\"" }
  picture = "SubMod.jpg"
  picture = "SubMod.jpg"
  tags = { "Mods" "Main Mod" }
  tags = { "Mods" "Main Mod" }
第139行: 第139行:
==游戏数据==
==游戏数据==


* [[Console commands]]于debug 非常有用
*[[ 控制台指令]] 于调试模组 非常有用
* [[Defines]], which allow to influence some hardcoded vanilla behaviors
*[[ 定义]] ,影响一些原版的硬编码行为
* [[Scopes]], [[conditions]], and [[commands]] used for [[scripting]]
*[[ 作用域]] [[ 条件]] ,和 [[ 指令]] 被用于[[ 脚本|脚本编写]]
* [[Modifiers]], used to influence calculations made by the game
*[[ 修正]], 用于影响游戏所做的计算
* [[Map modding|Map data]]
*[[ 地图模组制作| 地图数据]]


==游戏结构==
==游戏结构==


The game data is composed of hierarchy of folders, containing game files.
游戏数据是由包含游戏文件的文件夹及子文件夹的结构组成。


A mod follows the same folder structure as the base game, so that when loading the game the engine will combine files from vanilla and mod(s).
模组遵循与基础游戏相同的文件夹结构,因此在加载游戏时,引擎将合并来自原版和mod的文件。在大多数文件夹中,引擎将加载其中的所有文件,这允许mod添加新的定义(头衔,宗教等),而无需复制和修改原版文件。若要利用这一点,请务必了解如何在文件级别和定义级别加载脚本。
In most folders, the engine will load all the files within, which allows a mod to add new definitions (titles, religions, ...) without having to copy and modify vanilla files.
To make use of this, it is important to understand how the scripts are loaded both at file level and definition level.


The behavior when loading a mod is the following:
加载模组时的行为如下:
* Engine processes folders and files based on some hardcoded [[Troubleshooting#Loading|load order]].
* 引擎根据某些硬编码的[[ 故障排除| 加载顺序]] 处理文件夹和文件。
* If current folder is defined as <code>replace_path</code>, all vanilla files in that folder will be ignored, and only mod files will be loaded (if any).
* 如果将当前文件夹定义为 <code>replace_path</code> ,则该文件夹中的所有原版文件都将被忽略,并且只会加载mod文件(如果有)。
* If the mod folder and vanilla folder both contain files with same names, vanilla files will be ignored and mod version will be used.
* 如果 mod 文件夹和原版文件夹都包含同名的文件,则将忽略原版文件,并使用mod版本。
* Inside a given folder, the order in which files are processed is usually alphanumerical on combined vanilla and mod file names, though some folders may have a different behavior.
* 在给定的文件夹中,文件的处理顺序通常是字母数字的,合并了 vanilla mod 文件名,尽管某些文件夹可能具有不同的行为
* When encountering more than once the same definition (title, religion, decision, ...), the duplicate definition may:
* 在多次遇到相同的定义(头衔,宗教,决议等)时,重复的定义可能:
**be ignored (first definition wins)
** 被忽略(先加载的定义成为游戏内容)
**fully override the previous definition (last definition wins)
** 完全覆盖上一个定义(最后一个定义成为游戏内容)
**partially override the previous definition (definitions are merged/additive, which only makes sense if there is actually something to merge: hierarchy, list, etc.)
** 部分覆盖以前的定义(定义被合并/ 加法,这只有在实际有要合并的东西时才有意义:层次结构,列表等)
**coexist/break both (in which case duplicate IDs must be avoided)
** 两者共存/ 中断(在这种情况下,必须避免重复的ID)


Below is a list of CKII game files and folders, with associated modding guide, and loading behavior.
以下是[[王国风云II|CKII]]游戏文件和文件夹的列表,以及相关的模组指南和加载行为。


For loading behavior, the cell colours highlight whether the behaviour is the <span style="background-color:lightgreen">expected one</span>, <span style="background-color:gold">strange or requiring some attention</span>, or <span style="background-color:salmon">unexpected and to be avoided</span>.
对于加载行为,单元格颜色会突出显示行为是<span style="background-color:lightgreen"> 预期的行为</span> <span style="background-color:gold"> 奇怪的行为还是需要注意的行为</span> <span style="background-color:salmon"> 是意外的,还是需要避免的行为</span>


{| class = "wikitable"
{| class="wikitable"
!File/Folder
! 文件夹/ 文件
!What it contains
! 该文件包含什么
!How to mod
! 如何模组
!Loading behavior
! 加载行为
|-
|-
|.\'''common\'''
|.\'''common\'''
第182行: 第180行:
*static_modifiers.txt
*static_modifiers.txt
*technology.txt
*technology.txt
|General information
| 大致信息
*Defines Steam [[Achievements]]
* 定义[[ 成就|Steam成就]]
*POP, general, diplomatic, economic and military variables
*POP , 一般变量、外交变量、经济变量和军事变量
*Defines playable start- and end-date
* 定义可游玩的开始日期和结束日期
*Defines the displayed hints
* 定义显示的提示
*RGB code for each region
* 定义每个区域的 RGB 代码
*All difficulty, rank and standard modifiers
* 所有难度、等级和标准修饰符
*[[Technology]] data
*[[ 科技]] 数据
|<br/>
|<br />
[[Defines]]<br/>
[[Defines|定义]]<br />
 
<br /><br />[[Static modifiers|修正]]


<br/>
[[ 科技模组制作]]<br />
<br/>
| 不适用
[[Static modifiers]]<br/>
[[Technology modding]]<br/>
| N/A
|-
|-
|.\common\'''alternate_start\'''
|.\common\'''alternate_start\'''
|
|
|[[Alternate start modding]]
|[[ 另类开局模组制作]]
|{{sup|?}} Merge
|{{sup|?}} 合并。
|-
|-
|.\common\'''artifact_spawns\'''
|.\common\'''artifact_spawns\'''
|
|
|[[Artifact modding]]
|[[ 宝物模组制作]]
|style = "background-color:lightgreen"| Merge.
| style="background-color:lightgreen" | 合并。
|-
|-
|.\common\'''artifacts\'''
|.\common\'''artifacts\'''
| Definitions of [[artifact]]s
|[[ 宝物]] 的定义
|[[Artifact modding]]
|[[ 宝物模组制作]]
|style = "background-color:lightgreen"| Merge.
| style="background-color:lightgreen" | 合并。
|-
|-
|.\common\'''bloodlines\'''
|.\common\'''bloodlines\'''
|
| 血脉文件夹,所有的[[血脉]]都存储在这里。
|[[Bloodline modding]]
|[[ 血脉模组制作]]
|
|
|-
|-
|.\common\'''bookmarks\'''
|.\common\'''bookmarks\'''
|[[Bookmarks]] are configured here (scenarios/start dates)
| 剧本文件夹,所有的[[ 开局时间|剧本]] 都存储在这里。
|[[Bookmark modding]]
|[[ 剧本模组制作]]
|style = "background-color:lightgreen"| Merge. Bookmarks are listed chronologically in-game, whatever the order in files.
| style="background-color:lightgreen" | 合并。剧本在游戏中按时间顺序列出,无论文件中的顺序如何。
|-
|-
|.\common\'''buildings\'''
|.\common\'''buildings\'''
|[[Buildings]] folder, all buildings are stored here.
| 建筑文件夹,所有的[[ 地产|建筑]] 都存储在这里。
|[[Building modding]]
|[[ 建筑模组制作]]
|{{sup|?}} Merge
|{{sup|?}} 合并。
|-
|-
|.\common\'''cb_types\'''
|.\common\'''cb_types\'''
|[[Casus Belli]] folder, all Casus-belli are stored here.
| 宣战理由文件夹,所有的[[ 宣战理由]] 都存储在这里。
|[[Casus Belli modding]]
|[[ 宣战理由模组制作]]
|style = "background-color:gold"| Merge, but override of casus belli by re-using same name does not work (creates duplicate casus belli)
| style="background-color:gold" | 合并,但通过重复使用相同的名称来覆盖宣战理由不起作用。(创建重复的宣战理由文件)
|-
|-
|.\common\'''combat_tactics\'''
|.\common\'''combat_tactics\'''
|Combat [[tactics]] definitions.
| 作战战术文件夹,所有的[[ 作战战术]] 都存储在这里。
|[[Unit modding]]
|[[ 单位模组制作]]
|{{sup|?}} Merge
|{{sup|?}} 合并。
|-
|-
|.\common\'''council_positions\'''
|.\common\'''council_positions\'''
| Conditions for an A.I. councillor to adopt a certain category of voting behavior.
|AI内阁成员采取哪种类别的行为的规则。
|[[Councillor modding]]
|[[ 内阁成员模组制作]]
|{{sup|?}}
|{{sup|?}}
|-
|-
|.\common\'''council_voting\'''
|.\common\'''council_voting\'''
| A.I. rules for how councillors from a behavior category will vote
|AI在内阁中投票法律的规则
|[[Councillor modding]]
|[[ 内阁成员模组制作]]
|{{sup|?}}
|{{sup|?}}
|-
|-
|.\common\'''cultures\'''
|.\common\'''cultures\'''
|[[Cultures]] folder, all cultures are stored here.
| 文化文件夹,所有的[[ 文化]] 都存储在这里。
|[[Culture modding]]
|[[ 文化模组制作]]
|style = "background-color:lightgreen"| Merge. Since [[patch 2.4]] cultures are merged like religions, and a new culture may be added to a vanilla culture_group via a separate file.
| style="background-color:lightgreen" | 合并。 由于[[Patch 2.4|补丁2.4]] 文化像宗教一样合并,并且可以通过单独的文件将新的文化添加到原版文化组中。
|-
|-
|.\common\'''death\'''
| .\common\'''death\'''
|[[Death]] definitions
| 死亡原因文件夹,所有的[[ 死亡(消歧义)|死亡原因]] 都存储在这里。
|[[Death modding]]
|[[ 死亡模组制作]]
|
|
|-
|-
|.\common\'''death_text\'''
|.\common\'''death_text\'''
|Flavor text for succession screen
| 为继承屏幕添加死后评价
|[[Death modding]]
|[[ 死亡模组制作]]
|
|
|-
|-
|.\common\'''defines\'''
|.\common\'''defines\'''
|[[Defines]].
| 定义文件夹,所有的[[ 定义]] 都存储在这里。
|[[Defines]]
|[[ 定义]]
|{{sup|?}} Merge. Entries in files override common/defines.lua values.
|{{sup|?}} 合并。文件中的条目将覆盖common/defines.lua
|-
|-
|.\common\'''disease\'''
|.\common\'''disease\'''
|[[Diseases]] definitions.
| 疾病文件夹,所有的[[ 疾病]] 都存储在这里。
|[[Disease modding]]
|[[ 疾病模组制作]]
|{{sup|?}} Merge
|{{sup|?}} 合并。
|-
|-
|.\common\'''dynasties\'''
|.\common\'''dynasties\'''
|[[Dynasties]] folder, all dynasties are stored here.
| 家族文件夹,所有的[[ 家族]] 都存储在这里。
|[[Dynasty modding]].
|[[ 家族模组制作]]
|style = "background-color:gold"| Merge. Duplicate dynasties loaded before vanilla (i.e., <code>000_</code>  prefix) will overwrite dynasty shields. Duplicates loaded after (i.e., <code>z_</code>  prefix) will overwrite dynasty names. To overwrite both, use duplicate files, one with a preceding prefix and one with a succeeding prefix.
| style="background-color:gold" | 合并。在原版之前加载的重复家族将覆盖家族盾徽(i.e., <code>000_</code>  等前缀) 。之后加载的重复项 (i.e., <code>z_</code>  等前缀) 将覆盖家族名称。要覆盖两者,请使用重复的文件,一个具有前面的前缀,另一个具有后续前缀。
|-
|-
|.\common\'''event_modifiers\'''
|.\common\'''event_modifiers\'''
|Event_modifiers folder, all event modifiers are stored here
| 事件修正文件夹,所有的[[修正|事件修正]]都存储在这里。
|[[Modifiers]]
|[[ 修正]]
|style = "background-color:lightgreen"| Merge.
| style="background-color:lightgreen" | 合并。
|-
|-
|.\common\'''execution_methods\'''
|.\common\'''execution_methods\'''
|[[Execution]] methods
| 处决类型文件夹,所有的[[ 处决|处决类型]] 都存储在这里。
|[[Death modding]]
|[[Death modding|死亡模组制作]]
|{{sup|?}}
|{{sup|?}}
|-
|-
|.\common\'''game_rules\'''
|.\common\'''game_rules\'''
|[[Game rules]] definitions
| 游戏规则文件夹,所有的[[ 游戏规则]] 都存储在这里。
|[[Game rules modding]]
|[[ 游戏规则模组制作]]
|style = "background-color:lightgreen"| Merge. The rules are displayed in UI based on order of files (alphanumerical on file name), then order of rules within the file.
| style="background-color:lightgreen" | 合并。规则根据文件的顺序(文件名上的字母数字)和文件中的规则顺序显示在 UI 中。
|-
|-
|.\common\'''government_flavor\'''
|.\common\'''government_flavor\'''
|[[Government]] naming definitions
| 政体定义文件夹,所有的[[ 政体|政体定义]] 都存储在这里。
|[[Government modding]]
|[[ 政体模组制作]]
|{{sup|?}}
|{{sup|?}}
|-
|-
|.\common\'''governments\'''
|.\common\'''governments\'''
|[[Government]] definitions
| 政体文件夹,所有的[[ 政体]] 都存储在这里。
|[[Government modding]]
|[[ 政体模组制作]]
|style = "background-color:lightgreen"|Merge. It is possible to define governments of the same government group in different files.
| style="background-color:lightgreen" | 合并。可以在不同的文件中定义同一政府组的政府。
|-
|-
|.\common\'''graphicalculturetypes\'''
|.\common\'''graphicalculturetypes\'''
|Graphicalculturetypes folder, all graphical culture types are stored here
| 文化肤色文件夹,所有的[[文化|文化肤色]]都存储在这里。
|
|
|{{sup|?}} Merge
|{{sup|?}} 合并。
|-
|-
|.\common\'''heir_text\'''
|.\common\'''heir_text\'''
|Flavor text for succession screen
| 为继承屏幕添加继承人评价
|[[Death modding]]
|[[Death modding|死亡模组制作]]
|
|
|-
|-
|.\common\'''holding_types\'''
|.\common\'''holding_types\'''
|Conditions for being allowed to build each holding type.
| 地产类型文件夹,所有的[[地产|地产类型]]都存储在这里。
|[[Government modding]]
|[[Government modding|政体模组制作]]
|{{sup|?}}. It is not possible to add new holding types.
|{{sup|?}}. 无法添加新的地产类型。
|-
|-
|.\common\'''job_actions\'''
|.\common\'''job_actions\'''
|Defines [[councillors]] actions
| 内阁成员行为文件夹,所有的[[ 内阁]] 成员行为都存储在这里。
|[[Councillor modding]]
|[[Councillor modding|内阁成员模组制作]]
|style = "background-color:lightgreen"| Merge.
| style="background-color:lightgreen" | 合并。
|-
|-
|.\common\'''job_titles\'''
|.\common\'''job_titles\'''
|Defines councillors titles
| 内阁职务文件夹,所有的[[内阁]]职务都存储在这里。
|[[Councillor modding]]
|[[ 内阁成员模组制作]]
|{{sup|?}}
|{{sup|?}}
|-
|-
|.\common\'''landed_titles\'''
|.\common\'''landed_titles\'''
|Landed_titles folder, all landed titles are stored here.
| 头衔文件夹,所有的[[头衔]]都存储在这里。
|[[Title modding]]
|[[ 头衔模组制作]]
|style = "background-color:lightgreen"| Merge. Merging behaviour is "complicated and might not have been designed that way intentionally"<ref>[[Forum:774248/page-14#post-19100145]]</ref>
| style="background-color:lightgreen" | 合并。合并行为“很复杂,可能不是故意设计的”<ref>[[Forum:774248/page-14#post-19100145]]</ref>
|-
|-
|.\common\'''laws\'''
|.\common\'''laws\'''
|
|
|[[Law modding]]
|[[ 法律模组制作]]
|style = "background-color:gold"| Merge. A law with the same name as an existing law will append conditions to the allow section, but not the potential section.
| style="background-color:gold" | 合并。与现有法律同名的法律将在允许部分附加条件,但不会将潜在部分附加条件。
|-
|-
|.\common\'''mercenaries\'''
|.\common\'''mercenaries\'''
|[[Mercenaries]] folder, all mercenaries are stored here
| 佣兵文件夹,所有的[[ 雇佣兵|佣兵]] 都存储在这里。
|
|
|{{sup|?}} Merge
|{{sup|?}} 合并。
|-
|-
|.\common\'''minor_titles\'''
| .\common\'''minor_titles\'''
|Minor_titles folder, all minor (i.e. honorary) titles are stored here
| 荣誉头衔文件夹,所有的[[荣誉头衔]]都存储在这里。
|[[Minor title modding]]
|[[ 荣誉头衔模组制作]]
|style = "background-color:gold"| Cannot be overridden, attempts to do so will result in multiple minor titles with the same tags, like traits
| style="background-color:gold" | 无法覆盖,尝试这样做将导致多个荣誉头衔具有相同的tag,如特质
|-
|-
|.\common\'''modifier_definitions\'''
|.\common\'''modifier_definitions\'''
|Defines dynamically defined modifiers, in particular special [[units]] modifiers.
| 定义动态定义的修饰符,特别是特殊[[ 战争|单位]] 的修饰符。
|[[Unit modding]]
|[[ 单位模组制作]]
|{{sup|?}} Merge
|{{sup|?}} 合并。
|-
|-
|.\common\'''nicknames\'''
|.\common\'''nicknames\'''
|[[Nicknames]] folder, all nicknames are stored here
| 称号文件夹,所有的[[ 称号]] 都存储在这里。
|
|[[称号模组制作]]
|style = "background-color:lightgreen"| Merge.
| style="background-color:lightgreen" | 合并。
|-
|-
|.\common\'''objectives\'''
|.\common\'''objectives\'''
|[[Objectives]] folder, all objectives (i.e. ambitions, factions, and plots) are stored here.
| 目标文件夹,所有的[[ 目标]] 都存储在这里。
|[[Objective modding]]
|[[ 目标模组制作]]
|{{sup|?}} Merge
|{{sup|?}} 合并。
|-
|-
|.\common\'''offmap_powers\'''
|.\common\'''offmap_powers\'''
*policies\
*policies\
*statuses\
*statuses\
|Defines nations not represented on the map, but with a significant influence over it.
| 定义地图外政权的文件夹。
|[[Offmap power modding]]
|[[Offmap power modding|地图外政权模组制作]]
|{{sup|?}} Merge. Does NOT require [[Jade Dragon]] DLC.
|{{sup|?}} 合并。不需要[[ 碧玉之龙]]DLC
|-
|-
|.\common\'''on_actions\'''
|.\common\'''on_actions\'''
|On_actions folder, all on_actions are stored here
| On_actions 文件夹,所有的on_actions文件都存储在这里。
|[[Event modding]]
|[[ 事件模组制作]]
|style = "background-color:lightgreen"| Merge. Since [[patch 2.4]] on_actions are merged, with new events being added to the previous list for a particular on_action, instead of replacing the list.
| style="background-color:lightgreen" | 合并。由于[[Patch 2.4|补丁 2.4]] on_actions 被合并,新事件被添加到特定on_action的先前列表中,而不是替换列表。
|-
|-
|.\common\'''opinion_modifiers\'''
|.\common\'''opinion_modifiers\'''
|[[Opinion]] modifiers folder, all opinion modifiers are stored here
| 好感修正文件夹,所有的[[ 修正|好感修正]] 都存储在这里。
|[[Modifiers]]
|[[ 修正]]
|{{sup|?}} Merge
|{{sup|?}} 合并。
|-
|-
|style = "background-color:lightgrey"|.\common\'''province_setup\'''
| style="background-color:lightgrey" |.\common\'''province_setup\'''
|style = "background-color:lightgrey"|Deprecated since [[patch 3.0]].
| style="background-color:lightgrey" |[[patch 3.0]] 后废弃
|style = "background-color:lightgrey"|
| style="background-color:lightgrey" | 不适用
|style = "background-color:lightgrey"|
| style="background-color:lightgrey" | 不适用
|-
|-
|.\common\'''religion_features\'''
| .\common\'''religion_features\'''
|
| 宗教特性文件夹,所有的[[原始宗教|宗教特性]]都存储在这里。
|[[Religion modding]]
|[[Religion modding|宗教模组制作]]
|style = "background-color:gold"|{{sup|?}} Merge, but features with the same key get duplicated
| style="background-color:gold" |{{sup|?}} 合并,但具有相同键的功能会重复。
|-
|-
|.\common\'''religion_modifiers\'''
|.\common\'''religion_modifiers\'''
|Religion_modifiers folder, all religion modifiers are stored here.
| 宗教修正文件夹,所有的[[修正|宗教修正]]都存储在这里。
|[[Modifiers]]
|[[ 修正]]
|{{sup|?}} Merge
|{{sup|?}} 合并。
|-
|-
|.\common\'''religions\'''
|.\common\'''religions\'''
|Religions folder, all religions are stored here.
| 宗教文件夹,所有的宗教都存储在这里。
|[[Religion modding]] <br/>
|[[ 宗教模组制作]] <br />
|style = "background-color:lightgreen"| Merge. Vanilla religions can be overridden, without needing to duplicate the whole religion group. Restrictions: need to define reformed religion before the non-reformed.
| style="background-color:lightgreen" | 合并。原版宗教可以被覆盖,而不需要复制整个宗教组。限制:需要在未改革宗教之前定义改革宗教。
|-
|-
|.\common\'''religious_titles\'''
| .\common\'''religious_titles\'''
|Religious_titles folder, all religious titles are stored here
| 宗教头衔文件夹,所有的[[头衔|宗教头衔]]都存储在这里。
|
|
|{{sup|?}} Merge
|{{sup|?}} 合并。
|-
|-
|.\common\'''retinue_subunits\'''
|.\common\'''retinue_subunits\'''
|[[Retinue]] subunits folder, all retinue subunits are stored here
| 近卫军单位文件夹,所有的[[ 近卫军|近卫军单位]] 都存储在这里。
|
|
|style = "background-color:gold"|{{sup|?}} Merge, but retinues with the same key get duplicated
| style="background-color:gold" |{{sup|?}} 合并,但具有相同密钥的随从被复制。
|-
|-
|.\common\'''save_conversion\'''
| .\common\'''save_conversion\'''
|
|
|[[Save game compatibility]]
|[[ 游戏存档兼容性]]
|{{sup|?}} 
|{{sup|?}}
|-
|-
|.\common\'''scripted_effects\'''
|.\common\'''scripted_effects\'''
|
|
|[[Scripted effect]]s
|[[ 脚本]]
|{{sup|?}} Merge
|{{sup|?}} 合并。
|-
|-
|.\common\'''scripted_score_value\'''
|.\common\'''scripted_score_value\'''
|
|
|[[Scripted score value]]
|[[ 脚本分数值]]
|{{sup|?}} Merge
|{{sup|?}} 合并。
|-
|-
|.\common\'''scripted_triggers\'''
|.\common\'''scripted_triggers\'''
|
|[[Scripted trigger]]s
|[[ 脚本|脚本触发器]]
|style = "background-color:gold"| Merge, but scripted triggers with same name append their conditions rather than replacing the original one.
| style="background-color:gold" | 合并,但具有相同名称的脚本化触发器会附加其条件,而不是替换原始条件。
|-
|-
|.\common\'''societies\'''
|.\common\'''societies\'''
| Definition of [[societies]]
| 社团文件夹,所有的[[ 社团]] 都存储在这里。
|[[Society modding]]
|[[ 社团模组制作]]
|style = "background-color:gold"| Merge, but override of societies by re-using same name does not work (creates duplicate societies)
| style="background-color:gold" |Merge ,但通过用相同名称覆盖一个社团不起作用(创建重复的社团)。
|-
|-
|.\common\'''special_troops\'''
|.\common\'''special_troops\'''
|Special [[units]] definitions
| 特殊单位文件夹,所有的[[ 战争|特殊单位]] 都存储在这里。
|[[Unit modding]]
|[[ 单位模组制作]]
|{{sup|?}} Merge
|{{sup|?}} 合并。
|-
|-
|style = "background-color:lightgrey"|.\common\'''stories\'''
| style="background-color:lightgrey" |.\common\'''stories\'''
|style = "background-color:lightgrey"|Not used.
| style="background-color:lightgrey" | 废弃的
|style = "background-color:lightgrey"|
| style="background-color:lightgrey" | 不适用
|style = "background-color:lightgrey"|N/A
| style="background-color:lightgrey" | 不适用
|-
|-
|.\common\'''succession_voting\'''
|.\common\'''succession_voting\'''
|
| 继承投票规则及AI继承投票行为规则
|[[Succession modding]]
|[[ 继承模组制作]]
|{{sup|?}} Merge
|{{sup|?}} 合并。
|-
|-
|.\common\'''trade_routes\'''
|.\common\'''trade_routes\'''
|[[Trade route]] definitions.
| 贸易路线文件夹,所有的[[ 贸易区|贸易路线]] 都存储在这里。
|[[Trade route modding]]
|[[ 贸易路线模组制作]]
|{{sup|?}}
|{{sup|?}}
|-
|-
|.\common\'''traits\'''
|.\common\'''traits\'''
|[[Traits]] folder, all traits are stored here.
| 特质文件夹,所有的[[ 特质]] 都存储在这里。
|[[Trait modding]]
|[[ 特质模组制作]]
|style = "background-color:gold"| Merge, but traits with same name will co-exist, and generated characters may get both versions of the trait at the same time. The last definition gets assigned to a character when using commands.
| style="background-color:gold" | 合并,但具有相同名称的特质将共存,并且生成的角色可以同时获得两种特质。使用命令时,最后一个定义将分配给角色。
|-
|-
|.\common\'''tributary_types\'''
|.\common\'''tributary_types\'''
|[[Tributary]] relationship definitions.
| 朝贡关系文件夹,所有的[[ 宣战理由|朝贡关系]] 都存储在这里。
|[[Tributary modding]]
|[[ 朝贡类型模组制作]]
|{{sup|?}}
|{{sup|?}}
|-
|-
|.\common\'''triggered_modifiers\'''
|.\common\'''triggered_modifiers\'''
|Defines global modifiers that trigger under certain conditions
| 定义在特定条件下触发的全局修饰符。
|[[Triggered modifiers]]
|[[ 修正|Triggered modifiers]]
|{{sup|?}} Merge
|{{sup|?}} 合并。
|-
|-
|.\'''connectui\'''
|.\'''connectui\'''
| Appears to be leftover interface for the discontinued Paradox Connect service (used in older Clausewitz games CK2 is based on).
| 似乎是已停止使用的Paradox Connect 服务的剩余接口(用于克劳塞维茨引擎开发的较旧的游戏如CK2)。
| Unusable
| 废弃的
|
| 不适用
|-
|-
|.\'''decisions\'''
|.\'''decisions\'''
|[[Decisions]] folder, all decisions are stored here
| 决议文件夹,所有的[[ 决议]] 都存储在这里。
|[[Decision modding]]
|[[ 决议模组制作]]
|style = "background-color:gold"| Merge, but override of decision by re-using same name does not work (breaks the decision effect, that does nothing)
| style="background-color:gold" | 合并, 但通过重用相同名称覆盖决策不起作用(破坏决策效果,这不执行任何操作)。
|-
|-
|.\'''dlc\'''
|.\'''dlc\'''
|Contains DLC information and zipped content files
| 包含 DLC 信息和压缩内容文件
|[[DLC files]]
|[[ 可下载内容]]
|N/A
| 不适用
|-
|-
|.\'''dlc_metadata\'''
|.\'''dlc_metadata\'''
|?
|
|
|
|?
|
|-
|-
|.\'''eu4_converter\'''
|.\'''eu4_converter\'''
|[[Europa Universalis 4 Save Converter]] folder, all files related to the EUIV converter are stored here.
|EU4转档器文件夹,所有的[[ 《欧陆风云IV》转档器|EU4转档器]] 文件都存储在这里。
Note: vanilla files were moved inside ''/dlc/dlc030.zip''
|[[EU4 转档器模组制作]]
|[[EU4 Converter modding]]
|{{sup|?}}
|{{sup|?}}
|-
|-
|.\'''events\'''
|.\'''events\'''
|Events folder, all events are stored here.
| 事件文件夹,所有的[[事件]]都存储在这里。
|[[Event modding]]
|[[ 事件模组制作]]
|style = "background-color:gold"| Merge. If redefining an event in a file loaded alphabetically after the original file, the event will be fully overridden.
| style="background-color:gold" | 合并,如果在原始文件之后按字母顺序加载的文件中重新定义事件,则该事件将被完全覆盖。
Developers have discouraged this practice, as that engine behavior is not guaranteed to remain in the future (source ?)
开发人员不鼓励这种做法,因为该引擎行为不能保证在将来保留(来源?)
|-
|-
|.\'''gfx\'''
| .\'''gfx\'''
*ambitions\
* ambitions\
*characters\
*characters\
*coats_of_arms\
*coats_of_arms\
*cursors\
*cursors\
*eurfonts\
*eurfonts\
*event_pictures\
* event_pictures\
*flags\
*flags\
*fonts\
*fonts\
第520行: 第516行:
*titles\
*titles\
*traits\
*traits\
|Graphics folder, all graphics are stored here.
| 图像文件夹,所有的[[图形模组制作|图像]]都存储在这里。
|[[Graphics modding]]
|[[ 图形模组制作]]
Graphics are mapped to a logical name (GFX_xxx) inside .\interface\*.gfx files <br/>
图形映射到 .\interface\*.gfx 文件中
'''Warning''': a missing flag for a title in flags\ will cause wrong flags to appear for most titles, due to a shift.
 
的逻辑名称 (GFX_xxx) <br />''' 警告''' :flags\ 中缺少头衔的标志将导致大多数头衔出现错误的标志,这是由于偏移
|
|
|-
|-
|.\'''history\'''
|.\'''history\'''
|Historical data for characters, titles, provinces and wars for the possible start dates. This is a likely the text export of an internal database, which is sometime mentioned in the patch notes.<ref>http://www.ckiiwiki.com/Patch_2.0#Database</ref>
| 字符、标题、省份和战争的历史数据,以及可能的开始日期。这可能是内部数据库的文本导出,有时在补丁说明中会提到。<ref>https://ck2.paradoxwikis.com/Patch_2.0#Database</ref>
|[[History modding]]
|[[ 历史模组制作]]
|N/A
| 不适用
|-
|-
|.\history\'''characters\'''
| .\history\'''characters\'''
|Historical characters, optionally associated to a dynasty from \common\dynasties\ folder.
| 历史人物,可选择与\common\dynasties\ 文件夹中的王朝相关联。
|[[Character modding]]
|[[ 角色模组制作]]
|style = "background-color:gold"| {{sup|?}} Merge. Duplicate character IDs break the character history and must be avoided.
| style="background-color:gold" |{{sup|?}} 合并。重复的角色ID会破坏角色历史记录,必须避免。
|-
|-
|style = "background-color:lightgrey"|.\history\'''diplomacy\'''
| style="background-color:lightgrey" |.\history\'''diplomacy\'''
|style = "background-color:lightgrey"|Not used
| style="background-color:lightgrey" | 未使用
|style = "background-color:lightgrey"|N/A
| style="background-color:lightgrey" | 不适用
|style = "background-color:lightgrey"|N/A
| style="background-color:lightgrey" | 不适用
|-
|-
|.\history\'''offmap_powers\'''
|.\history\'''offmap_powers\'''
|History of offmap powers (holder, status, ...)
| 地图外政权的历史(持有者,地位等)
|[[Offmap power modding]]
|[[ 地图外政权模组制作]]
|{{sup|?}} Merge
|{{sup|?}} 合并。
|-
|-
|.\history\'''provinces\'''
|.\history\'''provinces\'''
|History of provinces (holdings built, change of culture or religion)
| 省份历史(地产,文化或宗教的变化)
|[[Province modding]]
|[[ 省份模组制作]]
|{{sup|?}} Merge
|{{sup|?}} 合并。
|-
|-
|.\history\'''technology\'''
|.\history\'''technology\'''
|Initial technology of provinces, depending on the start date.
| 各省的初始技术,取决于开始日期。
|[[Technology modding]]
|[[ 科技模组制作]]
|{{sup|?}}
|{{sup|?}}
|-
|-
|.\history\'''titles\'''
|.\history\'''titles\'''
|History of titles (list of successive holders)
| 头衔历史(持有者名单)
|Note: titles that should be deactivated at game start (ex: reformed religion heads) must have an history file that disables the title.
|Note: titles that should be deactivated at game start (ex: reformed religion heads) must have an history file that disables the title.
|{{sup|?}} Merge
|{{sup|?}} 合并。
|-
|-
|.\history\'''wars\'''
|.\history\'''wars\'''
|Important on-going wars (attacker, defender, Casus Belli, war score, ...), usually for historical bookmarks.
| 重要的正在进行的战争(进攻者,防守者,宣战理由,战争得分等),通常用于历史剧本。
|
|
|{{sup|?}} Merge
|{{sup|?}} 合并。
|-
|-
|.\'''interface\'''
|.\'''interface\'''
*generalstuff.gfx
*generalstuff.gfx
*sound.sfx
*sound.sfx
|Interface graphics
| 界面图形
|[[Interface modding]]
|[[ 界面模组制作]]
*[[Sound modding]]
*[[ 声音模组制作]]
|style = "background-color:gold"| 
| style="background-color:gold" | 
* Loading of *.gfx files is in alphanumerical order. Last spriteType definition loaded overrides previous ones with same name, if any (i.e. use zz_ file prefix to override vanilla sprites).
*<nowiki>*.gfx 文件的加载按字母数字顺序排列。加载的最后一个 spriteType 定义将覆盖具有相同名称的先前定义(如果有)(即使用zz_文件前缀来覆盖普通精灵)。</nowiki>
* Only '''sound.sfx''' is taken into account, other .sfx files are ignored.
* 仅考虑 '''sound.sfx''' ,忽略其他 .sfx 文件。
|-
|-
|.\interface\'''coat_of_arms\'''
|.\interface\'''coat_of_arms\'''
|
|[[Coats of arms modding]]
|[[ 盾徽模组制作]]
|style = "background-color:gold"| Coat of arms definitions can be split across multiple files. No support for appending existing definitions from a different file.
| style="background-color:gold" | 盾徽定义可以拆分到多个文件中。不支持从其他文件追加现有定义。
|-
|-
|.\interface\'''portrait_offsets\'''
|.\interface\'''portrait_offsets\'''
| .txt files with external offsets for portrait frames
|.txt 带有肖像框架外部偏移的文件
|[[Portrait modding]]
|[[ 肖像模组制作]]
|
|-
|-
|.\interface\'''portrait_properties\'''
|.\interface\'''portrait_properties\'''
| Dynamic rules to select portrait properties values
| 用于选择纵向属性值的动态规则
|[[Portrait modding]]
|[[ 肖像模组制作]]
| {{sup|?}}
|{{sup|?}}
|-
|-
|.\interface\'''portrait\'''
|.\interface\'''portrait\'''
| Definitions of spriteType and portraitType elements for portraits.
| 肖像的spriteType和portraitType元素的定义。
|[[Portrait modding]]
|[[ 肖像模组制作]]
| Merge
| 合并。
|-
|-
|.\'''launcher\'''
|.\'''launcher\'''
|Launcher graphics and configuration
| 启动器图像和配置
|
|
|N/A
| 不适用
|-
|-
|.\'''localisation\'''
|.\'''localisation\'''
|All text data for things like country names and event description, has options for other languages
| 所有本地化国家/地区名称和事件描述等内容的所有文本数据。
|[[Localisation]]
|[[ 本地化]]
|style = "background-color:lightgreen"|  Full override. If duplicates are in different files, first file loaded wins (i.e. use 00_ file prefix to override vanilla keys). If in same file, last duplicate in file wins. '''Warning''': files must end with '''.csv''' extension, or they will not be taken into account.
| style="background-color:lightgreen" | 完全覆盖。如果重复项位于不同的文件中,则首先加载的文件优先(即使用 00_ 文件前缀覆盖原始键)。如果在同一文件中,则文件中的最后一个重复项优先。''' 警告''' :文件必须以'''.csv''' 扩展名结尾,否则将不加载。
|-
|-
|.\localisation\'''customizable_localisation\'''
|.\localisation\'''customizable_localisation\'''
| Custom [[Localisation#Commands|localisation commands]] definitions
| 习惯的[[ 本地化| 本地化命令]] 定义
|[[Localisation#Custom commands]]
|[[ 本地化]]
|{{sup|?}} Merge.
|{{sup|?}} 合并
|-
|-
|.\'''map\'''
|.\'''map\'''
第621行: 第618行:
*terrain.bmp
*terrain.bmp
*topology.bmp
*topology.bmp
*trees.bmp
* trees.bmp
*world_normal_height.bmp
*world_normal_height.bmp
|Map settings, province shapes, continents, regions etc.
| 地图文件夹,所有的[[地图模组制作|地图数据]]都存储在这里。
|[[Map modding]]
|[[ 地图模组制作]]
|N/A
| 不适用
|-
|-
|.\'''map\statics'''
|.\'''map\statics'''
|Map external frame size, and positions of fixed 3D map elements (wonders, etc.)
| 地图外部框架大小,以及固定3D地图元素的位置(奇观等)。
|[[Map modding]]
|[[Map modding|地图模组制作]]
|
|
|-
|-
|.\'''map\terrain'''
|.\'''map\terrain'''
|
|
|[[Map modding]]
|[[Map modding|地图模组制作]]
|
|
|-
|-
|.\'''mod\'''
|.\'''mod\'''
|Dummy mod folder, do not store mods here, use local mod folder
| 虚拟mod文件夹,不要在这里放mod。
|[[Mod file]]
|[[ 模组制作]]
|style = "background-color:salmon"| Breaks mods, as configurations like replace_path are ignored.
| style="background-color:salmon" | 破坏模组,因为像replace_path这样的配置被忽略。
|-
|-
|.\'''music\'''
|.\'''music\'''
|[[Music]] used by the game
| 音乐文件夹,所有的[[ 音乐]] 都存储在这里。
|[[Music modding]]
|[[ 音乐模组制作]]
|{{sup|?}} All .txt files song elements are loaded.
|{{sup|?}} 加载所有.txt 文件歌曲元素。
|-
|-
|.\'''sound\'''
|.\'''sound\'''
|All sounds except music
| 声音文件夹,所有的[[声音]]都存储在这里。
|
|
|{{sup|?}}
|{{sup|?}}
|-
|-
|.\'''tutorial\'''
|.\'''tutorial\'''
|Tutorial configuration
| 教程设置
|
|
|{{sup|?}}
|{{sup|?}}
第660行: 第657行:


==具体指南==
==具体指南==
{{hatnote|Only includes guides not already linked in the "How to mod" column above or otherwise.}}
{{hatnote| 仅包含上面或以其他方式“如何修改”列中尚未链接的指南。}}


* [[Troubleshooting]] - 在你的mod中debug
*[[ 故障排除]] - 在你的mod中debug
* [[Save-game editing]] - 如何更改保存游戏
*[[ 编辑游戏存档]] - 如何更改保存游戏




* [[Patch 2.4 mod compatibility guide]] - 如何从 [[patch 2.3.6]] 移植到 [[patch 2.4.X]]
*[[Patch 2.4 mod compatibility guide]] - 如何从 [[patch 2.3.6]] 移植到 [[patch 2.4.X]]
* [[Patch 2.5 mod compatibility guide]] - 如何从 [[patch 2.4.5]] 移植到 [[patch 2.5.X]]
*[[Patch 2.5 mod compatibility guide]] - 如何从 [[patch 2.4.5]] 移植到 [[patch 2.5.X]]
* [[Patch 2.6 mod compatibility guide]] - 如何从[[patch 2.5.2]] 移植到 [[patch 2.6.X]]
*[[Patch 2.6 mod compatibility guide]] - 如何从[[patch 2.5.2]] 移植到 [[patch 2.6.X]]
* [[Patch 2.7 mod compatibility guide]] - 如何从m [[patch 2.6.3]] 移植到 [[patch 2.7.X]]
*[[Patch 2.7 mod compatibility guide]] - 如何从m [[patch 2.6.3]] 移植到 [[patch 2.7.X]]
* [[Patch 2.8 mod compatibility guide]] - 如何从 [[patch 2.7.2]] 移植到 [[patch 2.8.X]]
*[[Patch 2.8 mod compatibility guide]] - 如何从 [[patch 2.7.2]] 移植到 [[patch 2.8.X]]
* [[Patch 3.0 mod compatibility guide]] - 如何从 [[patch 2.8.3.2]] 移植到 [[patch 3.0.X]]
*[[Patch 3.0 mod compatibility guide]] - 如何从 [[patch 2.8.3.2]] 移植到 [[patch 3.0.X]]
* [[Patch 3.1 mod compatibility guide]] - 如何从 [[patch 3.0.X]] 移植到 [[patch 3.1.X]]
*[[Patch 3.1 mod compatibility guide]] - 如何从 [[patch 3.0.X]] 移植到 [[patch 3.1.X]]
* [[Merging guide]] - how to merge mod files with a new vanilla patch
*[[ 合并指南]] - 如何将mod文件与新的原版补丁合并




* [[Total conversion guide]] - Creating a total conversion mod
*[[ 彻底转换指南]] - Creating a total conversion mod
* [[Creating a mod exe installer guide]] - Advanced guide for creating a Windows installer
*[[ 模组安装程序创建指南]] - Advanced guide for creating a Windows installer


==工具与实用程序==
==工具与实用程序==


{{hatnote|这些是modder用的实用工具。 玩家使用的请看[[Mods#Utilities|utilities]].}}
{{hatnote|这些是modder用的实用工具。 玩家使用的请看[[Mods# 实用工具| 实用工具]].}}


* [http://notepad-plus-plus.org/ Notepad++] - 修改文件用的编辑器,比notepad要好。
*[http://notepad-plus-plus.org/ Notepad++] - 修改文件用的编辑器,比notepad要好。
* [[forum:745679|Notepad++ language file for CKII]] - 对于阅读代码十分友好。
*[[forum:745679|Notepad++ language file for CKII]] - 对于阅读代码十分友好。
* [[The Validator]] - 文件查错。
*[[The Validator]] - 文件查错。
* [[EU4:JoroDox mod making tool]] / [[forum:Tool-JoroDox-mod-making-tool.832866|Forum thread]] - 查看mod文件和创建3d模型。
*[[EU4:JoroDox mod making tool]] / [[forum:Tool-JoroDox-mod-making-tool.832866|Forum thread]] - 查看mod文件和创建3d模型。
* [[forum:651648|CK2 Cultures Parser]]
*[[forum:651648|CK2 Cultures Parser]]
* [[forum:597290|Coat of Arms Builder]]
*[[forum:597290|Coat of Arms Builder]]
* [[Portrait Builder]] - 预览人物特征的工具。
*[[Portrait Builder]] - 预览人物特征的工具。
* [[forum:686024|Scenario Editor]]
*[[forum:686024|Scenario Editor]]
* [[Titular Title Generator]]
*[[Titular Title Generator]]
* [http://www.textfixer.com/tools/alphabetize-text-words.php Text Fixer] - 按字母排序你的localisation 文件。 (alphabetize your localisation file)
*[http://www.textfixer.com/tools/alphabetize-text-words.php Text Fixer] - 按字母排序你的localisation 文件。
* [[forum:984905|Paradox Province Color Picker]]
*[[forum:984905|Paradox Province Color Picker]]


==高级技巧==
==高级技巧==


*For the bigger mods using a source control management tool (Git, ...), it is handy to create a symbolic link between CKII mod folder and the working directory of the local repository, especially if the mod also has sub-mods. Note that you'll still need to copy the .mod file(s) manually, but they rarely change. Run the following command from the parent directory of main git folder, replacing:
* 对于使用源代码管理工具(Git,...... )的大型mod,在CKII mod 文件夹和本地存储库的工作目录之间创建符号链接非常方便,特别是如果mod也有子mods。请注意,您仍然需要手动复制 .mod 文件,但它们很少更改。从主git文件夹的父目录运行以下命令,替换:
** <mod_path_name> by the value of <code>path</code> attribute from .mod file
**<mod_path_name> 填写.mod文件的 <code>path</code> 里的mod名称
** <git_mod_folder> by the name of the sub-folder that contain mod data (folders common, decisions, events, etc...)
**<git_mod_folder> 填写mod的子文件夹(common文件夹、decisions文件夹、event文件夹等)的名称
<pre>
<pre>
mklink /J "%HOMEDRIVE%%HOMEPATH%\Documents\Paradox Interactive\Crusader Kings II\mod\<mod_path_name>" ".\<git_mod_folder>"
mklink /J "%HOMEDRIVE%%HOMEPATH%\Documents\Paradox Interactive\Crusader Kings II\mod\<mod_path_name>" ".\<git_mod_folder>"
第706行: 第703行:
===MOD调试===
===MOD调试===
 毫无疑问,更多隐藏的控制台指令(在控制台输入help也不会显示的内容)对MOD测试会起到巨大的作用。
 毫无疑问,更多隐藏的控制台指令(在控制台输入help也不会显示的内容)对MOD测试会起到巨大的作用。
* observe - 让你进入观察者模式。此时你不再控制任何特定的角色——这会让游戏不受打断地自动运行。同时,所有隐藏特质、秘密信仰等对观察者都是可见的。
*observe - 让你进入观察者模式。此时你不再控制任何特定的角色——这会让游戏不受打断地自动运行。同时,所有隐藏特质、秘密信仰等对观察者都是可见的。
* run <filename.txt> - 直接运行特定脚本。脚本将从当前玩家控制角色的作用域开始执行。这个功能有助于测试复杂的脚本——你可以直接打开一个窗口编辑脚本,保存,重新载入,调整——省下重新打开游戏的时间。
*run <filename.txt> - 直接运行特定脚本。脚本将从当前玩家控制角色的作用域开始执行。这个功能有助于测试复杂的脚本——你可以直接打开一个窗口编辑脚本,保存,重新载入,调整——省下重新打开游戏的时间。
* reloadevents - 重新载入和编译每一个事件(可能花费一会时间,取决于你的硬件)。对调试事件很有帮助,同样为你省下重新打开游戏的时间。
*reloadevents - 重新载入和编译每一个事件(可能花费一会时间,取决于你的硬件)。对调试事件很有帮助,同样为你省下重新打开游戏的时间。
* reloadloc - 重新载入本地化文件,有助于确定文本是否显示在正确的位置上。
*reloadloc - 重新载入本地化文件,有助于确定文本是否显示在正确的位置上。


 更多[[控制台指令]]可以在首页找到,用于实现杀掉某人之类的特定功能,这些对MOD测试同样必不可少。
 更多[[控制台指令]]可以在首页找到,用于实现杀掉某人之类的特定功能,这些对MOD测试同样必不可少。
第720行: 第717行:
==更多==
==更多==


*[[Mods]]
*[[ 模组]]
*[[Modding suggestions]]
*[[Modding suggestions]]


第729行: 第726行:
{{ModdingNavbox}}
{{ModdingNavbox}}
{{ModdingGuidesNavbox}}
{{ModdingGuidesNavbox}}
[[Category:Modding|#]]
[[Category: 模组制作|#]]
[[en:Modding]]

2022年5月4日 (三) 14:58的最新版本

Modding, 或称为“模组制作”,是修改基本游戏(即原版)的行为, 无论是供个人使用,或者是公开发布给其他玩家,比如发布到Steam创意工坊

就所有p社游戏而言,ck2的模组制作有很大开放性,可以很显著的延伸游戏的内容,增强游戏的可玩性。 mod制作者的动机各不相同:更好的翻译成母语,更多的事件及决议,更棒的地图,亦或游戏整体大修改等等。

mod制作非魔术邪说也,人皆可学习相关知识以制作mod,这个指引旨在降低ck2模组制作的门槛。不过,无论学习资料有多么的好,制作mod的过程都会是十分曲折的,并且学习资料无法取代对阅读基础代码,以及不断调试的需要。总之,制作mod不是一天两天的功夫,而是一项宏伟的工程,努力是必须的。

指引

  • 为您的修改创建mod:即使是小的更改也要创建个人mod,并且切勿直接修改Steam CKII文件夹中的游戏文件,因为它们可能会在没有警告的情况下被覆盖。
  • 使用优质的文本编辑器 来编辑文件并搜索多个文件。请参见文本编辑器
  • 验证你的mod 使用The Validator,它将为您节省许多麻烦和时间,以解决崩溃和错误。
  • 尽量减少对原版文件的覆盖 通过添加单独的文件或尽可能地从文件夹加载,以改善mod兼容性和维护。
  • 使用适当的合并工具 以便在文件夹之间合并,并将修改后的原版文件更新为新的Vanilla补丁。
  • 备份您的工作 以避免丢失一切。如果是一个MOD制作组,请考虑使用诸如GitHub之类的源代码控制系统充当备份并管理协作。
  • 使用ANSI(Windows-1252)编码 用于文本文件。
  • 适当缩进 以轻松发现未闭合的花括号。原版使用1个制表符来缩进而不是空格。
  • 使用注释 以#字符开头,来记住编写棘手内容的原因。

文本编辑器

以下是支持CK2编程语言的文本编辑器:

Mod结构

mod文件被放置在 ~\Paradox Interactive\Crusader Kings II\mod, 里面必须包含:

  • .mod 文件, 告诉启动器如何加载你的mod
  • 包含mod数据好的文件夹或者是zip压缩包。mod数据的文件结构必须和本体的游戏结构相同,注意文件夹和文件的名称大小写在Mac和Linux上是敏感的,这意味着 Abc 和 abc 会被视为两个mod。

.mod 文件的文件名不能包含任何空格,否则在启动器重启的时候,不会被自动选中。

.mod 文件的内容如下所示:

关键字 必需? 效果 例子
name Yes 你的mod显示在启动器中的名称 name = "My Mod"
path Yes 定义哪个文件夹是你的mod文件夹。 其路径是相对于~\Documents\Paradox Interactive\Crusader Kings II\ . path = "mod/MyMod"
user_dir No 告诉启动器存储游戏或临时文件到特定的文件夹。 这对能改善mod的兼容性(例如新的标题,旗帜,宗教,文化,建筑之类的),让文件不会混淆在一起。

警告:不要给主mod的子mod设置 user_dir,因为所有激活mod的user_dir会连接在一起。

user_dir = "MyMod"
archive No 定义一个zip压缩包来代替文件夹。设置它的路径,路径是相对于 ~\Documents\Paradox Interactive\Crusader Kings II\ 的。这是从Steam创意工坊下载的mod使用的格式,但是在将mod上传到创意工坊时,必须使用path结构。 archive = "mod/mymod.zip"
replace_path No 告诉启动器覆盖对应文件夹的所有内容,并且只从mod中的指定路径加载。这是删除原版东西的唯一有效方式,而这经常被完全改动类mod所使用。

Notes:

  • replace_path作为文件夹工作,而不是文件.,覆盖一个文件,只需要在mod中创建一个同名文件。
  • replace_path只对对应文件夹中的文件有效,其子文件夹中的文件无效. 例如,覆盖“history”并不会覆盖“history/characters”。
  • 为了缩小mod体积、增强mod兼容性,尽可能少用replace_path.
  • 在旧版本中,replace_path在被安装到CK2安装目录/mod时通常被忽视,因此必须放入使用者文件。(见CK2模组目录
  • 除非你确实需要使用replace_path才使用,通常不用。
replace_path = "history"

replace_path = "history/characters"

dependencies No 告诉启动器,在此mod之前必须加载另一个mod。另一个模组将首先加载,允许另一个模组覆盖某些文件(否则第一个模组将先加载)。一个dependencies不是必要的;如果mod有一个集,则不需要加载dependencies。这只是 .mod文件告诉启动器应首先加载哪些文件的一种方式。

如果dependencies里的mod的名称包含空格,则必须将其括在转义引号中。"\"Mod with space in name\""

dependencies = { "MyMod" "\"Another Mod\"" }
picture No 模组文件夹下的图像可用作Steam创意工坊的展示图片。(将显示为 268 像素× 268 像素 JPEG) picture = "MyMod.jpg"
tags No Steam创意工坊的标签列表。警告:不要忘记包含空格的标签的引号。 tags = { "Tag1" "Tag 2" }
supported_checksums No 脚本条件将计算为true的预期校验和列表。这可以在事件模组制作中使用,以向玩家显示警告。supported_checksums supported_checksums = { ABCD EFGH }

以下是一些示例模组文件,具体取决于模组的类别:

小型mod

小型mod更常见一些,为了保证和其它小型mod的兼容性,请不要使用user_dir或者是replace_path

 name = "Small Mod"
 path = "mod/SmallMod"
 picture = "SmallMod.jpg"
 tags = { "Mods" "Small" }

大型mod

大型模组通常使用 user_dir 使保存内容无论如何都无法在开启此mod前加载。对于总转化模组, replace_path 用于完全覆盖在模组中没有意义的原版文件夹(histroy,flags等)。

 name = "Big Mod"
 path = "mod/BigMod"
 user_dir = "BigMod"
 replace_path = "history/provinces" 
 picture = "BigMod.jpg"
 tags = { "Mods" "Big" }

子mod

主mod的子mod通常用 dependencies 来覆盖主mod的文件。

 name = "Sub Mod"
 path = "mod/SubMod"
 dependencies = { "\"Main Mod\"" }
 picture = "SubMod.jpg"
 tags = { "Mods" "Main Mod" }

游戏数据

游戏结构

游戏数据是由包含游戏文件的文件夹及子文件夹的结构组成。

模组遵循与基础游戏相同的文件夹结构,因此在加载游戏时,引擎将合并来自原版和mod的文件。在大多数文件夹中,引擎将加载其中的所有文件,这允许mod添加新的定义(头衔,宗教等),而无需复制和修改原版文件。若要利用这一点,请务必了解如何在文件级别和定义级别加载脚本。

加载模组时的行为如下:

  • 引擎根据某些硬编码的加载顺序处理文件夹和文件。
  • 如果将当前文件夹定义为 replace_path ,则该文件夹中的所有原版文件都将被忽略,并且只会加载mod文件(如果有)。
  • 如果 mod 文件夹和原版文件夹都包含同名的文件,则将忽略原版文件,并使用mod版本。
  • 在给定的文件夹中,文件的处理顺序通常是字母数字的,合并了 vanilla 和 mod 文件名,尽管某些文件夹可能具有不同的行为
  • 在多次遇到相同的定义(头衔,宗教,决议等)时,重复的定义可能:
    • 被忽略(先加载的定义成为游戏内容)
    • 完全覆盖上一个定义(最后一个定义成为游戏内容)
    • 部分覆盖以前的定义(定义被合并/加法,这只有在实际有要合并的东西时才有意义:层次结构,列表等)
    • 两者共存/中断(在这种情况下,必须避免重复的ID)

以下是CKII游戏文件和文件夹的列表,以及相关的模组指南和加载行为。

对于加载行为,单元格颜色会突出显示行为是预期的行为奇怪的行为还是需要注意的行为是意外的,还是需要避免的行为

文件夹/文件 该文件包含什么 如何模组 加载行为
.\common\
  • achievements.txt
  • defines.lua
  • defines.txt
  • hints.txt
  • region_colors.txt
  • static_modifiers.txt
  • technology.txt
大致信息
  • 定义Steam成就
  • POP, 一般变量、外交变量、经济变量和军事变量
  • 定义可游玩的开始日期和结束日期
  • 定义显示的提示
  • 定义每个区域的 RGB 代码
  • 所有难度、等级和标准修饰符
  • 科技数据

定义



修正

科技模组制作

不适用
.\common\alternate_start\ 另类开局模组制作 [?] 合并。
.\common\artifact_spawns\ 宝物模组制作 合并。
.\common\artifacts\ 宝物的定义 宝物模组制作 合并。
.\common\bloodlines\ 血脉文件夹,所有的血脉都存储在这里。 血脉模组制作
.\common\bookmarks\ 剧本文件夹,所有的剧本都存储在这里。 剧本模组制作 合并。剧本在游戏中按时间顺序列出,无论文件中的顺序如何。
.\common\buildings\ 建筑文件夹,所有的建筑都存储在这里。 建筑模组制作 [?] 合并。
.\common\cb_types\ 宣战理由文件夹,所有的宣战理由都存储在这里。 宣战理由模组制作 合并,但通过重复使用相同的名称来覆盖宣战理由不起作用。(创建重复的宣战理由文件)
.\common\combat_tactics\ 作战战术文件夹,所有的作战战术都存储在这里。 单位模组制作 [?] 合并。
.\common\council_positions\ AI内阁成员采取哪种类别的行为的规则。 内阁成员模组制作 [?]
.\common\council_voting\ AI在内阁中投票法律的规则 内阁成员模组制作 [?]
.\common\cultures\ 文化文件夹,所有的文化都存储在这里。 文化模组制作 合并。 由于补丁2.4文化像宗教一样合并,并且可以通过单独的文件将新的文化添加到原版文化组中。
.\common\death\ 死亡原因文件夹,所有的死亡原因都存储在这里。 死亡模组制作
.\common\death_text\ 为继承屏幕添加死后评价 死亡模组制作
.\common\defines\ 定义文件夹,所有的定义都存储在这里。 定义 [?] 合并。文件中的条目将覆盖common/defines.lua。
.\common\disease\ 疾病文件夹,所有的疾病都存储在这里。 疾病模组制作 [?] 合并。
.\common\dynasties\ 家族文件夹,所有的家族都存储在这里。 家族模组制作 合并。在原版之前加载的重复家族将覆盖家族盾徽(i.e., 000_ 等前缀) 。之后加载的重复项 (i.e., z_ 等前缀) 将覆盖家族名称。要覆盖两者,请使用重复的文件,一个具有前面的前缀,另一个具有后续前缀。
.\common\event_modifiers\ 事件修正文件夹,所有的事件修正都存储在这里。 修正 合并。
.\common\execution_methods\ 处决类型文件夹,所有的处决类型都存储在这里。 死亡模组制作 [?]
.\common\game_rules\ 游戏规则文件夹,所有的游戏规则都存储在这里。 游戏规则模组制作 合并。规则根据文件的顺序(文件名上的字母数字)和文件中的规则顺序显示在 UI 中。
.\common\government_flavor\ 政体定义文件夹,所有的政体定义都存储在这里。 政体模组制作 [?]
.\common\governments\ 政体文件夹,所有的政体都存储在这里。 政体模组制作 合并。可以在不同的文件中定义同一政府组的政府。
.\common\graphicalculturetypes\ 文化肤色文件夹,所有的文化肤色都存储在这里。 [?] 合并。
.\common\heir_text\ 为继承屏幕添加继承人评价 死亡模组制作
.\common\holding_types\ 地产类型文件夹,所有的地产类型都存储在这里。 政体模组制作 [?]. 无法添加新的地产类型。
.\common\job_actions\ 内阁成员行为文件夹,所有的内阁成员行为都存储在这里。 内阁成员模组制作 合并。
.\common\job_titles\ 内阁职务文件夹,所有的内阁职务都存储在这里。 内阁成员模组制作 [?]
.\common\landed_titles\ 头衔文件夹,所有的头衔都存储在这里。 头衔模组制作 合并。合并行为“很复杂,可能不是故意设计的”[1]
.\common\laws\ 法律模组制作 合并。与现有法律同名的法律将在允许部分附加条件,但不会将潜在部分附加条件。
.\common\mercenaries\ 佣兵文件夹,所有的佣兵都存储在这里。 [?] 合并。
.\common\minor_titles\ 荣誉头衔文件夹,所有的荣誉头衔都存储在这里。 荣誉头衔模组制作 无法覆盖,尝试这样做将导致多个荣誉头衔具有相同的tag,如特质
.\common\modifier_definitions\ 定义动态定义的修饰符,特别是特殊单位的修饰符。 单位模组制作 [?] 合并。
.\common\nicknames\ 称号文件夹,所有的称号都存储在这里。 称号模组制作 合并。
.\common\objectives\ 目标文件夹,所有的目标都存储在这里。 目标模组制作 [?] 合并。
.\common\offmap_powers\
  • policies\
  • statuses\
定义地图外政权的文件夹。 地图外政权模组制作 [?] 合并。不需要碧玉之龙DLC。
.\common\on_actions\ On_actions文件夹,所有的on_actions文件都存储在这里。 事件模组制作 合并。由于补丁 2.4 on_actions被合并,新事件被添加到特定on_action的先前列表中,而不是替换列表。
.\common\opinion_modifiers\ 好感修正文件夹,所有的好感修正都存储在这里。 修正 [?] 合并。
.\common\province_setup\ patch 3.0后废弃 不适用 不适用
.\common\religion_features\ 宗教特性文件夹,所有的宗教特性都存储在这里。 宗教模组制作 [?] 合并,但具有相同键的功能会重复。
.\common\religion_modifiers\ 宗教修正文件夹,所有的宗教修正都存储在这里。 修正 [?] 合并。
.\common\religions\ 宗教文件夹,所有的宗教都存储在这里。 宗教模组制作
合并。原版宗教可以被覆盖,而不需要复制整个宗教组。限制:需要在未改革宗教之前定义改革宗教。
.\common\religious_titles\ 宗教头衔文件夹,所有的宗教头衔都存储在这里。 [?] 合并。
.\common\retinue_subunits\ 近卫军单位文件夹,所有的近卫军单位都存储在这里。 [?] 合并,但具有相同密钥的随从被复制。
.\common\save_conversion\ 游戏存档兼容性 [?]
.\common\scripted_effects\ 脚本 [?] 合并。
.\common\scripted_score_value\ 脚本分数值 [?] 合并。
.\common\scripted_triggers\ 脚本触发器 合并,但具有相同名称的脚本化触发器会附加其条件,而不是替换原始条件。
.\common\societies\ 社团文件夹,所有的社团都存储在这里。 社团模组制作 Merge,但通过用相同名称覆盖一个社团不起作用(创建重复的社团)。
.\common\special_troops\ 特殊单位文件夹,所有的特殊单位都存储在这里。 单位模组制作 [?] 合并。
.\common\stories\ 废弃的 不适用 不适用
.\common\succession_voting\ 继承投票规则及AI继承投票行为规则 继承模组制作 [?] 合并。
.\common\trade_routes\ 贸易路线文件夹,所有的贸易路线都存储在这里。 贸易路线模组制作 [?]
.\common\traits\ 特质文件夹,所有的特质都存储在这里。 特质模组制作 合并,但具有相同名称的特质将共存,并且生成的角色可以同时获得两种特质。使用命令时,最后一个定义将分配给角色。
.\common\tributary_types\ 朝贡关系文件夹,所有的朝贡关系都存储在这里。 朝贡类型模组制作 [?]
.\common\triggered_modifiers\ 定义在特定条件下触发的全局修饰符。 Triggered modifiers [?] 合并。
.\connectui\ 似乎是已停止使用的Paradox Connect服务的剩余接口(用于克劳塞维茨引擎开发的较旧的游戏如CK2)。 废弃的 不适用
.\decisions\ 决议文件夹,所有的决议都存储在这里。 决议模组制作 合并, 但通过重用相同名称覆盖决策不起作用(破坏决策效果,这不执行任何操作)。
.\dlc\ 包含 DLC 信息和压缩内容文件 可下载内容 不适用
.\dlc_metadata\
.\eu4_converter\ EU4转档器文件夹,所有的EU4转档器文件都存储在这里。 EU4转档器模组制作 [?]
.\events\ 事件文件夹,所有的事件都存储在这里。 事件模组制作 合并,如果在原始文件之后按字母顺序加载的文件中重新定义事件,则该事件将被完全覆盖。

开发人员不鼓励这种做法,因为该引擎行为不能保证在将来保留(来源?)

.\gfx\
  • ambitions\
  • characters\
  • coats_of_arms\
  • cursors\
  • eurfonts\
  • event_pictures\
  • flags\
  • fonts\
  • FX\
  • interface\
  • loadingscreens\
  • mapitems\
  • models\
  • polishfonts\
  • titles\
  • traits\
图像文件夹,所有的图像都存储在这里。 图形模组制作

图形映射到 .\interface\*.gfx 文件中

的逻辑名称 (GFX_xxx)
警告:flags\ 中缺少头衔的标志将导致大多数头衔出现错误的标志,这是由于偏移

.\history\ 字符、标题、省份和战争的历史数据,以及可能的开始日期。这可能是内部数据库的文本导出,有时在补丁说明中会提到。[2] 历史模组制作 不适用
.\history\characters\ 历史人物,可选择与\common\dynasties\文件夹中的王朝相关联。 角色模组制作 [?] 合并。重复的角色ID会破坏角色历史记录,必须避免。
.\history\diplomacy\ 未使用 不适用 不适用
.\history\offmap_powers\ 地图外政权的历史(持有者,地位等) 地图外政权模组制作 [?] 合并。
.\history\provinces\ 省份历史(地产,文化或宗教的变化) 省份模组制作 [?] 合并。
.\history\technology\ 各省的初始技术,取决于开始日期。 科技模组制作 [?]
.\history\titles\ 头衔历史(持有者名单) Note: titles that should be deactivated at game start (ex: reformed religion heads) must have an history file that disables the title. [?] 合并。
.\history\wars\ 重要的正在进行的战争(进攻者,防守者,宣战理由,战争得分等),通常用于历史剧本。 [?] 合并。
.\interface\
  • generalstuff.gfx
  • sound.sfx
界面图形 界面模组制作
  • *.gfx 文件的加载按字母数字顺序排列。加载的最后一个 spriteType 定义将覆盖具有相同名称的先前定义(如果有)(即使用zz_文件前缀来覆盖普通精灵)。
  • 仅考虑 sound.sfx,忽略其他 .sfx 文件。
.\interface\coat_of_arms\ 盾徽模组制作 盾徽定义可以拆分到多个文件中。不支持从其他文件追加现有定义。
.\interface\portrait_offsets\ .txt带有肖像框架外部偏移的文件 肖像模组制作
.\interface\portrait_properties\ 用于选择纵向属性值的动态规则 肖像模组制作 [?]
.\interface\portrait\ 肖像的spriteType和portraitType元素的定义。 肖像模组制作 合并。
.\launcher\ 启动器图像和配置 不适用
.\localisation\ 所有本地化国家/地区名称和事件描述等内容的所有文本数据。 本地化 完全覆盖。如果重复项位于不同的文件中,则首先加载的文件优先(即使用 00_ 文件前缀覆盖原始键)。如果在同一文件中,则文件中的最后一个重复项优先。警告:文件必须以.csv扩展名结尾,否则将不加载。
.\localisation\customizable_localisation\ 习惯的本地化命令定义 本地化 [?] 合并
.\map\
  • adjacencies.csv
  • default.map
  • definition.csv
  • geographical_region.txt
  • positions.txt
  • provinces.bmp
  • rivers.bmp
  • terrain.bmp
  • topology.bmp
  • trees.bmp
  • world_normal_height.bmp
地图文件夹,所有的地图数据都存储在这里。 地图模组制作 不适用
.\map\statics 地图外部框架大小,以及固定3D地图元素的位置(奇观等)。 地图模组制作
.\map\terrain 地图模组制作
.\mod\ 虚拟mod文件夹,不要在这里放mod。 模组制作 破坏模组,因为像replace_path这样的配置被忽略。
.\music\ 音乐文件夹,所有的音乐都存储在这里。 音乐模组制作 [?] 加载所有.txt文件歌曲元素。
.\sound\ 声音文件夹,所有的声音都存储在这里。 [?]
.\tutorial\ 教程设置 [?]

具体指南

仅包含上面或以其他方式“如何修改”列中尚未链接的指南。



工具与实用程序

这些是modder用的实用工具。 玩家使用的请看实用工具.

高级技巧

  • 对于使用源代码管理工具(Git,......)的大型mod,在CKII mod文件夹和本地存储库的工作目录之间创建符号链接非常方便,特别是如果mod也有子mods。请注意,您仍然需要手动复制 .mod 文件,但它们很少更改。从主git文件夹的父目录运行以下命令,替换:
    • <mod_path_name>填写.mod文件的 path 里的mod名称
    • <git_mod_folder>填写mod的子文件夹(common文件夹、decisions文件夹、event文件夹等)的名称
mklink /J "%HOMEDRIVE%%HOMEPATH%\Documents\Paradox Interactive\Crusader Kings II\mod\<mod_path_name>" ".\<git_mod_folder>"

MOD调试

毫无疑问,更多隐藏的控制台指令(在控制台输入help也不会显示的内容)对MOD测试会起到巨大的作用。

  • observe - 让你进入观察者模式。此时你不再控制任何特定的角色——这会让游戏不受打断地自动运行。同时,所有隐藏特质、秘密信仰等对观察者都是可见的。
  • run <filename.txt> - 直接运行特定脚本。脚本将从当前玩家控制角色的作用域开始执行。这个功能有助于测试复杂的脚本——你可以直接打开一个窗口编辑脚本,保存,重新载入,调整——省下重新打开游戏的时间。
  • reloadevents - 重新载入和编译每一个事件(可能花费一会时间,取决于你的硬件)。对调试事件很有帮助,同样为你省下重新打开游戏的时间。
  • reloadloc - 重新载入本地化文件,有助于确定文本是否显示在正确的位置上。

更多控制台指令可以在首页找到,用于实现杀掉某人之类的特定功能,这些对MOD测试同样必不可少。

外部链接

更多

引用