upgrades = {

	tank_nsb_engine_upgrade = {
		abbreviation = "eng"
		max_level = 35 #each level represents ~50HP
		cost = land

		linear_cost = {
			cost_by_level = 1
			cost_by_level_for_licensed_equipment = 5
		}

		level_requirements = {
			5 = {
				has_tech = engine_tech_1
			}
			10 = {
				has_tech = engine_tech_2
			}
			15 = {
				has_tech = engine_tech_3
			}
			18 = { 
				has_tech = engine_tech_4
			}
			21 = { 
				has_tech = engine_tech_5
			}
			24 = { 
				has_tech = engine_tech_6
			}
			27 = { 
				has_tech = engine_tech_7
			}
			30 = { 
				has_tech = engine_tech_8
			}
		}

		resource_cost_thresholds = {
			10 = { #higher level engines do require more strategic resources
#				chromium = 1
			}
#			20 = {
#				chromium = 2
#		}
#			30 = {
#				chromium = 3
#			}
		}
#		maximum_speed = 0.1

		#maximum_speed = 0.1
		reliability = -0.015
		add_stats = {
			fuel_consumption = 0.05
			build_cost_ic = 0.1
			maximum_speed = 0.1
		}
	}

	tank_nsb_armor_upgrade = {
		abbreviation = "arm"
		max_level = 35 #each level represents ~10mm of armor 
		cost = land

		linear_cost = {
			cost_by_level = 1
			cost_by_level_for_licensed_equipment = 2
		}

		level_requirements = {
			5 = {
				has_tech = armor_tech_1
			}
			10 = {
				has_tech = armor_tech_2
			}
			15 = {
				has_tech = armor_tech_3
			}
			18 = {
				has_tech = armor_tech_4
			}
			21 = {
				has_tech = armor_tech_5
			}
			24 = {
				has_tech = armor_tech_6
			}
			27 = {
				has_tech = armor_tech_7
			}
			30 = {
				has_tech = armor_tech_8
			}
		}

		resource_cost_thresholds = { # resource values defined here are TOTAL added cost, not cumulative
			5 = { #more armor requires more resources
				steel = 1 
			}
			10 = {
				steel = 1
#				chromium = 1
			}
			15 = {
				steel = 1
#				chromium = 2
			}
			20 = {
				steel = 1
#				chromium = 2
			}
			25 = {
				steel = 1
#				chromium = 2
			}
			30 = {
				steel = 1
#				chromium = 2
			}
		}

		reliability = -0.015
		#armor_value = 0.085
		add_stats = {
			maximum_speed = -0.1
			breakthrough = 1.25
			build_cost_ic = 0.2
			armor_value = 2.5

		}
	}

	tank_gun_upgrade = {
		max_level = 5

		cost = land				# This determies how much XP it will cost, controlled by defines, there are 3 cost types: air, land and naval
		soft_attack = 0.03
		hard_attack = 0.1
		ap_attack = 0.05
		maximum_speed = -0.02
		reliability = -0.05
		build_cost_ic = 0.05
	}
	tank_armor_upgrade = {
		max_level = 5

		cost = land
		armor_value = 0.05
		maximum_speed = -0.02
		reliability = -0.05
		build_cost_ic = 0.05
	}
	tank_engine_upgrade = {
		max_level = 5
		cost = land
		maximum_speed = 0.04
		build_cost_ic = 0.05
	}	
	ac_engine_upgrade = {
		max_level = 5
		cost = land
		maximum_speed = 0.02
	}	
	tank_reliability_upgrade = {
		max_level = 5
		cost = land
		reliability = 0.1
		build_cost_ic = 0.05
	}
	mech_cost_upgrade = {
		max_level = 5
		cost = land
		build_cost_ic = -0.1
		reliability = -0.05
	}
	tank_aa_upgrade = {
		max_level = 5

		cost = land
		air_attack = 0.15
		maximum_speed = -0.02
		reliability = -0.05
	}
	tank_at_upgrade = {
		max_level = 5

		cost = land
		soft_attack = 0.1
		hard_attack = 0.1
		ap_attack = 0.05
		maximum_speed = -0.02
		reliability = -0.05
	}
	tank_art_upgrade = {
		max_level = 5

		cost = land
		soft_attack = 0.03
		maximum_speed = -0.02
		reliability = -0.05
	}

	tank_AT_reliability_upgrade = {
		max_level = 40
		cost = land

		linear_cost = {
			cost_by_level = 1
			cost_by_level_for_licensed_equipment = 5
		}

		level_requirements = {
			1 = {  #1936
				has_tech = basic_machine_tools
			}
			5 = { #1941
				has_tech = assembly_line_production
			}
			10 = { #1943
				has_tech = machine_tools5
			}
			15 = { #1945
				has_tech = machine_tools6
			}
			20 = { #1949
				has_tech = machine_tools8
			}
			25 = { #1955
				has_tech = machine_tools11
			}
			30 = { #1959
				has_tech = machine_tools13
			}
			35 = { #1963
				has_tech = machine_tools15
			}
		}

		add_stats = {
			reliability = 0.05
			build_cost_ic = 0.1
		}
	}


}
