单位修改

本页面所适用的版本可能已经过时,最后更新于1.23
本页关于修改兵种单位的属性。关于单位模型的修改请参考兵模

修改单位

游戏中所有可以看见的单位都被储存在 /Europa Universalis IV/common/units/

陆军单位

要添加一个新的历史陆军单位(例如长戟步兵,halberd_infantry),你需要创建一个单位文件在 /Europa Universalis IV/common/units/ 里面。单位设定参照以下格式:

type = <internal type>              # 决定单位内部类型。(步兵,骑兵,炮兵)
unit_type = <technology group>        # 可选。设定该单位将会出现在某个特定科技组,省略它将会使所有科技组都可以使用这个单位。

maneuver = <int>                    # 打击范围,原版步兵和炮兵此处填1,骑兵填2
offensive_morale = <int>            # 进攻时的士气
defensive_morale = <int>           # 防御时的士气
offensive_fire = <int>             # 进攻时的火力
defensive_fire = <int>              # 防御时的火力
offensive_shock = <int>              # 进攻时的冲击
defensive_shock = <int>               # 防御时的冲击

unitsize = <int>                    # 可选。 可以设定一个陆军单位的人数(基准是1000人), 使一个团的人数变得更多或更少。
manpower = <float>                  # 可选。 可以设定一个陆军单位消耗的人力,此处1点相当于1000人力。

# 可选,当触发器满足时,显示该单位作为一个选项
trigger = {
    <triggers>
}

陆军单位可以是这三种内部类型之一:

infantry # 步兵
cavalry # 骑兵
artillery # 炮兵

注意: 改变一个单位的大小并不会改变作战公式,这意味着人数少的军团在战斗中将会表现不佳。

海军单位

要添加一个新的历史海军单位(例如三桅帆船,barque),你需要创建一个文件在 /Europa Universalis IV/common/units/里面。 单位设定参照以下格式:

type = <internal type>              # 决定单位内部类型。(重型船,轻型船,浆帆船,运输船)
unit_type = <technology group>      # 可选。 设定该单位将会出现在某个特定科技组,省略它将会使所有科技组都可以使用这个单位。

hull_size = <int>  # 船体
base_cannons = <int> # 基础火炮
sail_speed = <int> # 航行速度
blockade = <int> # 封锁效率

trade_power = <float>   # 可选。设定当这艘船在保护贸易时提供的贸易力量。
sprite_level = <int>    # 可选。 船的等级(1至5)
manpower = <float>      # 可选。 可以设定一个海军单位消耗的水手,此处1点相当于1000水手。

# 可选,当触发器满足时,显示该单位作为一个选项
trigger = {
    <triggers>
}

海军单位可以是这四种内部类型之一:

heavy_ship # 重型船
light_ship # 轻型船
galley # 桨帆船
transport # 运输船

内部类型

内部类型的功能是不能被修改的。例如,你不可以移除设定在 骑兵 单位上的侧翼攻击,或者将其添加到其他不同的内部类型上。

文件中的其他区域引用这些类型例如定义和修正(例如炮兵速度ARTILLERY_SPEED 或步兵作战能力 infantry_power)都将影响所有使用上述内部类型的单位。

科技

要使单位出现,它们必须在科技中启用。添加以下代码使科技启用某个单位:

enable = <unit>

注意:陆军单位只能启用在军事科技,而海军单位只能启用在外交科技。

本地化

单位的本地化遵循以下格式:

<unit>: "单位名称在这里"
<unit>DESCR: "描述在这里"


参考资料

兵种单位关键字就是文件名

  1. adal_guerilla_warfare
  2. adal_gunpowder_warfare
  3. african_abyssinian_cavalry
  4. african_abyssinian_light_cavalry
  5. african_clubmen
  6. african_cuirassier
  7. african_dragoon
  8. african_hill_warfare
  9. african_hussar
  10. african_mandelaku
  11. african_mossi_horsemen
  12. african_somali_cavalry
  13. african_spearmen
  14. african_swarm
  15. african_tuareg_cavalry
  16. african_western_franchise_warfare
  17. afsharid_reformed
  18. afsharid_reformed_infantry
  19. algonkin_tomahawk_charge
  20. ali_bey_reformed_infantry
  21. american_western_franchise_warfare
  22. anglofrench_line
  23. apache_guerilla
  24. archipelago_frigate
  25. asian_arquebusier
  26. asian_charge_cavalry
  27. asian_mass_infantry
  28. asian_musketeer
  29. austrian_grenzer
  30. austrian_hussar
  31. austrian_jaeger
  32. austrian_tercio
  33. austrian_white_coat
  34. aztec_gunpowder_warfare
  35. aztec_hill_warfare
  36. aztec_tribal_warfare
  37. bantu_gunpowder_warfare
  38. bantu_plains_warfare
  39. bantu_tribal_warfare
  40. bardiche_infantry
  41. barque
  42. bhonsle_cavalry
  43. bhonsle_infantry
  44. brig
  45. british_hussar
  46. british_redcoat
  47. british_square
  48. caravel
  49. carrack
  50. central_american_dragoon
  51. central_american_horsemen
  52. central_american_hussar
  53. central_american_rifle_cavalry
  54. central_american_swarm
  55. chambered_demi_cannon
  56. chebeck
  57. chevauchee
  58. chinese_dragoon
  59. chinese_footsoldier
  60. chinese_longspear
  61. chinese_steppe
  62. coehorn_mortar
  63. cog
  64. commanche_swarm
  65. creek_arquebusier
  66. culverin
  67. druzhina_cavalry
  68. durrani_dragoon
  69. durrani_rifled_musketeer
  70. durrani_swivel
  71. dutch_maurician
  72. early_carrack
  73. early_frigate
  74. east_asian_spearmen
  75. east_mongolian_steppe
  76. eastern_bow
  77. eastern_carabinier
  78. eastern_knights
  79. eastern_medieval_infantry
  80. eastern_militia
  81. eastern_skirmisher
  82. eastern_uhlan
  83. eastindiaman
  84. ethiopian_guerilla_warfare
  85. ethiopian_gunpowder_warfare
  86. ethiopian_mountain_warfare
  87. flute
  88. flying_battery
  89. french_bluecoat
  90. french_carabinier
  91. french_caracolle
  92. french_cuirassier
  93. french_dragoon
  94. french_impulse
  95. frigate
  96. gaelic_free_shooter
  97. gaelic_galloglaigh
  98. gaelic_mercenary
  99. galiot
  100. galleass
  101. galleon
  102. galley
  103. germanized_pike
  104. great_frigate
  105. ha_foreign_influenced_infantry
  106. ha_reformed_influenced_infantry
  107. ha_reformed_xantican_warrior
  108. ha_reformed_xoloti
  109. ha_xantican_warrior
  110. ha_xiuhtecuhtli_soldier
  111. ha_xiuhtecuhtlian_infantry
  112. ha_xoloti
  113. halberd_infantry
  114. han_banner
  115. heavy_frigate
  116. high_american_dragoon
  117. high_american_horsemen
  118. high_american_hussar
  119. high_american_rifle_cavalry
  120. high_american_swarm
  121. houfnice
  122. hungarian_hussar
  123. huron_arquebusier
  124. inca_mountain_warfare
  125. incan_axemen
  126. incan_guerilla_warfare
  127. incan_slingshots
  128. indian_archers
  129. indian_arquebusier
  130. indian_elephant
  131. indian_footsoldier
  132. indian_rifle
  133. indian_shock_cavalry
  134. irish_charge
  135. iroquis_rifle_scout
  136. iroquois_rifle_scout
  137. italian_condotta
  138. japanese_archer
  139. japanese_footsoldier
  140. japanese_samurai
  141. large_cast_bronze_mortar
  142. large_cast_iron_bombard
  143. leather_cannon
  144. maharathan_cavalry
  145. maharathan_guerilla_warfare
  146. mali_tribal_warfare
  147. mamluk_archer
  148. mamluk_cavalry_charge
  149. mamluk_duel
  150. mamluk_musket_charge
  151. manchu_banner
  152. maya_forest_warfare
  153. maya_guerilla_warfare
  154. maya_gunpowder_warfare
  155. maya_tribal_warfare
  156. merchantman
  157. mesoamerican_spearmen
  158. mexican_guerilla_warfare
  159. mixed_order_infantry
  160. mongol_bow
  161. mongol_steppe
  162. mongol_swarm
  163. mongolian_bow
  164. mughal_mansabdar
  165. mughal_musketeer
  166. muscovite_caracolle
  167. muscovite_cossack
  168. muscovite_musketeer
  169. muscovite_soldaty
  170. muslim_cavalry_archers
  171. muslim_dragoon
  172. muslim_mass_infantry
  173. napoleonic_lancers
  174. napoleonic_square
  175. native_clubmen
  176. native_indian_archer
  177. native_indian_horsemen
  178. native_indian_mountain_warfare
  179. native_indian_tribal_warfare
  180. niger_kongolese_forest_warfare
  181. niger_kongolese_guerilla_warfare
  182. niger_kongolese_gunpowder_warfare
  183. niger_kongolese_tribal_warfare
  184. north_american_dragoon
  185. north_american_horsemen
  186. north_american_hussar
  187. north_american_rifle_cavalry
  188. north_american_swarm
  189. open_order_cavalry
  190. ottoman_azab
  191. ottoman_janissary
  192. ottoman_lancer
  193. ottoman_musellem
  194. ottoman_new_model
  195. ottoman_nizami_cedid
  196. ottoman_reformed_janissary
  197. ottoman_reformed_spahi
  198. ottoman_sekban
  199. ottoman_spahi
  200. ottoman_timariot
  201. ottoman_toprakli_dragoon
  202. ottoman_toprakli_hit_and_run
  203. ottoman_yaya
  204. pedrero
  205. persian_cavalry_charge
  206. persian_footsoldier
  207. persian_rifle
  208. persian_shamshir
  209. peruvian_guerilla_warfare
  210. polish_hussar
  211. polish_musketeer
  212. polish_tercio
  213. polish_winged_hussar
  214. prussian_drill
  215. prussian_frederickian
  216. prussian_uhlan
  217. pueblo_ambush
  218. qizilbash_cavalry
  219. rajput_hill_fighters
  220. rajput_musketeer
  221. reformed_asian_cavalry
  222. reformed_asian_musketeer
  223. reformed_manchu_rifle
  224. reformed_mughal_mansabdar
  225. reformed_mughal_musketeer
  226. reformed_steppe_rifles
  227. reformed_westernized_incan
  228. royal_mortar
  229. russian_cossack
  230. russian_cuirassier
  231. russian_green_coat
  232. russian_lancer
  233. russian_mass
  234. russian_petrine
  235. saxon_infantry
  236. schwarze_reiter
  237. scottish_highlander
  238. shaybani
  239. sikh_hit_and_run
  240. sikh_rifle
  241. sioux_dragoon
  242. slavic_stradioti
  243. small_cast_iron_bombard
  244. songhai_tribal_warfare
  245. south_american_arquebusier
  246. south_american_dragoon
  247. south_american_forest_warfare
  248. south_american_gunpowder_warfare
  249. south_american_horsemen
  250. south_american_hussar
  251. south_american_reformed_gunpowder_warfare
  252. south_american_rifle_cavalry
  253. south_american_spearmen
  254. south_american_swarm
  255. south_american_warfare
  256. south_indian_musketeer
  257. spanish_tercio
  258. steppe_cavalry
  259. steppe_footmen
  260. steppe_infantry
  261. steppe_lancers
  262. steppe_mounted_raiders
  263. steppe_musketeers
  264. steppe_raiders
  265. steppe_riders
  266. steppe_rifles
  267. steppe_uhlans
  268. swedish_arme_blanche
  269. swedish_caroline
  270. swedish_gallop
  271. swedish_gustavian
  272. swiss_landsknechten
  273. swivel_cannon
  274. tartar_cossack
  275. threedecker
  276. tipu_sultan_rocket
  277. tofongchis_musketeer
  278. topchis_artillery
  279. trabakul
  280. twodecker
  281. war_galley
  282. wargalleon
  283. western_longbow
  284. western_medieval_infantry
  285. western_medieval_knights
  286. western_men_at_arms
  287. westernized_adal
  288. westernized_aztec
  289. westernized_bantu
  290. westernized_ethiopian
  291. westernized_incan
  292. westernized_mayan
  293. westernized_niger_kongolese
  294. westernized_south_american
  295. westernized_zapotec
  296. zaporoghian_cossack
  297. zapotec_gunpowder_warfare
  298. zapotec_plains_warfare
  299. zapotec_tribal_warfare
  300. zulu_chest_and_horns