### New Repeatable Techs ###

#Engineering                     Physics                     Society
#Alloys +3% (max 15%)            Motes +10%                  +3 Basic jobs/40 pops
#Rare Crystals +10%              Planet Maintenance -5%        (job specialization)
#Exotic Gases +10%                 max -25%                  +2 Processing Jobs/40 pops
#Station Production +10%         Ship Maintenance -5%          (job specialization)
#Ship Hull +5%                     max -25%                  +2 Military Jobs/40 pops
#Disengage Chance +5%           Damage to Shields +5%         (job specialization)
#  max 25% (tactical focus)        (weapons focus)           Terraforming cost -5%
#Sublight Speed +5%             Damage to Armor +5%           max -25%
#  max 25%                        (weapons focus)           Pop Growth +5%
#Evasion +5%                     Damage to Hull +5%            max +50%
#  max 50%, multiplicative         (weapons focus)           Pop Assembly +5%
#Titan Hull +1000                Small Ship Cost -5%           max +50%
#                                  max -25% (ship focus)     Housing +3
#                                Captial Ship Cost -5%       Fire Rate +2%
#                                  max -25% (ship focus)     Force Disparity Combat Bonus +5%
#                                Ship Build Speed -5%         max 25%(tactical focus)
#                                  max -25%                  Collateral/Morale Damage +10%
#                                Trade Value +5%              (exclusive with collateral reduction)
#                                Tracking +2, max +10        Collateral Reduction -05% /Trust Cap +10
#                                Sensor Range +1               (exclusive) max -100%
                                


@EarlyRepeatableTechCost = 50000
@EarlyRepeatableTechLevelCost = 5000
@EarlyRepatableTechFactor = 0.5
@RepeatableCategoryFactor = 0.01
@RepeatableDifferntFactor = 0.05
@EarlyRepeatableWeight = 12.5
@EarlyRepeatableTier = 5
@SpecializationPenalty = 0.6
@SpecializationLevel = 0.75

tech_repeatable_improved_alloy_output = {
	area = engineering
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
    category = { industry }
    prerequisites = { "tech_alloys_2" }
	levels = 5

	weight = @EarlyRepeatableWeight

	weight_modifier = {
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_alloys value > 0 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_alloys value > 1 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_alloys value > 2 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_alloys value > 3 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_alloys value > 4 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_alloys value > 5 }
		}
	}   

	ai_weight = {
		factor = 1.0
    }
    weight_groups = {
		production_repeatable
	}
	mod_weight_if_group_picked = {
		production_repeatable = @RepeatableCategoryFactor
		ship_repeatable = @RepeatableDifferntFactor
		job_repeatable = @RepeatableDifferntFactor
	}
	modifier = {
		planet_jobs_alloys_produces_mult = 0.03
	}
}

tech_repeatable_improved_station_output = {
	area = engineering
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
    category = { industry }
    prerequisites = { "tech_space_mining_5" }
	levels = -1

    weight = @EarlyRepeatableWeight
    
	weight_modifier = {
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_station_output value > 0 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_station_output value > 1 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_station_output value > 2 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_station_output value > 3 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_station_output value > 4 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_station_output value > 5 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_station_output value > 6 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_station_output value > 7 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_station_output value > 8 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_station_output value > 9 }
		}
	}	
	ai_weight = {
		factor = 1.0
    }
    weight_groups = {
		production_repeatable
	}
	mod_weight_if_group_picked = {
		production_repeatable = @RepeatableCategoryFactor
    }
    mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableDifferntFactor
		job_repeatable = @RepeatableDifferntFactor
	}
	modifier = {
		station_gatherers_produces_mult = 0.10
	}
}

tech_repeatable_improved_motes_output = {
	area = physics
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
    category = { materials }
    prerequisites = { "tech_volatile_motes" }
	levels = -1

    weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_motes_output value > 0 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_motes_output value > 1 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_motes_output value > 2 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_motes_output value > 3 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_motes_output value > 4 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_motes_output value > 5 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_motes_output value > 6 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_motes_output value > 7 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_motes_output value > 8 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_motes_output value > 9 }
		}
	} 
	
	ai_weight = {
		factor = 1.0
    }
    
    weight_groups = {
		production_repeatable
	}
	mod_weight_if_group_picked = {
		production_repeatable = @RepeatableCategoryFactor
    }
    mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableDifferntFactor
		job_repeatable = @RepeatableDifferntFactor
	}
	modifier = {
		planet_jobs_volatile_motes_produces_mult = 0.10
	}
}

tech_repeatable_improved_gases_output = {
	area = engineering
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
    category = { materials }
    prerequisites = { "tech_exotic_gases" }
	levels = -1

    weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_gases_output value > 0 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_gases_output value > 1 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_gases_output value > 2 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_gases_output value > 3 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_gases_output value > 4 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_gases_output value > 5 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_gases_output value > 6 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_gases_output value > 7 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_gases_output value > 8 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_gases_output value > 9 }
		}
	} 
	
	ai_weight = {
		factor = 1.0
    }
    
    weight_groups = {
		production_repeatable
	}
	mod_weight_if_group_picked = {
		production_repeatable = @RepeatableCategoryFactor
    }
    mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableDifferntFactor
		job_repeatable = @RepeatableDifferntFactor
	}
	modifier = {
		planet_jobs_exotic_gases_produces_mult = 0.10
	}
}

tech_repeatable_improved_crystals_output = {
	area = engineering
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
    category = { materials }
    prerequisites = { "tech_rare_crystals" }
	levels = -1

    weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_crystals_output value > 0 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_crystals_output value > 1 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_crystals_output value > 2 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_crystals_output value > 3 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_crystals_output value > 4 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_crystals_output value > 5 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_crystals_output value > 6 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_crystals_output value > 7 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_crystals_output value > 8 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_crystals_output value > 9 }
		}
	}
	
	ai_weight = {
		factor = 1.0
    }
    
    weight_groups = {
		production_repeatable
	}
	mod_weight_if_group_picked = {
		production_repeatable = @RepeatableCategoryFactor
    }
    mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableDifferntFactor
		job_repeatable = @RepeatableDifferntFactor
	}
	modifier = {
		planet_jobs_rare_crystals_produces_mult = 0.10
	}
}

tech_repeatable_improved_ship_health = {
	area = engineering
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
	category = { voidcraft }
	levels = -1
	prerequisites = { "tech_cruisers" }
	weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_health value > 0 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_health value > 1 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_health value > 2 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_health value > 3 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_health value > 4 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_health value > 5 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_health value > 6 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_health value > 7 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_health value > 8 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_health value > 9 }
		}
	}
	ai_weight = {
		factor = 1.0
	}	
	weight_groups = {
		ship_repeatable
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableCategoryFactor
    }
    mod_weight_if_group_picked = {
		production_repeatable = @RepeatableDifferntFactor
		job_repeatable = @RepeatableDifferntFactor
	}	
	modifier = {
		ship_hull_mult = 0.05
	}
}

tech_repeatable_improved_ship_escape = {
	area = engineering
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
	category = { voidcraft }
	levels = 5
	prerequisites = { "tech_thrusters_3" }
	weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_ship_escape value > 0 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_ship_escape value > 1 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_ship_escape value > 2 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_ship_escape value > 3 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_ship_escape value > 4 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_ship_escape value > 5 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_force_disparity value > 0 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_force_disparity value > 1 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_force_disparity value > 2 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_force_disparity value > 3 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_force_disparity value > 4 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_force_disparity value > 5 }
		}
	}

	potential = {
		NOT = { is_country_type = fallen_empire }
	}

	prereqfor_desc = {
		custom = {
			title = "escape_focus"
			desc = "escape_focus_desc"
		}
	}

	ai_weight = {
		factor = 1.0
	}	
	weight_groups = {
		ship_repeatable
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableCategoryFactor
    }	
    mod_weight_if_group_picked = {
		production_repeatable = @RepeatableDifferntFactor
		job_repeatable = @RepeatableDifferntFactor
	}
	modifier = {
    ship_disengage_chance_mult = 0.05
	}
}



tech_repeatable_improved_ship_speed = {
	area = engineering
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
    tier = @EarlyRepeatableTier
    prerequisites = { "tech_afterburners_2" }
	category = { propulsion }
	levels = 5

    weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_speed value > 0 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_speed value > 1 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_speed value > 2 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_speed value > 3 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_speed value > 4 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_speed value > 5 }
		}
	}

	potential = {
		NOT = { is_country_type = fallen_empire }
	}
	
	ai_weight = {
		factor = 1.0
    }
    
    weight_groups = {
		ship_repeatable
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableCategoryFactor
    }
    mod_weight_if_group_picked = {
		production_repeatable = @RepeatableDifferntFactor
		job_repeatable = @RepeatableDifferntFactor
	}
	modifier = {
		ship_speed_mult = 0.05
	}
}

tech_repeatable_improved_ship_evasion = {
	area = engineering
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
    category = { propulsion }
    prerequisites = { "tech_strike_craft_3" }
	levels = 10

    weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_evasion value > 0 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_evasion value > 1 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_evasion value > 2 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_evasion value > 3 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_evasion value > 4 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_evasion value > 5 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_evasion value > 6 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_evasion value > 7 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_evasion value > 8 }
		}
	}

	potential = {
		NOT = { is_country_type = fallen_empire }
	}
	
	ai_weight = {
		factor = 1.0
    }
    
    weight_groups = {
		ship_repeatable
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableCategoryFactor
    }
    mod_weight_if_group_picked = {
		production_repeatable = @RepeatableDifferntFactor
		job_repeatable = @RepeatableDifferntFactor
	}
	modifier = {
		ship_evasion_mult = 0.05
	}
}

tech_repeatable_improved_shield_damage = {
	area = physics
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
    category = { field_manipulation }
    prerequisites = { "tech_mass_drivers_4" }
	levels = -1

    weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_shield_damage value > 0 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_shield_damage value > 1 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_shield_damage value > 2 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_shield_damage value > 3 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_shield_damage value > 4 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_shield_damage value > 5 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_shield_damage value > 6 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_shield_damage value > 7 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_shield_damage value > 8 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_shield_damage value > 9 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_hull_damage value > 0 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_hull_damage value > 1 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_hull_damage value > 2 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_hull_damage value > 3 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_hull_damage value > 4 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_hull_damage value > 5 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_hull_damage value > 6 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_hull_damage value > 7 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_hull_damage value > 8 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_hull_damage value > 9 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_armor_damage value > 0 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_armor_damage value > 1 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_armor_damage value > 2 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_armor_damage value > 3 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_armor_damage value > 4 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_armor_damage value > 5 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_armor_damage value > 6 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_armor_damage value > 7 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_armor_damage value > 8 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_armor_damage value > 9 }
		}
	}
	
	ai_weight = {
		factor = 1.0
    }
	
	potential = {
		NOT = { is_country_type = fallen_empire }
	}

	prereqfor_desc = {
		custom = {
			title = "specialization_shields"
			desc = "specialization_shields_desc"
		}
	}
	
    weight_groups = {
		ship_repeatable
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableCategoryFactor
    }
    mod_weight_if_group_picked = {
		production_repeatable = @RepeatableDifferntFactor
		job_repeatable = @RepeatableDifferntFactor
	}
	modifier = {
		ship_shield_damage_mult = 0.05
	}
}

tech_repeatable_improved_armor_damage = {
	area = physics
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
    category = { particles }
    prerequisites = { "tech_lasers_4" }
	levels = -1

    weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_shield_damage value > 0 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_shield_damage value > 1 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_shield_damage value > 2 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_shield_damage value > 3 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_shield_damage value > 4 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_shield_damage value > 5 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_shield_damage value > 6 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_shield_damage value > 7 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_shield_damage value > 8 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_shield_damage value > 9 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_hull_damage value > 0 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_hull_damage value > 1 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_hull_damage value > 2 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_hull_damage value > 3 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_hull_damage value > 4 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_hull_damage value > 5 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_hull_damage value > 6 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_hull_damage value > 7 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_hull_damage value > 8 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_hull_damage value > 9 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_armor_damage value > 0 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_armor_damage value > 1 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_armor_damage value > 2 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_armor_damage value > 3 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_armor_damage value > 4 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_armor_damage value > 5 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_armor_damage value > 6 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_armor_damage value > 7 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_armor_damage value > 8 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_armor_damage value > 9 }
		}
	}

	potential = {
		NOT = { is_country_type = fallen_empire }
	}

	prereqfor_desc = {
		custom = {
			title = "specialization_armor"
			desc = "specialization_armor_desc"
		}
	}

	ai_weight = {
		factor = 1.0
    }
    
    weight_groups = {
		ship_repeatable
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableCategoryFactor
    }
    mod_weight_if_group_picked = {
		production_repeatable = @RepeatableDifferntFactor
		job_repeatable = @RepeatableDifferntFactor
	}
	modifier = {
		ship_armor_damage_mult = 0.05
	}
}

tech_repeatable_improved_hull_damage = {
	area = physics
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
    category = { particles }
    prerequisites = { "tech_missiles_4" }
	levels = -1

    weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_shield_damage value > 0 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_shield_damage value > 1 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_shield_damage value > 2 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_shield_damage value > 3 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_shield_damage value > 4 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_shield_damage value > 5 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_shield_damage value > 6 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_shield_damage value > 7 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_shield_damage value > 8 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_shield_damage value > 9 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_hull_damage value > 0 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_hull_damage value > 1 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_hull_damage value > 2 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_hull_damage value > 3 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_hull_damage value > 4 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_hull_damage value > 5 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_hull_damage value > 6 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_hull_damage value > 7 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_hull_damage value > 8 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_hull_damage value > 9 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_armor_damage value > 0 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_armor_damage value > 1 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_armor_damage value > 2 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_armor_damage value > 3 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_armor_damage value > 4 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_armor_damage value > 5 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_armor_damage value > 6 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_armor_damage value > 7 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_armor_damage value > 8 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_armor_damage value > 9 }
		}
	}
	
	potential = {
		NOT = { is_country_type = fallen_empire }
	}

	prereqfor_desc = {
		custom = {
			title = "specialization_hull"
			desc = "specialization_hull_desc"
		}
	}

	ai_weight = {
		factor = 1.0
    }
    
    weight_groups = {
		ship_repeatable
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableCategoryFactor
    }
    mod_weight_if_group_picked = {
		production_repeatable = @RepeatableDifferntFactor
		job_repeatable = @RepeatableDifferntFactor
	}
	modifier = {
		ship_hull_damage_mult = 0.05
	}
}

tech_repeatable_reduced_building_maintenance = {
	area = physics
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
	category = { computing }
	levels = 5
	prerequisites = { "tech_construction_templates" }
	weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_building_maintenance value > 0 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_building_maintenance value > 1 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_building_maintenance value > 2 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_building_maintenance value > 3 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_building_maintenance value > 4 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_building_maintenance value > 5 }
		}
	}

	potential = {
		NOT = { is_country_type = fallen_empire }
	}
	
	ai_weight = {
		factor = 1.0
	}
	
	weight_groups = {
		production_repeatable
	}
	mod_weight_if_group_picked = {
		production_repeatable = @RepeatableCategoryFactor
    }
    mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableDifferntFactor
		job_repeatable = @RepeatableDifferntFactor
	}
	
	modifier = {
        planet_buildings_upkeep_mult = -0.05
		starbases_upkeep_mult = -0.05
		planet_districts_upkeep_mult = -0.05
	}
}

tech_repeatable_reduced_ship_maintenance = {
	area = physics
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
	category = { voidcraft }
	levels = 5
	prerequisites = { "tech_antimatter_power" }
	weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_maintenance value > 0 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_maintenance value > 1 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_maintenance value > 2 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_maintenance value > 3 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_maintenance value > 4 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_maintenance value > 5 }
		}
	}

	potential = {
		NOT = { is_country_type = fallen_empire }
	}
	
	ai_weight = {
		factor = 1.0
	}
	
	weight_groups = {
		production_repeatable
	}
	mod_weight_if_group_picked = {
		production_repeatable = @RepeatableCategoryFactor
    }
    mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableDifferntFactor
		job_repeatable = @RepeatableDifferntFactor
	}
	
	modifier = {
        ships_upkeep_mult = -0.05
    }
}

tech_repeatable_reduced_ship_cost_small = {
	area = physics
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
	category = { voidcraft }
	levels = 5
	prerequisites = { "tech_destroyer_hull_2" }
	weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_ship_cost_small value > 0 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_ship_cost_small value > 1 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_ship_cost_small value > 2 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_ship_cost_small value > 3 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_ship_cost_small value > 4 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_ship_cost_small value > 5 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_cost_large value > 0 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_cost_large value > 1 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_cost_large value > 2 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_cost_large value > 3 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_cost_large value > 4 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_cost_large value > 5 }
		}
	}

	potential = {
		NOT = { is_country_type = fallen_empire }
	}

	prereqfor_desc = {
		custom = {
			title = "specialization_support"
			desc = "specialization_support_desc"
		}
	}
	
	ai_weight = {
		factor = 1.0
	}
	
	weight_groups = {
		production_repeatable
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableDifferntFactor
    }
    mod_weight_if_group_picked = {
		production_repeatable = @RepeatableCategoryFactor
		job_repeatable = @RepeatableDifferntFactor
	}
	
	modifier = {
        ship_corvette_cost_mult = -0.05
        ship_destroyer_cost_mult = -0.05
    }
}


tech_repeatable_reduced_ship_cost_large = {
	area = physics
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
	category = { voidcraft }
	levels = 5
	prerequisites = { "tech_cruiser_hull_1" }
	weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_ship_cost_large value > 0 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_ship_cost_large value > 1 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_ship_cost_large value > 2 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_ship_cost_large value > 3 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_ship_cost_large value > 4 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_ship_cost_large value > 5 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_cost_small value > 0 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_cost_small value > 1 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_cost_small value > 2 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_cost_small value > 3 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_cost_small value > 4 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_cost_small value > 5 }
		}
	}

	potential = {
		NOT = { is_country_type = fallen_empire }
	}

	prereqfor_desc = {
		custom = {
			title = "specialization_capital"
			desc = "specialization_capital_desc"
		}
	}
	
	ai_weight = {
		factor = 1.0
	}
	
	weight_groups = {
		production_repeatable
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableDifferntFactor
    }
    mod_weight_if_group_picked = {
		production_repeatable = @RepeatableCategoryFactor
		job_repeatable = @RepeatableDifferntFactor
	}
	
	modifier = {
        ship_cruiser_cost_mult = -0.05
        ship_battleship_cost_mult = -0.05
    }
}

tech_repeatable_improved_titan = {
	area = engineering
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
	category = { voidcraft }
	levels = -1
	prerequisites = { "tech_titans" }
	weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_titan_hull value > 0 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_titan_hull value > 1 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_titan_hull value > 2 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_titan_hull value > 3 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_titan_hull value > 4 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_titan_hull value > 5 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_titan_hull value > 6 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_titan_hull value > 7 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_titan_hull value > 8 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_titan_hull value > 9 }
		}
	}

	potential = {
		NOT = { is_country_type = fallen_empire }
	}
	
	ai_weight = {
		factor = 1.0
	}
	
	weight_groups = {
		ship_repeatable
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableCategoryFactor
    }
    mod_weight_if_group_picked = {
		production_repeatable = @RepeatableDifferntFactor
		job_repeatable = @RepeatableDifferntFactor
	}
	
	modifier = {
        shipsize_titan_hull_add = 1000
    }
}

tech_repeatable_ship_build_speed = {
	area = physics
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
	category = { computing }
	levels = 5
	prerequisites = { "tech_basic_science_lab_3" }
	weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_build_speed value > 0 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_build_speed value > 1 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_build_speed value > 2 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_build_speed value > 3 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_build_speed value > 4 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_build_speed value > 5 }
		}
	}

	potential = {
		NOT = { is_country_type = fallen_empire }
	}
	
	ai_weight = {
		factor = 1.0
	}
	
	weight_groups = {
		ship_repeatable
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableCategoryFactor
    }
    mod_weight_if_group_picked = {
		production_repeatable = @RepeatableDifferntFactor
		job_repeatable = @RepeatableDifferntFactor
	}
	
	modifier = {
        starbase_shipyard_build_speed_mult   = 0.05
    }
}

tech_repeatable_trade_value = {
	area = physics
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
	category = { computing }
	levels = -1
	prerequisites = { "tech_interstellar_economics" }
	weight = @EarlyRepeatableWeight

	potential = {
       	is_gestalt = no
	}	
	weight_modifier = {
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_trade_value value > 0 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_trade_value value > 1 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_trade_value value > 2 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_trade_value value > 3 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_trade_value value > 4 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_trade_value value > 5 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_trade_value value > 6 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_trade_value value > 7 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_trade_value value > 8 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_trade_value value > 9 }
		}
	}
	
	ai_weight = {
		factor = 1.0
	}
	
	weight_groups = {
		production_repeatable
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableDifferntFactor
    }
    mod_weight_if_group_picked = {
		production_repeatable = @RepeatableCategoryFactor
		job_repeatable = @RepeatableDifferntFactor
	}
	
	modifier = {
        trade_value_mult   = 0.05
    }
}

tech_repeatable_sensors = {
	area = physics
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
	category = { computing }
	levels = 5
	prerequisites = { "tech_sensors_4" }
	weight = @EarlyRepeatableWeight

	weight_modifier = {
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_sensors value > 0 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_sensors value > 1 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_sensors value > 2 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_sensors value > 3 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_sensors value > 4 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_sensors value > 5 }
		}
	}

	potential = {
		NOT = { is_country_type = fallen_empire }
	}
	
	ai_weight = {
		factor = 1.0
	}
	
	weight_groups = {
		ship_repeatable
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableCategoryFactor
    }
    mod_weight_if_group_picked = {
		production_repeatable = @RepeatableDifferntFactor
		job_repeatable = @RepeatableDifferntFactor
	}
	
	modifier = {
		planet_sensor_range_add = 2
		ship_sensor_range_add = 1
		ship_tracking_add = 2
    }
}

tech_repeatable_farmer_jobs = {
	area = society
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
	category = { statecraft }
	levels = 5
	prerequisites = { "tech_global_production_strategy" }
	weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 0 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 1 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 2 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 3 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 4 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 5 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 6 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 7 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 8 }
		}
		modifier = {
			factor = 0
			check_variable = { which = repeatable_jobs value > 9 }
		}
	}

	potential = {
		is_gestalt = no
		is_country_type = default
	}

	prereqfor_desc = {
		custom = {
			title = "specialization_job"
			desc = "specialization_job_desc"
		}
	}
	
	ai_weight = {
		factor = 1.0
	}
	
	weight_groups = {
		job_repeatable
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableDifferntFactor
    }
  mod_weight_if_group_picked = {
		production_repeatable = @RepeatableDifferntFactor
	}
	mod_weight_if_group_picked = {
		job_repeatable = 0
	}
	
	modifier = {
        job_farmer_per_pop = 0.02
    }
}

tech_repeatable_miner_jobs = {
	area = society
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
	category = { statecraft }
	levels = 5
	prerequisites = { "tech_global_production_strategy" }
	weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 0 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 1 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 2 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 3 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 4 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 5 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 6 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 7 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 8 }
		}
		modifier = {
			factor = 0
			check_variable = { which = repeatable_jobs value > 9 }
		}
	}

	potential = {
		is_gestalt = no
		is_country_type = default
	}

	prereqfor_desc = {
		custom = {
			title = "specialization_job"
			desc = "specialization_job_desc"
		}
	}
	
	ai_weight = {
		factor = 1.0
	}
	
	weight_groups = {
		job_repeatable
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableDifferntFactor
    }
  mod_weight_if_group_picked = {
		production_repeatable = @RepeatableDifferntFactor
	}
	mod_weight_if_group_picked = {
		job_repeatable = 0
	}
	
	modifier = {
        job_miner_per_pop = 0.02
    }
}

tech_repeatable_technician_jobs = {
	area = society
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
	category = { statecraft }
	levels = 5
	prerequisites = { "tech_global_production_strategy" }
	weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 0 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 1 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 2 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 3 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 4 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 5 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 6 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 7 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 8 }
		}
		modifier = {
			factor = 0
			check_variable = { which = repeatable_jobs value > 9 }
		}
	}

	potential = {
		is_gestalt = no
		is_country_type = default
	}

	prereqfor_desc = {
		custom = {
			title = "specialization_job"
			desc = "specialization_job_desc"
		}
	}
	
	ai_weight = {
		factor = 1.0
	}
	
	weight_groups = {
		job_repeatable
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableDifferntFactor
    }
  mod_weight_if_group_picked = {
		production_repeatable = @RepeatableDifferntFactor
	}
	mod_weight_if_group_picked = {
		job_repeatable = 0
	}
	
	modifier = {
        job_technician_per_pop = 0.02
    }
}

tech_repeatable_clerk_jobs = {
	area = society
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
	category = { statecraft }
	levels = 5
	prerequisites = { "tech_global_production_strategy" }
	weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 0 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 1 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 2 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 3 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 4 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 5 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 6 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 7 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 8 }
		}
		modifier = {
			factor = 0
			check_variable = { which = repeatable_jobs value > 9 }
		}
	}

	potential = {
		is_gestalt = no
		is_country_type = default
	}

	prereqfor_desc = {
		custom = {
			title = "specialization_job"
			desc = "specialization_job_desc"
		}
	}
	
	ai_weight = {
		factor = 1.0
	}
	
	weight_groups = {
		job_repeatable
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableDifferntFactor
    }
  mod_weight_if_group_picked = {
		production_repeatable = @RepeatableDifferntFactor
	}
	mod_weight_if_group_picked = {
		job_repeatable = 0
	}
	
	modifier = {
        job_clerk_per_pop = 0.02
    }
}

tech_repeatable_farmer_drone_jobs = {
	area = society
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
	category = { statecraft }
	levels = 5
	prerequisites = { "tech_embodied_dynamism" }
	weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 0 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 1 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 2 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 3 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 4 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 5 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 6 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 7 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 8 }
		}
		modifier = {
			factor = 0
			check_variable = { which = repeatable_jobs value > 9 }
		}
	}

	potential = {
		has_authority = auth_hive_mind
		is_country_type = default
	}

	prereqfor_desc = {
		custom = {
			title = "specialization_job"
			desc = "specialization_job_desc"
		}
	}
	
	ai_weight = {
		factor = 1.0
	}
	
	weight_groups = {
		job_repeatable
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableDifferntFactor
    }
  mod_weight_if_group_picked = {
		production_repeatable = @RepeatableDifferntFactor
	}
	mod_weight_if_group_picked = {
		job_repeatable = 0
	}
	
	modifier = {
        job_agri_drone_per_pop = 0.02
    }
}

tech_repeatable_miner_drone_jobs = {
	area = society
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
	category = { statecraft }
	levels = 5
	prerequisites = { "tech_embodied_dynamism" }
	weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 0 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 1 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 2 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 3 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 4 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 5 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 6 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 7 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 8 }
		}
		modifier = {
			factor = 0
			check_variable = { which = repeatable_jobs value > 9 }
		}
	}

	potential = {
		is_gestalt = yes
		is_country_type = default
	}

	prereqfor_desc = {
		custom = {
			title = "specialization_job"
			desc = "specialization_job_desc"
		}
	}
	
	ai_weight = {
		factor = 1.0
	}
	
	weight_groups = {
		job_repeatable
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableDifferntFactor
    }
  mod_weight_if_group_picked = {
		production_repeatable = @RepeatableDifferntFactor
	}
	mod_weight_if_group_picked = {
		job_repeatable = 0
	}
	
	modifier = {
        job_mining_drone_per_pop = 0.02
    }
}

tech_repeatable_technician_drone_jobs = {
	area = society
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
	category = { statecraft }
	levels = 5
	prerequisites = { "tech_embodied_dynamism" }
	weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 0 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 1 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 2 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 3 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 4 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 5 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 6 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 7 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 8 }
		}
		modifier = {
			factor = 0
			check_variable = { which = repeatable_jobs value > 9 }
		}
	}

	potential = {
		is_gestalt = yes
		is_country_type = default
	}

	prereqfor_desc = {
		custom = {
			title = "specialization_job"
			desc = "specialization_job_desc"
		}
	}
	
	ai_weight = {
		factor = 1.0
	}
	
	weight_groups = {
		job_repeatable
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableDifferntFactor
    }
  mod_weight_if_group_picked = {
		production_repeatable = @RepeatableDifferntFactor
	}
	mod_weight_if_group_picked = {
		job_repeatable = 0
	}
	
	modifier = {
        job_technician_drone_per_pop = 0.02
    }
}

tech_repeatable_foundry_jobs = {
	area = society
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
	category = { statecraft }
	levels = 5
	prerequisites = { "tech_global_production_strategy" }
	weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 0 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 1 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 2 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 3 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 4 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 5 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 6 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 7 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 8 }
		}
		modifier = {
			factor = 0
			check_variable = { which = repeatable_jobs value > 9 }
		}
	}

	potential = {
		is_gestalt = no
		is_country_type = default
	}

	prereqfor_desc = {
		custom = {
			title = "specialization_job"
			desc = "specialization_job_desc"
		}
	}
	
	ai_weight = {
		factor = 1.0
	}
	
	weight_groups = {
		job_repeatable
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableDifferntFactor
    }
  mod_weight_if_group_picked = {
		production_repeatable = @RepeatableDifferntFactor
	}
	mod_weight_if_group_picked = {
		job_repeatable = 0
	}
	
	modifier = {
        job_foundry_per_pop = 0.01
    }
}

tech_repeatable_artisan_jobs = {
	area = society
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
	category = { statecraft }
	levels = 5
	prerequisites = { "tech_global_production_strategy" }
	weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 0 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 1 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 2 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 3 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 4 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 5 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 6 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 7 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 8 }
		}
		modifier = {
			factor = 0
			check_variable = { which = repeatable_jobs value > 9 }
		}
	}

	potential = {
		is_gestalt = no
		is_country_type = default
	}

	prereqfor_desc = {
		custom = {
			title = "specialization_job"
			desc = "specialization_job_desc"
		}
	}
	
	ai_weight = {
		factor = 1.0
	}
	
	weight_groups = {
		job_repeatable
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableDifferntFactor
    }
  mod_weight_if_group_picked = {
		production_repeatable = @RepeatableDifferntFactor
	}
	mod_weight_if_group_picked = {
		job_repeatable = 0
	}
	
	modifier = {
        job_artisan_per_pop = 0.01
    }
}

tech_repeatable_researcher_jobs = {
	area = society
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
	category = { statecraft }
	levels = 5
	prerequisites = { "tech_global_production_strategy" }
	weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 0 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 1 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 2 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 3 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 4 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 5 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 6 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 7 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 8 }
		}
		modifier = {
			factor = 0
			check_variable = { which = repeatable_jobs value > 9 }
		}
	}

	potential = {
		is_gestalt = no
		is_country_type = default
	}

	prereqfor_desc = {
		custom = {
			title = "specialization_job"
			desc = "specialization_job_desc"
		}
	}
	
	ai_weight = {
		factor = 1.0
	}
	
	weight_groups = {
		job_repeatable
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableDifferntFactor
    }
  mod_weight_if_group_picked = {
		production_repeatable = @RepeatableDifferntFactor
	}
	mod_weight_if_group_picked = {
		job_repeatable = 0
	}
	
	modifier = {
        job_researcher_per_pop = 0.01
    }
}

tech_repeatable_foundry_drone_jobs = {
	area = society
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
	category = { statecraft }
	levels = 5
	prerequisites = { "tech_embodied_dynamism" }
	weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 0 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 1 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 2 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 3 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 4 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 5 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 6 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 7 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 8 }
		}
		modifier = {
			factor = 0
			check_variable = { which = repeatable_jobs value > 9 }
		}
	}

	potential = {
		is_gestalt = yes
		is_country_type = default
	}

	prereqfor_desc = {
		custom = {
			title = "specialization_job"
			desc = "specialization_job_desc"
		}
	}
	
	ai_weight = {
		factor = 1.0
	}
	
	weight_groups = {
		job_repeatable
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableDifferntFactor
    }
  mod_weight_if_group_picked = {
		production_repeatable = @RepeatableDifferntFactor
	}
	mod_weight_if_group_picked = {
		job_repeatable = 0
	}
	
	modifier = {
		job_alloy_drone_per_pop = 0.01
  }
}

tech_repeatable_brain_drone_jobs = {
	area = society
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
	category = { statecraft }
	levels = 5
	prerequisites = { "tech_embodied_dynamism" }
	weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 0 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 1 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 2 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 3 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 4 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 5 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 6 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 7 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 8 }
		}
		modifier = {
			factor = 0
			check_variable = { which = repeatable_jobs value > 9 }
		}
	}

	potential = {
		has_authority = auth_hive_mind
		is_country_type = default
	}

	prereqfor_desc = {
		custom = {
			title = "specialization_job"
			desc = "specialization_job_desc"
		}
	}
	
	ai_weight = {
		factor = 1.0
	}
	
	weight_groups = {
		job_repeatable
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableDifferntFactor
    }
  mod_weight_if_group_picked = {
		production_repeatable = @RepeatableDifferntFactor
	}
	mod_weight_if_group_picked = {
		job_repeatable = 0
	}
	
	modifier = {
		job_brain_drone_per_pop = 0.01
  }
}

tech_repeatable_calculator_drone_jobs = {
	area = society
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
	category = { statecraft }
	levels = 5
	prerequisites = { "tech_embodied_dynamism" }
	weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 0 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 1 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 2 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 3 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 4 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 5 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 6 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 7 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 8 }
		}
		modifier = {
			factor = 0
			check_variable = { which = repeatable_jobs value > 9 }
		}
	}

	potential = {
		has_authority = auth_machine_intelligence
		is_country_type = default
	}

	prereqfor_desc = {
		custom = {
			title = "specialization_job"
			desc = "specialization_job_desc"
		}
	}
	
	ai_weight = {
		factor = 1.0
	}
	
	weight_groups = {
		job_repeatable
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableDifferntFactor
    }
  mod_weight_if_group_picked = {
		production_repeatable = @RepeatableDifferntFactor
	}
	mod_weight_if_group_picked = {
		job_repeatable = 0
	}
	
	modifier = {
		job_calculator_per_pop = 0.01
  }
}

tech_repeatable_maintenance_drone_jobs = {
	area = society
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
	category = { statecraft }
	levels = 5
	prerequisites = { "tech_embodied_dynamism" }
	weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 0 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 1 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 2 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 3 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 4 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 5 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 6 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 7 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 8 }
		}
		modifier = {
			factor = 0
			check_variable = { which = repeatable_jobs value > 9 }
		}
	}

	potential = {
		is_gestalt = yes
		is_country_type = default
	}

	prereqfor_desc = {
		custom = {
			title = "specialization_job"
			desc = "specialization_job_desc"
		}
	}
	
	ai_weight = {
		factor = 1.0
	}
	
	weight_groups = {
		job_repeatable
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableDifferntFactor
    }
  mod_weight_if_group_picked = {
		production_repeatable = @RepeatableDifferntFactor
	}
	mod_weight_if_group_picked = {
		job_repeatable = 0
	}
	
	modifier = {
		job_maintenance_drone_per_pop = 0.02
  }
}

tech_repeatable_militarization = {
	area = society
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
	category = { military_theory }
	levels = 5
	prerequisites = { "tech_combat_training" }
	weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 0 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 1 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 2 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 3 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 4 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 5 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 6 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 7 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 8 }
		}
		modifier = {
			factor = 0
			check_variable = { which = repeatable_jobs value > 9 }
		}
	}
	potential = {
		is_gestalt = no
		is_country_type = default
	}

	prereqfor_desc = {
		custom = {
			title = "specialization_job"
			desc = "specialization_job_desc"
		}
	}
	
	ai_weight = {
		factor = 1.0
	}
	
	weight_groups = {
		production
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableCategoryFactor
		job_repeatable = 0
    }
    mod_weight_if_group_picked = {
		production_repeatable = @RepeatableDifferntFactor
	}
	
	modifier = {
		job_soldier_per_pop = 0.02
    }
}

tech_repeatable_gestalt_militarization = {
	area = society
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
	category = { military_theory }
	levels = 5
	prerequisites = { "tech_combat_training" }
	weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 0 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 1 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 2 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 3 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 4 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 5 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 6 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 7 }
		}
		modifier = {
			factor = @SpecializationLevel
			check_variable = { which = repeatable_jobs value > 8 }
		}
		modifier = {
			factor = 0
			check_variable = { which = repeatable_jobs value > 9 }
		}
	}
	potential = {
		is_gestalt = yes
		is_country_type = default
	}

	prereqfor_desc = {
		custom = {
			title = "specialization_job"
			desc = "specialization_job_desc"
		}
	}
	
	ai_weight = {
		factor = 1.0
	}
	
	weight_groups = {
		production
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableCategoryFactor
		job_repeatable = 0
    }
    mod_weight_if_group_picked = {
		production_repeatable = @RepeatableDifferntFactor
	}
	
	modifier = {
		job_warrior_drone_per_pop = 0.02
    }
}

tech_repeatable_terraforming = {
	area = society
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
	category = { new_worlds }
	levels = 5
	prerequisites = { "tech_ecological_adaptation" }
	weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_terraforming value > 0 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_terraforming value > 1 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_terraforming value > 2 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_terraforming value > 3 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_terraforming value > 4 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_terraforming value > 5 }
		}
	}
	
	ai_weight = {
		factor = 1.0
	}
	
	weight_groups = {
		production
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableDifferntFactor
		job_repeatable = @RepeatableDifferntFactor
    }
    mod_weight_if_group_picked = {
		production_repeatable = @RepeatableCategoryFactor
	}
	
	modifier = {
        terraforming_cost_mult = -0.05
    }
}

tech_repeatable_pop_growth = {
	area = society
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
	category = { biology }
	levels = 10
	prerequisites = { "tech_gene_tailoring" }
	weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_pop_growth value > 0 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_pop_growth value > 1 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_pop_growth value > 2 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_pop_growth value > 3 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_pop_growth value > 4 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_pop_growth value > 5 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_pop_growth value > 6 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_pop_growth value > 7 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_pop_growth value > 8 }
		}
	}

	potential = {
		NOT = { is_country_type = fallen_empire }
	}
	
	ai_weight = {
		factor = 1.0
	}
	
	weight_groups = {
		production
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableDifferntFactor
		job_repeatable = @RepeatableDifferntFactor
    }
    mod_weight_if_group_picked = {
		production_repeatable = @RepeatableCategoryFactor
	}
	
	modifier = {
        pop_growth_speed = 0.05
    }
}

tech_repeatable_pop_assembly = {
	area = society
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
	category = { industry }
	levels = 10
	weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_pop_assembly value > 0 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_pop_assembly value > 1 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_pop_assembly value > 2 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_pop_assembly value > 3 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_pop_assembly value > 4 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_pop_assembly value > 5 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_pop_assembly value > 6 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_pop_assembly value > 7 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_pop_assembly value > 8 }
		}
	}
	
	potential = {
       	OR = { 
           	has_technology = tech_droid_workers
           	has_authority = auth_machine_intelligence
		}
		NOT = { is_country_type = fallen_empire }
	}	
	ai_weight = {
		factor = 1.0
	}	
	weight_groups = {
		production
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableDifferntFactor
		job_repeatable = @RepeatableDifferntFactor
    }
    mod_weight_if_group_picked = {
		production_repeatable = @RepeatableCategoryFactor
	}	
	modifier = {
        planet_pop_assembly_mult = 0.05
    }
}

tech_repeatable_housing = {
	area = society
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
	category = { new_worlds }
	levels = -1
	prerequisites = { "tech_food_processing_2" }
	weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_housing value > 0 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_housing value > 1 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_housing value > 2 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_housing value > 3 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_housing value > 4 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_housing value > 5 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_housing value > 6 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_housing value > 7 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_housing value > 8 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_housing value > 9 }
		}
	}

	potential = {
		NOT = { is_country_type = fallen_empire }
	}
	
	ai_weight = {
		factor = 1.0
	}
	
	weight_groups = {
		production
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableDifferntFactor
		job_repeatable = @RepeatableDifferntFactor
    }
    mod_weight_if_group_picked = {
		production_repeatable = @RepeatableCategoryFactor
	}
	
	modifier = {
        planet_housing_add = 3
    }
}

tech_repeatable_fire_rate = {
	area = society
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
	category = { military_theory }
	levels = -1
	prerequisites = { "tech_command_matrix" }
	weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_fire_rate value > 0 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_fire_rate value > 1 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_fire_rate value > 2 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_fire_rate value > 3 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_fire_rate value > 4 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_fire_rate value > 5 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_fire_rate value > 6 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_fire_rate value > 7 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_fire_rate value > 8 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_fire_rate value > 9 }
		}
	}

	potential = {
		NOT = { is_country_type = fallen_empire }
	}
	
	ai_weight = {
		factor = 1.0
	}
	
	weight_groups = {
		production
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableCategoryFactor
		job_repeatable = @RepeatableDifferntFactor
    }
    mod_weight_if_group_picked = {
		production_repeatable = @RepeatableDifferntFactor
	}
	
	modifier = {
        ship_fire_rate_mult = 0.02
    }
}

tech_repeatable_force_disparity = {
	area = society
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
	category = { military_theory }
	levels = 5
	prerequisites = { "tech_doctrine_fleet_size_3" }
	weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_force_disparity value > 0 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_force_disparity value > 1 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_force_disparity value > 2 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_force_disparity value > 3 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_force_disparity value > 4 }
		}
		modifier = {
			factor = @SpecializationPenalty
			check_variable = { which = repeatable_force_disparity value > 5 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_escape value > 0 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_escape value > 1 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_escape value > 2 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_escape value > 3 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_escape value > 4 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_ship_escape value > 5 }
		}
	}

	potential = {
		NOT = { is_country_type = fallen_empire }
	}

	prereqfor_desc = {
		custom = {
			title = "no_retreat_focus"
			desc = "no_retreat_focus_desc"
		}
	}
	
	ai_weight = {
		factor = 1.0
	}
	
	weight_groups = {
		production
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableCategoryFactor
    }
    mod_weight_if_group_picked = {
		production_repeatable = @RepeatableDifferntFactor
		job_repeatable = @RepeatableDifferntFactor
	}
	
	modifier = {
        force_disparity_fire_rate_mult = 0.05
    }
}

tech_repeatable_collateral_damage = {
	area = society
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
	category = { military_theory }
	levels = -1
	prerequisites = { "tech_combat_training" }
	weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_collateral_damage value > 0 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_collateral_damage value > 1 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_collateral_damage value > 2 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_collateral_damage value > 3 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_collateral_damage value > 4 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_collateral_damage value > 5 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_collateral_damage value > 6 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_collateral_damage value > 7 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_collateral_damage value > 8 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_collateral_damage value > 9 }
		}
	}

	potential = {
		NOT = { is_country_type = fallen_empire }
		NOT = { has_technology = tech_repeatable_collateral_reduction }
	}

	prereqfor_desc = {
		custom = {
			title = "collateral_damage"
			desc = "collateral_reduction_desc"
		}
	}
	
	ai_weight = {
		factor = 1.0
		modifier = {
			factor = 0
			OR = {
				has_ethic = ethic_pacifist
				has_ethic = ethic_fanatic_pacifist
				has_ethic = ethic_xenophile
				has_ethic = ethic_fanatic_xenophile
			}
		}
	}
	
	weight_groups = {
		production
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableCategoryFactor
    }
    mod_weight_if_group_picked = {
		production_repeatable = @RepeatableDifferntFactor
		job_repeatable = @RepeatableDifferntFactor
	}
	
	modifier = {
		army_collateral_damage_mult = 0.1
		army_morale_damage_mult = 0.1
    }
}

tech_repeatable_collateral_reduction = {
	area = society
	cost = @EarlyRepeatableTechCost
	cost_per_level = @EarlyRepeatableTechLevelCost
	tier = @EarlyRepeatableTier
	category = { military_theory }
	levels = 10
	prerequisites = { "tech_combat_training" }
	weight = @EarlyRepeatableWeight
	
	weight_modifier = {
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_collateral_reduction value > 0 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_collateral_reduction value > 1 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_collateral_reduction value > 2 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_collateral_reduction value > 3 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_collateral_reduction value > 4 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_collateral_reduction value > 5 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_collateral_reduction value > 6 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_collateral_reduction value > 7 }
		}
		modifier = {
			factor = @EarlyRepatableTechFactor
			check_variable = { which = repeatable_collateral_reduction value > 8 }
		}
	}

	potential = {
		NOT = { is_country_type = fallen_empire }
		NOT = { has_technology = tech_repeatable_collateral_damage }
	}

	prereqfor_desc = {
		custom = {
			title = "collateral_reduction"
			desc = "collateral_damage_desc"
		}
	}

	ai_weight = {
		factor = 1.0
		modifier = {
			factor = 0
			OR = {
				has_ethic = ethic_militarist
				has_ethic = ethic_fanatic_militarist
				has_ethic = ethic_xenophobe
				has_ethic = ethic_fanatic_xenophobe
			}
		}
	}
	
	weight_groups = {
		production
	}
	mod_weight_if_group_picked = {
		ship_repeatable = @RepeatableCategoryFactor
    }
    mod_weight_if_group_picked = {
		production_repeatable = @RepeatableDifferntFactor
		job_repeatable = @RepeatableDifferntFactor
	}
	
	modifier = {
		army_collateral_damage_mult = -0.05
		country_trust_cap_add = 10
    }
}


