# Grand Archive @entity_x = -16 @entity_y = 4 grand_archive_0 = { entity = "grand_archive_entity" construction_entity = "grand_archive_entity" portrait = "GFX_megastructure_grand_archive_background" place_entity_on_planet_plane = no entity_offset = { x = @entity_x y = @entity_y } is_grand_archive = yes build_time = 1800 resources = { category = megastructures_grand_archive cost = { trigger = { country_uses_bio_ships = no } alloys = 1000 } cost = { trigger = { country_uses_bio_ships = yes } alloys = 500 food = 500 } upkeep = { energy = 10 } } construction_blocks_and_blocked_by = self_type prerequisites = { "tech_galactic_archivism" } show_prereqs = yes potential = { is_country_type = default NOR = { any_owned_megastructure = { is_megastructure_type = grand_archive_0 } } } possible = { hidden_trigger = { exists = starbase } custom_tooltip = { fail_text = "requires_inside_border" is_inside_border = from } custom_tooltip = { fail_text = "requires_surveyed_system" NOT = { any_system_planet = { is_surveyed = { who = prev.from status = no } } } } custom_tooltip = { fail_text = must_have_2500_pops OR = { from = { pop_amount >= 2500 } from.owner = { is_wilderness_empire = yes } } } } placement_rules = { planet_possible = { is_colony = yes owner = { NOT = { is_primitive = yes } } OR = { pop_amount >= 2500 AND = { exists = owner owner = { is_wilderness_empire = yes } } } } } country_modifier = { country_vivarium_max_capacity_add = @grand_archive_vivarium_capacity } # Root = System # From = Country ai_weight = { factor = 5 modifier = { factor = 3 from = { acquired_specimen_count > 6 } } modifier = { factor = 0 from = { is_unfriendly = yes } } } on_build_complete = { from = { if = { limit = { has_country_flag = grand_archive_destroyed } remove_country_flag = grand_archive_destroyed country_event = { id = grand_archive.4580 scopes = { from = fromfrom.solar_system } } } } fromfrom.planet = { set_planet_flag = has_megastructure } } }