From 01200b90202219f3bd22752598e24dfee31336d4 Mon Sep 17 00:00:00 2001 From: "ProjectKoi-Kalo\\Kalo" Date: Sat, 21 Sep 2024 12:56:55 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9A=82=E5=AD=98=E7=A9=BA=E9=97=B4=E7=AB=99?= =?UTF-8?q?=E5=B7=A8=E6=9E=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- common/ascension_perks/rg_ascension_perks.txt | 5 +- common/buildings/RG_nano_buildings.txt | 75 +++++++- common/megastructures/RG_habitats.txt | 182 ++++++++++++++++++ .../RG_megastructure_effects.txt | 48 +++++ common/ship_sizes/RG_ship_sizes.txt | 50 ++++- common/traditions/RG_nanotech_tradition.txt | 33 ++-- events/RG_gray_leader_event.txt | 8 +- .../simp_chinese/RG_l_simp_chinese.yml | 33 +++- 8 files changed, 392 insertions(+), 42 deletions(-) create mode 100644 common/megastructures/RG_habitats.txt create mode 100644 common/scripted_effects/RG_megastructure_effects.txt diff --git a/common/ascension_perks/rg_ascension_perks.txt b/common/ascension_perks/rg_ascension_perks.txt index 81e9950..8becf61 100644 --- a/common/ascension_perks/rg_ascension_perks.txt +++ b/common/ascension_perks/rg_ascension_perks.txt @@ -5,10 +5,7 @@ rg_ap_nantiematter = { } possible = { OR = { - has_country_flag = origin_rg_gray - has_country_flag = gray_owner - has_technology = tech_lgate_activation - can_research_technology = tech_lgate_activation + has_tradition = tr_rg_nanotech_4 } NOT = { has_ascension_perk = rg_ap_nantiematter diff --git a/common/buildings/RG_nano_buildings.txt b/common/buildings/RG_nano_buildings.txt index 71be6f2..d2488b0 100644 --- a/common/buildings/RG_nano_buildings.txt +++ b/common/buildings/RG_nano_buildings.txt @@ -10,13 +10,15 @@ building_rg_nanolab_1 = { potential = { exists = owner - uses_district_set = rg_station + OR = { + uses_district_set = rg_station + owner = { has_tradition = tr_rg_nanotech_1 } + } #owner = { has_tradition = tr_nanotech_adopt } } allow = { - exists = owner - uses_district_set = rg_station + always = yes #owner = { has_tradition = tr_nanotech_adopt } } @@ -82,7 +84,7 @@ building_rg_nanolab_1 = { } upgrades = { - "building_nanolab_2" + "building_rg_nanolab_2" } } @@ -96,7 +98,10 @@ building_rg_nanolab_2 = { potential = { exists = owner - uses_district_set = rg_station + OR = { + uses_district_set = rg_station + owner = { has_tradition = tr_rg_nanotech_1 } + } # owner = { has_tradition = tr_nanotech_1 } } @@ -175,8 +180,10 @@ building_rg_nanotech_cauldron = { potential = { exists = owner - uses_district_set = rg_station - # owner = { has_tradition = tr_nanotech_2 } + OR = { + uses_district_set = rg_station + owner = { has_tradition = tr_rg_nanotech_1 } + } # NOT = { has_modifier = resort_colony } # NOT = { has_modifier = slave_colony } } @@ -208,3 +215,57 @@ building_rg_nanotech_cauldron = { } } } + +building_rg_nanite_transmuter = { + base_buildtime = @b3_time + icon = building_nanite_transmuter + + category = manufacturing + + potential = { + exists = owner + OR = { + uses_district_set = rg_station + owner = { has_tradition = tr_rg_nanotech_1 } + } + # owner = { has_tradition = tr_nanotech_2 } + # NOT = { has_modifier = resort_colony } + # NOT = { has_modifier = slave_colony } + } + + allow = { + has_upgraded_capital = yes + } + + resources = { + category = planet_buildings + cost = { + minerals = 1000 + } + produces = { + trigger = { + owner = { + NOT = { + has_deficit = nanites + } + } + } + rare_crystals = 2 + volatile_motes = 2 + exotic_gases = 2 + } + upkeep = { + nanites = 1 + energy = 5 + } + } + + ai_resource_production = { + rare_crystals = @b3_rare_upkeep + volatile_motes = @b3_rare_upkeep + exotic_gases = @b3_rare_upkeep + trigger = { + always = yes + } + } +} diff --git a/common/megastructures/RG_habitats.txt b/common/megastructures/RG_habitats.txt new file mode 100644 index 0000000..8adbabe --- /dev/null +++ b/common/megastructures/RG_habitats.txt @@ -0,0 +1,182 @@ +# see README.txt for example + +@central_orbital_build_time = 1800 +@central_orbital_alloy_cost = 1500 +@central_orbital_influence_cost = 200 + +@major_orbital_build_time = 720 +@major_orbital_alloy_cost = 200 + +@minor_orbital_build_time = 180 +@minor_orbital_alloy_cost = 50 + +# Habitat Central Complex +RG_habitat_central_complex = { + entity = "gatebuilder_01_space_station_entity" + construction_entity = "habitat_phase_03_entity" + portrait = "GFX_megastructure_habitat_background" + place_entity_on_planet_plane = no + show_galactic_map_icon = no + hide_name = yes + show_in_outliner = no + entity_offset = { x = 7 y = -7 } + build_time = 360 + + resources = { + category = megastructures_habitat + cost = { + nanites = 4500 + influence = 200 + } + } + + construction_blocks_and_blocked_by = self_type + + potential = { + has_tradition = tr_rg_nanotech_2 + # OR = { + # has_technology = tech_habitat_1 + # has_civic = civic_diadochi + # has_civic = civic_great_khans_legacy + # has_country_flag = democratic_khanate_flag + # } + } + + possible = { + exists = starbase + custom_tooltip = { + fail_text = "requires_inside_border" + is_inside_border = from + } + custom_tooltip = { + fail_text = "requires_not_habitat_central_complex" + NOT = { + OR = { + any_system_planet = { + has_planet_flag = habitat + } + has_megastructure = habitat_central_complex_ruined + } + } + } + custom_tooltip = { + fail_text = "requires_no_orbital_debris" + NOT = { + any_system_planet = { + has_planet_flag = has_orbital_debris + } + } + } + } + + placement_rules = { + planet_possible = { + custom_tooltip = { + fail_text = "requires_surveyed_planet" + is_surveyed = { # prevent leaking habitability information + who = prev.from + status = yes + } + } + custom_tooltip = { + fail_text = "requires_no_anomaly" + NOT = { has_anomaly = yes } + } + custom_tooltip = { + fail_text = "requires_no_existing_megastructure" + #can_build_megastructure_on_planet = yes + NOR = { + solar_system = { + OR = { + has_star_flag = ithomes_gate + } + } + is_planet_class = pc_habitat + } + } + + # balance for habitats + custom_tooltip = { + fail_text = "requires_not_minor_planetary_body" + NOR = { + is_asteroid = yes + is_moon = yes + } + } + custom_tooltip = { + fail_text = "requires_not_solarpunk" + NOT = { + solar_system = { + has_star_flag = solarpunk_system_02 + } + } + } + if = { + limit = { + from = { is_ai = yes } + } + or = { + has_deposit_for = shipclass_mining_station + has_deposit_for = shipclass_research_station + } + } + } # use these for all non-star megastructures + } + + # root = system + # from = country + ai_weight = { + factor = 0 + } + + on_build_complete = { + fromfrom.planet = { + save_event_target_as = target_planet + } + if = { + limit = { + fromfrom.planet = { + is_star = yes + } + } + spawn_rg_habitat_effect = { + DISTANCE = 19.798 + } + } + else = { + spawn_rg_habitat_effect = { + DISTANCE = 9.899 + } + } + + fromfrom.solar_system = { + set_star_flag = has_habitat + } + + if = { + limit = { + event_target:target_planet = { + OR = { + has_deposit_for = shipclass_research_station + has_deposit_for = shipclass_mining_station + } + + } + } + on_orbital_complete_effect = { + BODY = major + TYPE = resource + } + } + + else = { + on_orbital_complete_effect = { + BODY = major + TYPE = generic + } + } + + remove_megastructure = fromfrom + from = { country_event = { id = megastructures.10 } } + } +} \ No newline at end of file diff --git a/common/scripted_effects/RG_megastructure_effects.txt b/common/scripted_effects/RG_megastructure_effects.txt new file mode 100644 index 0000000..e8ee568 --- /dev/null +++ b/common/scripted_effects/RG_megastructure_effects.txt @@ -0,0 +1,48 @@ +spawn_rg_habitat_effect = { + spawn_planet = { + class = "pc_rg_grayhabitat" + location = event_target:target_planet + orbit_location = yes + orbit_angle_offset = 135 + orbit_distance_offset = $DISTANCE$ + size = 15 + has_ring = no + + init_effect = { + set_name = { + key = HABITAT_PLANET_NAME + variable_string = "\\[FROM.from.solar_system.GetName]" + } + set_planet_entity = { + entity = "grey_tempesttw_orbital_habitat_entity" + } + set_surveyed = { + surveyed = yes + surveyor = FROM + } + set_all_comms_surveyed = yes + clear_blockers = yes + + set_planet_flag = megastructure + set_planet_flag = habitat + set_planet_flag = rg_gray_habitat + set_planet_flag = habitat_level_1 + save_event_target_as = target_habitat + add_deposit_if_missing = { + DEPOSIT = d_system_resources + } + add_deposit_if_missing = { + DEPOSIT = d_orbital_research + } + add_deposit_if_missing = { + DEPOSIT = d_orbital_energy + } + add_deposit_if_missing = { + DEPOSIT = d_orbital_mining + } + event_target:target_planet = { + set_planet_flag = habitat@PREV + } + } + } +} \ No newline at end of file diff --git a/common/ship_sizes/RG_ship_sizes.txt b/common/ship_sizes/RG_ship_sizes.txt index 7b7fba9..84595af 100644 --- a/common/ship_sizes/RG_ship_sizes.txt +++ b/common/ship_sizes/RG_ship_sizes.txt @@ -125,8 +125,52 @@ RG_graygoo_capitalship = { combat_disengage_chance = 1.25 class = shipclass_military construction_type = starbase_shipyard + potential_construction = { + OR = { + is_scope_type = starbase + AND = { + is_scope_type = megastructure + OR = { + is_megastructure_type = mega_shipyard_3 + is_megastructure_type = mega_shipyard_restored + } + } + } + } + possible_construction = { - always = no + custom_tooltip = { + fail_text = starbase_citadel_trigger + OR = { + AND = { + is_scope_type = megastructure + OR = { + is_megastructure_type = mega_shipyard_3 + is_megastructure_type = mega_shipyard_restored + } + } + AND = { + is_scope_type = starbase + has_starbase_size >= starbase_citadel + } + } + } + custom_tooltip = { + fail_text = starbase_colossal_yards_trigger + OR = { + AND = { + is_scope_type = megastructure + OR = { + is_megastructure_type = mega_shipyard_3 + is_megastructure_type = mega_shipyard_restored + } + } + AND = { + is_scope_type = starbase + has_starbase_building = colossus_yards + } + } + } } combat_size_multiplier = 4 prerequisites = { @@ -463,8 +507,8 @@ RG_graygoo_destroyer = { enable_3dview_in_ship_browser = yes #if yes, ship design will have a 3d view in the ship browser is_designable = yes default_behavior = line - prerequisites = { - "tech_gray_interdictor_4" + potential_country = { + has_tradition = tr_rg_nanotech_4 } ship_roles = { screen gunship artillery brawler } triggered_ship_roles = { diff --git a/common/traditions/RG_nanotech_tradition.txt b/common/traditions/RG_nanotech_tradition.txt index 85efc7d..7879931 100644 --- a/common/traditions/RG_nanotech_tradition.txt +++ b/common/traditions/RG_nanotech_tradition.txt @@ -2,8 +2,15 @@ tr_rg_nanotech_adopt = { possible = { custom_tooltip = { - fail_text = REQUIRES_FINISHED_TRANSFORMATION - has_country_flag = nanotech_traditions_unlocked + fail_text = REQUIRES_lgate_or_gray + OR = { + has_country_flag = origin_rg_gray + has_country_flag = gray_owner + AND = { + has_event_chain = l_cluster_chain + has_technology = tech_lgate_activation + } + } } } custom_tooltip = tr_rg_nanotech_adopt_modifier_desc @@ -13,6 +20,12 @@ tr_rg_nanotech_adopt = { tr_rg_nanotech_finish = { custom_tooltip_with_modifiers = tr_rg_nanotech_finish_modifier_desc + on_enabled = { + give_technology = { + tech = tech_object_gray_5 + message = no + } + } modifier = { empire_size_colonies_mult = -0.5 @@ -80,21 +93,7 @@ tr_rg_nanotech_4 = { custom_tooltip = tr_rg_nanotech_4_modifier_desc #Unlocks Nanite Swarmer ship and nanite ship component research options on_enabled = { - add_research_option = tech_nanite_repair_system - add_research_option = tech_nanite_autocannon - add_research_option = tech_nanite_flak_batteries - add_tech_progress = { - tech = tech_nanite_repair_system - progress = 0.25 - } - add_tech_progress = { - tech = tech_nanite_autocannon - progress = 0.25 - } - add_tech_progress = { - tech = tech_nanite_flak_batteries - progress = 0.25 - } + } ai_weight = { factor = 1000 diff --git a/events/RG_gray_leader_event.txt b/events/RG_gray_leader_event.txt index 507c0d6..2b88480 100644 --- a/events/RG_gray_leader_event.txt +++ b/events/RG_gray_leader_event.txt @@ -1879,8 +1879,8 @@ country_event = { desc = "rg_event.7.a.desc" event_window_type = leader_recruit picture_event_data = { - portrait = event_target:gray_governor - room = "ethic_spaceship_room" + portrait = event_target:rg_gray_country_leader + planet_background = root.capital_scope } is_triggered_only = yes immediate = { @@ -1960,8 +1960,8 @@ country_event = { desc = "rg_event.8.a.desc" event_window_type = leader_recruit picture_event_data = { - portrait = event_target:gray_governor - room = "ethic_spaceship_room" + portrait = event_target:rg_gray_country_leader + planet_background = root.capital_scope } is_triggered_only = yes immediate = { diff --git a/localisation/simp_chinese/RG_l_simp_chinese.yml b/localisation/simp_chinese/RG_l_simp_chinese.yml index dea1510..250b733 100644 --- a/localisation/simp_chinese/RG_l_simp_chinese.yml +++ b/localisation/simp_chinese/RG_l_simp_chinese.yml @@ -36,7 +36,7 @@ tradition_rg_nanotech_desc: "生命的构成形式不是千篇一律,拥抱纳米机器使我们超维宇宙万物。" tr_rg_nanotech_adopt: "§Y纳米重构§!传统" tr_rg_nanotech_1: "物质再塑" - tr_rg_nanotech_2: "献身精神" + tr_rg_nanotech_2: "精神献身" tr_rg_nanotech_3: "风暴洪流" tr_rg_nanotech_4: "无限远疆" tr_rg_nanotech_5: "纳米归一" @@ -47,13 +47,13 @@ tr_rg_nanotech_4_delayed: "我们是一股洪流,我们的存在需要力量作为根基。现在,§R我§!即是虫群。" tr_rg_nanotech_5_delayed: "物质和人之间的界限已经模糊,一切都只是我们集体意志的洪流中的一注。" tradition_rg_nanotech_delayed: "我们是一股永不停息的洪流,吞天食地、势不可挡。一切都将融入我们,我们将形成一切。" - tr_rg_nanotech_adopt_modifier_desc: "§Y$AVAILABLE_BUILDINGS$§!$building_nanolab_1$\n§Y$AVAILABLE_STARBASE_BUILDINGS$§!$sm_nanite_harvester$" - tr_rg_nanotech_1_modifier_desc: "§Y$AVAILABLE_BUILDINGS$§!$building_nanolab_2$" - tr_rg_nanotech_2_modifier_desc: "§Y$AVAILABLE_BUILDINGS$§!$building_nanotech_cauldron$\n获得科技选项:§Y£engineering£$tech_nanite_transmutation$§!" + tr_rg_nanotech_adopt_modifier_desc: "§Y$AVAILABLE_BUILDINGS$§!$building_rg_nanolab_1$\n§Y$AVAILABLE_STARBASE_BUILDINGS$§!$sm_nanite_harvester$" + tr_rg_nanotech_1_modifier_desc: "§Y$AVAILABLE_BUILDINGS$§!$building_rg_nanolab_2$\n§Y$AVAILABLE_BUILDINGS$§!$building_rg_nanotech_cauldron$\n§Y$AVAILABLE_BUILDINGS$§!$building_rg_nanite_transmuter$\n" + tr_rg_nanotech_2_modifier_desc: "—§I解锁巨型结构:§!$RG_habitat_central_complex$\n" tr_rg_nanotech_3_modifier_desc: "§Y解锁行星决议:§!$decision_nanotech_swarm_consume_world$" - tr_rg_nanotech_4_modifier_desc: "§Y解锁舰船:§!纳米虫群\n\n获得研究选项:$TABBED_NEW_LINE$—§Y£engineering£$tech_nanite_autocannon$§!$TABBED_NEW_LINE$—§Y£engineering£$tech_nanite_repair_system$§!$TABBED_NEW_LINE$—§Y£engineering£$tech_nanite_flak_batteries$§!" + tr_rg_nanotech_4_modifier_desc: "§Y解锁飞升:$rg_ap_nantiematter$解锁舰船:§!$RG_graygoo_destroyer$\n\n" tr_rg_nanotech_5_modifier_desc: "§Y解锁法令:§!$TABBED_NEW_LINE$—$edict_nanotech_naval_augmentation$$TABBED_NEW_LINE$—$edict_nanotech_alloy_augmentation$$TABBED_NEW_LINE$—$edict_nanotech_energy_augmentation$" - tr_rg_nanotech_finish_modifier_desc: "§Y解锁舰船:§!纳米拦截舰\n每§Y5§!年§Y$sm_nanite_harvester_plural$§!都会提升,可能是增加$r_nanites$矿藏的规模,或是直接产出一笔纳米机器人资源。该效果受到矿藏所依附的行星尺寸的限制。" + tr_rg_nanotech_finish_modifier_desc: "§Y解锁舰船:§!$RG_graygoo_mothership$\n每§Y5§!年§Y$sm_nanite_harvester_plural$§!都会提升,可能是增加$r_nanites$矿藏的规模,或是直接产出一笔纳米机器人资源。该效果受到矿藏所依附的行星尺寸的限制。" civic_rg_gray_cluster: "§Y遥远约定-星团开局§!" civic_rg_gray_non_cluster: "§Y遥远约定-银河开局§!" @@ -61,6 +61,25 @@ civic_tooltip_rg_gray_non_cluster: "选择在§Y银河系§!中开启你的冒险。适合不希望在L-星团中开局的玩家。" rg_tempest_invocator: "灰蛊核心" + REQUIRES_lgate_or_gray: "$TRIGGER_FAIL$已发现§Y$NAME_Gray$§!或拥有科技§Y$tech_lgate_activation$§!" + + RG_habitat_central_complex: "$pc_rg_grayhabitat$" + RG_habitat_central_complex_plural: "$pc_rg_grayhabitat$" + RG_habitat_central_complex_DESC: "一座§Y$pc_rg_grayhabitat$§!,可以容纳若干£pop£§Y人口§!并在非宜居行星的轨道上为£building£§Y建筑§!和£district£§Y区划§!提供空间。" + RG_habitat_central_complex_MEGASTRUCTURE_DETAILS: "§Y$pc_rg_grayhabitat$§!是完全由纳米机器组成的用于永久居住的自持空间站。" + RG_habitat_central_complex_CONSTRUCTION_INFO_DELAYED: "$REQUIREMENTS_HEADER$$major_orbital_requirements$\n\n$EFFECTS_HEADER$$NEW_LINE$—将创建一座可殖民的(规模:£planetsize£6)$pc_rg_grayhabitat$。$NEW_LINE$—$habitat_0_CONSTRUCTION_INFO_DELAYED$" + requires_RG_habitat_central_complex: "$TRIGGER_FAIL$§R需要恒星系中存在一座$habitat_central_complex$§!" + requires_not_RG_habitat_central_complex: "$TRIGGER_FAIL$§R恒星系内已存在$habitat_central_complex$,无法建造。§!" + + building_rg_nanolab_1: "§Y纳米研究设施§!" + building_rg_nanolab_1_desc: "在纳观尺度上进行研究带来对宇宙的全新视角。" + building_rg_nanolab_2: "§Y纳米研究复合体§!" + building_rg_nanolab_2_desc: "无限小与无限大看起来是如此地相似,这是多么地奇妙啊。" + building_rg_nanotech_cauldron: "纳米熔炉" + building_rg_nanotech_cauldron_desc: "在分子水平上运作,虫群可以很容易地将矿物结构重新配置成坚固的合金晶格。" + building_rg_nanite_transmuter: "纳米变形器" + building_rg_nanite_transmuter_desc: "该工厂使用极为先进的纳米材料大量生产各种稀有资源。缺少纳米材料时生产将会暂停。" + district_rg_farming: "农业区段" district_rg_farming_plural: "农业区段" district_rg_farming_desc: "无垠的农田之海充斥着这个区段,其中种满了大量的食物。" @@ -492,7 +511,7 @@ pc_rg_grayhabitat: "纳米空间站点" pc_rg_grayhabitat_desc: "一座由纳米机械组成的深空居所,能提供仿佛行星一般的居住体验,具体而言是指行星上的城市区域。完全由纳米机器人组成使得建筑如梦幻般瞬间出现,由纳米机器组成的实体承担着空间站点的一切生产工作。\n§Y空间站点的$PLANET_SIZE$会随着$NAME_Gray$领袖等级(§Y[owner.rg_gray_level]§!)的提升而扩展。初始$PLANET_SIZE$为10,每级领袖等级提升2$PLANET_SIZE$。§!" -扩大 + rg_ap_nantiematter:0 "§Y纳米物质构成工程§!" rg_ap_nantiematter_desc:0 "如果能够对L星门建造者的物质与科技进行一次彻底的构成研究,这些强力的纳米机器将极大的提升我们的军备水平。这需要我们获得足够的L星门认知。" rg_ap_nantiematter_tooltip:0 "§Y这表明了一切。§!"