Provinces along a trade route 享受地方税收、移动速度和技术传播的加成。沿贸易路线的某些省份也可以建造 trade posts,这些为省的所有者提供贸易收入。贸易路线的路线定义在 /common/trade_routes/ folder.
贸易路线的加成、起点、航线和主要停靠点必须.txt由 /common/trade_routes/ folder. As an example:
trier_tree_trade = {
wealth = 100 # Multiplier for other modifiers. Modifiers calculated as (Wealth * modifier)/# of trade provinces.
trade_post_display_trigger = {# Determines which provinces will have the Potential Trade Post tool-tip.
OR = {
province_id = 127 #Lorraine
province_id = 118 #Trier
}
}
modifier = { # Modifiers applied to each province on a trade route.
castle_tax_modifier = 0.01 # Percentage multiplier applied to tax income for castle holdings in a province
city_tax_modifier = 0.01 # Percentage multiplier applied to tax income for city holdings in a province.
temple_tax_modifier = 0.01 # Percentage multiplier applied to tax income for temple holdings in a province.
tribal_tax_modifier = 0.01 # Percentage multiplier applied to tax income for tribal holdings in a province.
trade_route_value = 2.5 # Modifier used to determine base trade route income for a trade post on a province.
local_movement_speed = 0.025 # Percentage multiplier applied to movement speed of troops through a province.
tech_growth_modifier = 0.025 # Percentage multiplier for technology spread between provinces.
icon = 4 # Sets the icon displayed for the province modifier, in this case the Stewardship icon.
}
start = { # Starting province for the trade route. Trade flows from this province to all other provinces connected downstream.
127 # Lorraine
}
path = { # Creates a connection between either a starting province or an already defined end province of a previous path.
127 128 118 # Lorraine - Metz - Trier
}
}
该代码的最终成果——特里尔树贸易,是一条从洛林出发,经过梅斯,终点为特里尔的贸易路线,为当地收入提供33.3%的加成,本地移动速度和技术传播有83.3%的加成,沿贸易路线建设的贸易站可获得83.3的基础收入。
现在特里尔树贸易已经定义,可以添加本地化功能来更改省份修正词的名称。创建.csv文件 /localisation/ will add a localization for the trade route:
trier_tree_trade;Trier Tree Trade;;;;;;;;;;;;;x
最后,需要脚本触发条件允许在潜在贸易站县内建设贸易站。创建.txt文件 /common/scripted_triggers/, and add a trade route post trigger:
trade_route_post_trigger = { custom_tooltip = { 文本 = trade_route_province_desc hidden_tooltip = { OR = { province_id = 127 # 洛林 province_id = 118 # 特里尔 } } } }
特里尔贸易树现已完成——其省份修正值生效,可以在洛林和特里尔建造贸易站,名称也已正确本地化,可在游戏内显示。
路径连接起始省份或先前定义的终省与新的终点省份。这些省份不必相邻。两者兼具 path = { 127 128 118} and path = { 127 118} 是有效的。路径不能连接已存在路径中定义的省份,该路径为 not the end province of that path. As an example:
path = { 127 128 118 } # Lorraine - Metz - Trier
path = { 128 123 } # Metz - Mainz
梅斯至美因茨之间的第二条路线无效。为了创建一条有效连接梅斯和美因茨的路径,梅斯必须是现有路径的终点省份:
path = { 127 128} # Lorraine - Metz path = { 128 118} # Metz - Trier path = { 128 123} # Metz - Mainz
路径中的省份也可以是非县级省份,比如主要河流和海域地块。这些省份和县的路径规则同样适用。这些非县级省份的身份证可在以下地区找到 /map/definition.csv 举例来说,为从特里尔到荷兰的莱茵河贸易添加一条通道:
path = { 127 128} # Lorraine - Metz path = { 128 118} # Metz - Trier path = { 128 123} # Metz - Mainz path = { 118 1045 1043 1044 80 } # Trier - Rhine River - Holland