无编辑摘要 |
无编辑摘要 |
||
第1行: | 第1行: | ||
{{DISPLAYTITLE:意识形态}} | |||
{{Version|1.8}} | {{Version|1.8}} | ||
第180行: | 第182行: | ||
{{Modding navbox}} | {{Modding navbox}} | ||
[[Category:Modding]] | [[Category:Modding]] | ||
{{DEFAULTSORT:意识形态}} |
2021年9月5日 (日) 10:09的版本
意识形态 代表所选国家的所有不同政治信仰或联盟。意识形态将有助于决定国家将采取的选择和道路。
意识形态文件在 /Hearts of Iron IV/common/ideologies/*.txt.
Ideologies
An ideology follows the following format:
ideologies = { anarchist = { types = { anarcho_syndicalism = { # Used when assigning ideologies to leaders. Eg. democratic has conservatism, liberalism, and socialism. One value can be defined (yes/no) can_be_randomly_selected = # If no, the subideology will not be randomly selected when creating a new random leader } } dynamic_faction_names = { "FACTION_NAME_ANARCHIST_1" # Faction names used by the ai when an ai with this ideology creates a faction } color = { 169 42 42 } # RGB ideology colour. The color it appears when in a political pie chart or next to the chart rules = { # Rules for the ideology. (yes/no) can_create_collaboration_government = # Can create a collaboration government can_declare_war_on_same_ideology = # Declare war on same ideology. Not required can_force_government = # Can change ideology in peace deal. Required can_send_volunteers = # Can send volunteers. Required can_puppet = # Can puppet a nation at peace deal. Required can_lower_tension = # Lowers tension at peace deal. Not required can_only_justify_war_on_threat_country = # Can only justify on a nation that has generated world tension/threat. Not required can_guarantee_other_ideologies = # Can guarantee nations with different ideologies. Not required } can_host_government_in_exile = no #Can host a government in exile war_impact_on_world_tension = # Goes from -1 to 1. Increases or decreases the world tension created by this nation faction_impact_on_world_tension = # Goes from -1 to 1. Increases or decreases a faction of this ideologies impact on tension modifiers = { # More rules for the ideology generate_wargoal_tension = # Required world tension to start justifying a war (0 to 1) join_faction_tension = # Required world tension to join a faction (0 to 1) lend_lease_tension = # Required tension to start a lend-lease (0 to 1) send_volunteers_tension = # Required tension to send volunteers (0 to 1) guarantee_tension = # Required tension to guarantee a nation (0 to 1) take_states_cost_factor = # Changes the cost of states in a peace deal. 0.25 would increase state cost by 25% (-1 to 1) annex_cost_factor = # Changes the cost of entirely annexing a nation in a peace deal. 0.5 would increase annexing cost by 50% (-1 to 1) justify_war_goal_when_in_major_war_time = # Changes the cost of justifying a war while in a major war. 0.5 would decrease time by 50% (0 to 1) drift_defence_factor = # Natural drift defence for the ideology # 0.3 would grant 30% drift defence (-1 to 1) puppet_cost_factor = # Changes the cost of puppeting a nation in a peace deal (-1 to 1) } can_be_boosted = # Can you boost this ideologies popularity in another country (yes/no) can_collaborate = # faction_modifiers = { faction_trade_opinion_factor = 0.50 #plus 50% trade opinion } ai_<ideology> = yes # Determines what ai this ideology will use (democratic, communism, fascism, neutral or make a new one.) } }
Ai peace
This is what the ai will look to to determine how they will act. It tells them in what circumstance to take a state, annex or puppet, or what they want to achieve from a peace deal.
It is influenced by the ai's ideology
It is located in /Hearts of Iron IV/common/ai_peace/*.txt and every ideology has its own file. Should you not make a specialised one, the ai will just use /Hearts of Iron IV/common/ai_peace/z_default.txt
Getting the ideology in your game
Localisation
The localisation for the ideologies is located in /Hearts of Iron IV/localisation/parties_l_<language>.txt. This file also houses the names given to the political parties in each nation.
Somewhere in your copy of the file add
<ideology>:0 "<The name you want to be displayed>" <ideology>_noun:0 "<The ideology's noun>" <ideology>_desc:0 "<How you would refer to a nation with that ideology>" # Ie. Democratic Regime, Fascist Dictatorship, Anarcho-Capitalist Regime
You also have to add localisation for the ideology to every country which can be a bit time consuming
AFG_anarchist:0 "Anarchist Republic of Afghanistan" AFG_anarchist_ADJ:0 "Anarcho-Afghan" AFG_anarchist_DEF:0 "The People's Anarchist Republic of Afghanistan"
GFX
Every nation will either need a flag for this ideology, or a generic national flag.
To assign an ideology to a flag just name it <TAG>_<ideology>.tga or create a flag for the nation to use that doesn't have a specific ideology by just naming the flag <TAG>.tga. Doing it the last way makes it easier to add flags when you have added a lot of similar ideologies.
Country history
If you want the ideology to appear in a country you will have to add it like this to a countries history file like this: In France, for example /Hearts of Iron IV/history/countries/FRA - France.txt
set_politics = { ruling_party = democratic last_election = "1932.5.1" election_frequency = 48 elections_allowed = yes } set_popularities = { #This MUST add up to 100 otherwise the ideologies break democratic = 69 fascism = 1 communism = 30 }
France will now need a new leader
create_country_leader = { name = "Édouard Daladier" desc = "POLITICS_ÉDOUARD_DALADIER_DESC" picture = "Portrait_France_Edouard_Daladier.dds" expire = "1965.1.1" ideology = socialism traits = { stout_defender } }
Political advisor
If you want to make it possible for you to boost the ideology through advisor you have to add this into /Hearts of Iron IV/common/country_leader/00_traits.txt
<ideology>_booster = { random = no sprite = 13 <ideology>_drift = 0.1 ai_will_do = { factor = 0 } }
Also to add localisation to this advisor go to /Hearts of Iron IV/localisation/ideas_l_<language>.txt and add something similar to:
generic_<ideology>_booster:0 "" #Whatever you want to call the person that supports the ideology. Eg. Democratic Politician, Communist Politician, Fascist Politician
If you want a country to have an advisor of this ideology you have to go to the nation's idea files in /Hearts of Iron IV/common/ideas/<nation>.txt and add:
<name> = { allowed = { original_tag = "<TAG>" } traits = { <ideology>_booster } on_add = { country_event = # Add an event here if you want one } do_effect = { NOT = { has_government = <ideology> # You can only select it if your current ideology isn't your new one } } ai_will_do = { factor = 0 } }
文件 | 效果 • 条件 • 定义 • 修正 • 修正列表 • 作用域 • 本地化 • on action • 数据结构 (标记, 临时标记, 国家别名, 变量, 数组) |
脚本 | 成就修改 • AI修改 • AI focuses • 自治领修改 • 权力平衡修改 • 剧本/标签 (游戏规则)• 建筑修改 • 人物修改 • 修饰性TAG修改 • 国家创建 • 军队修改 • 决议制作 • 装备修改 • 事件修改 • Idea修改 • 意识形态修改 • 军工商修改 • 国策制作 • 资源修改 • Scripted GUI • 科技制作 • 单位修改 |
地图 | 地图 • 省份 • 补给区域 • 战略区域 |
图形图像 | 界面 • 图形资产 • 实体模型 • 后期特效 • 离子效果 • 字体 |
装饰性 | 肖像 • 命名列表 • 音乐 • 音效 |
其他 | 控制台指令 • 故障排除 • 模组结构 • 成就代码分析 • Mod相关 • Nudger修改 |