kiel_canal = {
	# province it starts in
	start = 1775

	# date built in real life (so anything built during game time will be there if you start a game after that date)
	date = 1895.06.20

	#time to build
	time = {
		months = 120
	}

	#how much to build one
	build_cost = 10000

	#can we move it?
	can_be_moved = no

	#tier that the project starts at when first placed in the game (be that at game start or when built by a country as the game progresses)
	starting_tier = 3

	#project type
	type = canal

	#can we build it?
	build_trigger = {
		FROM = {
			owns_or_vassal_of = 1775
			owns_or_vassal_of = 4141
			is_subject = no
			OR = {
				mission_completed = emp_brapru_kiel_canal
				mission_completed = GER_german_industry
				adm_tech = 22
			}
		}
	}

	#what to do when it's built
	on_built = {
		if = {
			limit = {
				NOT = { has_province_flag = kiel_canal }
			}
			set_province_flag = kiel_canal
			add_canal = kiel_canal
		}
	}

	#what to do when it's destroyed
	on_destroyed = {
		remove_canal = kiel_canal
		clr_province_flag = kiel_canal
	}

	#can our country use it?
	can_use_modifiers_trigger = {
		custom_trigger_tooltip = {
			tooltip = CANAL_IS_NOT_CLOSED
			NOT = { has_province_modifier = canal_closed }
		}
	}

	#can our country upgrade it?
	can_upgrade_trigger = {
	}

	#can our country keep it or is it destroyed when we get hold of it?
	keep_trigger = {
	}

	#tier data
	tier_0 = {
		#time to upgrade to this level (0 for tier 0)
		upgrade_time = {
			months = 0
		}

		#cost to upgrade to this level (0 for tier 0)
		cost_to_upgrade = {
			factor = 0
		}

		#what modifiers are added to the province when we have this project here on this tier
		province_modifiers = {
			province_trade_power_value = 10
		}

		#what modifiers are added to the provinces in the map area when we have this project here on this tier
		area_modifier = {
		}

		#what modifiers are added to the country when we have this project here on this tier
		country_modifiers = {
			global_trade_power = 0.01
		}

		#what effects happen when this tier is achieved
		on_upgraded = {
		}
	}

	tier_1 = {
		#time to upgrade to this level (0 for tier 0)
		upgrade_time = {
			months = 120
		}

		#cost to upgrade to this level (0 for tier 0)
		cost_to_upgrade = {
			factor = 1000
		}

		#what modifiers are added to the province when we have this project here on this tier
		province_modifiers = {
			province_trade_power_value = 20
		}

		#what modifiers are added to the provinces in the map area when we have this project here on this tier
		area_modifier = {
		}

		#what modifiers are added to the country when we have this project here on this tier
		country_modifiers = {
			global_trade_power = 0.02
		}

		#what effects happen when this tier is achieved
		on_upgraded = {
			owner = { add_prestige = 30 }
		}
	}

	tier_2 = {
		#time to upgrade to this level (0 for tier 0)
		upgrade_time = {
			months = 120
		}

		#cost to upgrade to this level (0 for tier 0)
		cost_to_upgrade = {
			factor = 1000
		}

		#what modifiers are added to the province when we have this project here on this tier
		province_modifiers = {
			province_trade_power_value = 30
		}

		#what modifiers are added to the provinces in the map area when we have this project here on this tier
		area_modifier = {
		}

		#what modifiers are added to the country when we have this project here on this tier
		country_modifiers = {
			global_trade_power = 0.03
		}

		#what effects happen when this tier is achieved
		on_upgraded = {
		}
	}

	tier_3 = {
		#time to upgrade to this level (0 for tier 0)
		upgrade_time = {
			months = 120
		}

		#cost to upgrade to this level (0 for tier 0)
		cost_to_upgrade = {
			factor = 1000
		}

		#what modifiers are added to the province when we have this project here on this tier
		province_modifiers = {
			province_trade_power_value = 50
		}

		#what modifiers are added to the provinces in the map area when we have this project here on this tier
		area_modifier = {
		}

		#what modifiers are added to the country when we have this project here on this tier
		country_modifiers = {
			global_trade_power = 0.05
		}

		#what effects happen when this tier is achieved
		on_upgraded = {
		}
		conditional_modifier = {
			trigger = {
				owner = { mission_completed = GER_kiel_canal }
			}
			modifier = {
				merchants = 1
			}
		}
	}
}

suez_canal = {
	# province it starts in
	start = 4316

	# date built in real life (so anything built during game time will be there if you start a game after that date)
	date = 1869.11.17

	#time to build
	time = {
		months = 120
	}

	#how much to build one
	build_cost = 20000

	#can we move it?
	can_be_moved = no

	#tier that the project starts at when first placed in the game (be that at game start or when built by a country as the game progresses)
	starting_tier = 3

	#project type
	type = canal

	#can we build it?
	build_trigger = {
		FROM = {
			owns_or_vassal_of = 4316
			owns_or_vassal_of = 2315
			is_subject = no
			OR = {
				adm_tech = 22
				mission_completed = mam_highway_empire
				mission_completed = hsn_suez_canal
				mission_completed = ITA_explore_eastern_markets
				mission_completed = ven_mamluk_suez
			}
		}
	}

	#what to do when it's built
	on_built = {
		if = {
			limit = {
				NOT = { has_province_flag = suez_canal }
			}
			set_province_flag = suez_canal
			add_canal = suez_canal
		}
	}

	#what to do when it's destroyed
	on_destroyed = {
		remove_canal = suez_canal
		clr_province_flag = suez_canal
	}

	#can our country use it?
	can_use_modifiers_trigger = {
		custom_trigger_tooltip = {
			tooltip = CANAL_IS_NOT_CLOSED
			NOT = { has_province_modifier = canal_closed }
		}
	}

	#can our country upgrade it?
	can_upgrade_trigger = {
	}

	#can our country keep it or is it destroyed when we get hold of it?
	keep_trigger = {
	}

	#tier data
	tier_0 = {
		#time to upgrade to this level (0 for tier 0)
		upgrade_time = {
			months = 0
		}

		#cost to upgrade to this level (0 for tier 0)
		cost_to_upgrade = {
			factor = 0
		}

		#what modifiers are added to the province when we have this project here on this tier
		province_modifiers = {
			province_trade_power_value = 10
		}

		#what modifiers are added to the provinces in the map area when we have this project here on this tier
		area_modifier = {
		}

		#what modifiers are added to the country when we have this project here on this tier
		country_modifiers = {
			global_trade_power = 0.01
		}

		#what effects happen when this tier is achieved
		on_upgraded = {
		}
	}

	tier_1 = {
		#time to upgrade to this level (0 for tier 0)
		upgrade_time = {
			months = 120
		}

		#cost to upgrade to this level (0 for tier 0)
		cost_to_upgrade = {
			factor = 1000
		}

		#what modifiers are added to the province when we have this project here on this tier
		province_modifiers = {
			province_trade_power_value = 20
		}

		#what modifiers are added to the provinces in the map area when we have this project here on this tier
		area_modifier = {
		}

		#what modifiers are added to the country when we have this project here on this tier
		country_modifiers = {
			global_trade_power = 0.02
		}

		conditional_modifier = {
			trigger = {
				custom_trigger_tooltip = {
					tooltip = has_completed_hsn_suez_canal_tt
					owner = {
						mission_completed = hsn_suez_canal
					}
				}
			}
			modifier = {
				global_trade_power = 0.1
			}
		}

		#what effects happen when this tier is achieved
		on_upgraded = {
			owner = { add_prestige = 40 }
		}
	}

	tier_2 = {
		#time to upgrade to this level (0 for tier 0)
		upgrade_time = {
			months = 120
		}

		#cost to upgrade to this level (0 for tier 0)
		cost_to_upgrade = {
			factor = 1000
		}

		#what modifiers are added to the province when we have this project here on this tier
		province_modifiers = {
			province_trade_power_value = 30
		}

		#what modifiers are added to the provinces in the map area when we have this project here on this tier
		area_modifier = {
		}

		#what modifiers are added to the country when we have this project here on this tier
		country_modifiers = {
			global_trade_power = 0.03
		}

		conditional_modifier = {
			trigger = {
				custom_trigger_tooltip = {
					tooltip = has_completed_hsn_suez_canal_tt
					owner = {
						mission_completed = hsn_suez_canal
					}
				}
			}
			modifier = {
				global_trade_power = 0.1
			}
		}

		#what effects happen when this tier is achieved
		on_upgraded = {
		}
	}

	tier_3 = {
		#time to upgrade to this level (0 for tier 0)
		upgrade_time = {
			months = 120
		}

		#cost to upgrade to this level (0 for tier 0)
		cost_to_upgrade = {
			factor = 1000
		}

		#what modifiers are added to the province when we have this project here on this tier
		province_modifiers = {
			province_trade_power_value = 50
		}

		#what modifiers are added to the provinces in the map area when we have this project here on this tier
		area_modifier = {
		}

		#what modifiers are added to the country when we have this project here on this tier
		country_modifiers = {
			global_trade_power = 0.05
		}

		conditional_modifier = {
			trigger = {
				custom_trigger_tooltip = {
					tooltip = has_completed_hsn_suez_canal_tt
					owner = {
						mission_completed = hsn_suez_canal
					}
				}
			}
			modifier = {
				global_trade_power = 0.1
			}
		}
		conditional_modifier = {
			trigger = {
				owner = { mission_completed = ITA_journey_to_the_east }
			}
			modifier = {
				merchants = 1
			}
		}

		#what effects happen when this tier is achieved
		on_upgraded = {
		}
	}
}

panama_canal = {
	# province it starts in
	start = 835

	# date built in real life (so anything built during game time will be there if you start a game after that date)
	date = 1914.08.14

	#time to build
	time = {
		months = 120
	}

	#how much to build one
	build_cost = 30000

	#can we move it?
	can_be_moved = no

	#tier that the project starts at when first placed in the game (be that at game start or when built by a country as the game progresses)
	starting_tier = 3

	#project type
	type = canal

	#can we build it?
	build_trigger = {
		FROM = {
			owns_or_vassal_of = 835
			is_subject = no
			if = {
				limit = {
					NOT = { mission_completed = SUN_panama_canal }
					NOT = { mission_completed = SUNm_panama_canal }
				}
				adm_tech = 22
			}
		}
	}

	#what to do when it's built
	on_built = {
		if = {
			limit = {
				NOT = { has_province_flag = panama_canal }
			}
			set_province_flag = panama_canal
			add_canal = panama_canal
		}
	}

	#what to do when it's destroyed
	on_destroyed = {
		remove_canal = panama_canal
		clr_province_flag = panama_canal
	}

	#can our country use it?
	can_use_modifiers_trigger = {
		custom_trigger_tooltip = {
			tooltip = CANAL_IS_NOT_CLOSED
			NOT = { has_province_modifier = canal_closed }
		}
	}

	#can our country upgrade it?
	can_upgrade_trigger = {
	}

	#can our country keep it or is it destroyed when we get hold of it?
	keep_trigger = {
	}

	#tier data
	tier_0 = {
		#time to upgrade to this level (0 for tier 0)
		upgrade_time = {
			months = 0
		}

		#cost to upgrade to this level (0 for tier 0)
		cost_to_upgrade = {
			factor = 0
		}

		#what modifiers are added to the province when we have this project here on this tier
		province_modifiers = {
			province_trade_power_value = 10
		}

		#what modifiers are added to the provinces in the map area when we have this project here on this tier
		area_modifier = {
		}

		#what modifiers are added to the country when we have this project here on this tier
		country_modifiers = {
			global_trade_power = 0.01
		}

		#what effects happen when this tier is achieved
		on_upgraded = {
		}
	}

	tier_1 = {
		#time to upgrade to this level (0 for tier 0)
		upgrade_time = {
			months = 120
		}

		#cost to upgrade to this level (0 for tier 0)
		cost_to_upgrade = {
			factor = 1000
		}

		#what modifiers are added to the province when we have this project here on this tier
		province_modifiers = {
			province_trade_power_value = 20
		}

		#what modifiers are added to the provinces in the map area when we have this project here on this tier
		area_modifier = {
		}

		#what modifiers are added to the country when we have this project here on this tier
		country_modifiers = {
			global_trade_power = 0.02
		}

		#what effects happen when this tier is achieved
		on_upgraded = {
			owner = { add_prestige = 50 }
		}
	}

	tier_2 = {
		#time to upgrade to this level (0 for tier 0)
		upgrade_time = {
			months = 120
		}

		#cost to upgrade to this level (0 for tier 0)
		cost_to_upgrade = {
			factor = 1000
		}

		#what modifiers are added to the province when we have this project here on this tier
		province_modifiers = {
			province_trade_power_value = 30
		}

		#what modifiers are added to the provinces in the map area when we have this project here on this tier
		area_modifier = {
		}

		#what modifiers are added to the country when we have this project here on this tier
		country_modifiers = {
			global_trade_power = 0.03
		}

		#what effects happen when this tier is achieved
		on_upgraded = {
		}
	}

	tier_3 = {
		#time to upgrade to this level (0 for tier 0)
		upgrade_time = {
			months = 120
		}

		#cost to upgrade to this level (0 for tier 0)
		cost_to_upgrade = {
			factor = 1000
		}

		#what modifiers are added to the province when we have this project here on this tier
		province_modifiers = {
			province_trade_power_value = 50
		}

		#what modifiers are added to the provinces in the map area when we have this project here on this tier
		area_modifier = {
		}

		#what modifiers are added to the country when we have this project here on this tier
		country_modifiers = {
			global_trade_power = 0.05
		}

		conditional_modifier = {
			trigger = {
				owner = {
					custom_trigger_tooltip = {
						tooltip = SUN_completed_panama_canal_mission
						OR = {
							mission_completed = SUN_panama_canal
							mission_completed = SUNm_panama_canal
						}
					}
				}
			}
			modifier = {
				reduced_trade_penalty_on_non_main_tradenode = 0.5
				trade_efficiency = 0.05
			}
		}

		#what effects happen when this tier is achieved
		on_upgraded = {
		}
	}
}
