diff --git a/data/mods/Sky_Island/EOCs.json b/data/mods/Sky_Island/EOCs.json index be944d5fc60aa..c479f76d48f5e 100644 --- a/data/mods/Sky_Island/EOCs.json +++ b/data/mods/Sky_Island/EOCs.json @@ -19,13 +19,6 @@ "effect": [ { "math": [ "u_spell_level('island_hostile_eviction') = -1" ] }, { "math": [ "u_spell_level('island_close_tear_and_portal') = -1" ] }, - { "u_location_variable": { "global_val": "OM_HQ_origin" } }, - { - "u_location_variable": { "global_val": "OM_HQ_origin_npc" }, - "passable_only": true, - "min_radius": 2, - "max_radius": 10 - }, { "u_add_effect": "warpcloak", "intensity": 2, "duration": { "global_val": "invistime", "default": "3 s" } }, { "run_eocs": [ @@ -87,6 +80,7 @@ "effect": [ { "u_teleport": { "global_val": "OM_missionspot" }, + "success_message": "Your followers teleport with you.", "fail_message": "It seems some of your followers couldn't teleport with you.", "force": true }, @@ -104,6 +98,7 @@ }, { "u_teleport": { "global_val": "OM_missionspot" }, + "success_message": "You arrive on the raid.", "fail_message": "It seems the portal couldn't find a valid location.", "force": true }, @@ -115,6 +110,51 @@ "id": "EOC_return_OM_teleport", "//": "This is the EOC which actually returns you home. It brings you home and removes all warp-related effects including warp sickness. It heals you enough to fix broken limbs. It also resets the awayfromhome counter to 0 so warp sickness can be tracked properly next time you're out.", "effect": [ + { + "u_run_npc_eocs": [ + { + "id": "EOC_SKY_ISLAND_MISSION_DIMENSION_SHIFT_ADD_NPC_EFFECT_RETURN", + "condition": "u_following", + "effect": [ { "u_add_effect": "blind", "duration": 0 }, { "u_add_effect": "effect_sky_island_momentary_flight", "duration": 1 } ] + } + ], + "npc_range": 10, + "local": true + }, + { "u_add_effect": "blind", "duration": 0 }, + { "u_add_effect": "effect_sky_island_momentary_flight", "duration": 1 }, + { + "u_location_variable": { "global_val": "sky_dimension_teleport_departure" }, + "z_adjust": 7, + "z_override": true + }, + { + "u_location_variable": { "global_val": "sky_dimension_teleport_departure_npc" }, + "z_adjust": 7, + "z_override": true + }, + { + "u_run_npc_eocs": [ + { + "id": "EOC_return_to_dimension_teleport_followers", + "condition": "u_following", + "effect": [ + { "u_add_effect": "blind", "duration": 0 }, + { "u_add_effect": "effect_sky_island_momentary_flight", "duration": 1 }, + { "u_teleport": { "global_val": "sky_dimension_teleport_departure_npc" }, "force": true }, + { + "location_variable_adjust": { "global_val": "sky_dimension_teleport_departure_npc" }, + "x_adjust": [ -2, 2 ], + "y_adjust": [ -2, 2 ] + } + ] + } + ], + "npc_range": 10, + "local": true + }, + { "u_teleport": { "global_val": "sky_dimension_teleport_departure" }, "force": true }, + { "u_travel_to_dimension": "default", "npc_travel_radius": 10, "region_type": "default" }, { "u_run_npc_eocs": [ { @@ -150,10 +190,17 @@ "EOC_return_heal" ] }, + { "clear_dimension": "dimension_sky_island_mission" }, { "alter_timed_events": "return_portal_close" }, { "math": [ "timeawayfromhome = 0 - bonuspulses" ] } ] }, + { + "type": "effect_on_condition", + "id": "EOC_DIMENSION_HECK", + "condition": { "current_dimension": "dimension_sky_island_mission" }, + "effect": [ { "u_message": "You are on a mission" } ] + }, { "type": "effect_on_condition", "id": "EOC_award_material_tokens", diff --git a/data/mods/Sky_Island/effects.json b/data/mods/Sky_Island/effects.json index fcd73cf866e64..b4978561d3060 100644 --- a/data/mods/Sky_Island/effects.json +++ b/data/mods/Sky_Island/effects.json @@ -144,5 +144,12 @@ "name": [ "" ], "desc": [ "" ], "flags": [ "STEADY" ] + }, + { + "type": "effect_type", + "id": "effect_sky_island_momentary_flight", + "name": [ "" ], + "desc": [ "" ], + "flags": [ "LEVITATION" ] } ] diff --git a/data/mods/Sky_Island/obelisk_selector.json b/data/mods/Sky_Island/obelisk_selector.json index e081218c9b84f..e2de8672d5cd8 100644 --- a/data/mods/Sky_Island/obelisk_selector.json +++ b/data/mods/Sky_Island/obelisk_selector.json @@ -91,13 +91,14 @@ "id": "EOC_Random_Loc_Warp", "//": "Picks a random location of any kind and activates the actual teleport EOC.", "effect": [ + { "run_eocs": "EOC_SKY_ISLAND_MISSION_DIMENSION_SHIFT" }, { "u_location_variable": { "global_val": "OM_missionspot" }, "target_params": { "om_terrain": "field", "om_terrain_match_type": "CONTAINS", - "search_range": 1200, - "min_distance": 200, + "search_range": 200, + "min_distance": 0, "reveal_radius": { "global_val": "scoutingdistancelanding", "default": 0 }, "z": 0, "random": true @@ -111,13 +112,14 @@ "id": "EOC_Field_Loc_Warp", "//": "Picks a random field and activates the actual teleport EOC.", "effect": [ + { "run_eocs": "EOC_SKY_ISLAND_MISSION_DIMENSION_SHIFT" }, { "u_location_variable": { "global_val": "OM_missionspot" }, "target_params": { "om_terrain": "field", "om_terrain_match_type": "CONTAINS", - "search_range": 1200, - "min_distance": 200, + "search_range": 200, + "min_distance": 0, "reveal_radius": { "global_val": "scoutingdistancelanding", "default": 0 }, "z": 0, "random": true @@ -132,13 +134,14 @@ "//": "Picks a random basement and activates the actual teleport EOC.", "condition": { "math": [ "basementsunlocked == 1" ] }, "effect": [ + { "run_eocs": "EOC_SKY_ISLAND_MISSION_DIMENSION_SHIFT" }, { "u_location_variable": { "global_val": "OM_missionspot" }, "target_params": { "om_terrain": "basement", "om_terrain_match_type": "CONTAINS", - "search_range": 1200, - "min_distance": 200, + "search_range": 200, + "min_distance": 0, "reveal_radius": { "global_val": "scoutingdistancelanding", "default": 0 }, "z": -1, "random": true @@ -155,13 +158,14 @@ "//": "Picks a random rooftop and activates the actual teleport EOC.", "condition": { "math": [ "roofsunlocked == 1" ] }, "effect": [ + { "run_eocs": "EOC_SKY_ISLAND_MISSION_DIMENSION_SHIFT" }, { "u_location_variable": { "global_val": "OM_missionspot" }, "target_params": { "om_terrain": "roof", "om_terrain_match_type": "CONTAINS", - "search_range": 1200, - "min_distance": 200, + "search_range": 200, + "min_distance": 0, "reveal_radius": { "global_val": "scoutingdistancelanding", "default": 0 }, "z": 1, "random": true @@ -178,13 +182,14 @@ "//": "Picks a random underground lab and activates the actual teleport EOC.", "condition": { "and": [ { "math": [ "labsunlocked == 1" ] }, { "u_has_items": { "item": "warp_labs_catalyst", "count": 1 } } ] }, "effect": [ + { "run_eocs": "EOC_SKY_ISLAND_MISSION_DIMENSION_SHIFT" }, { "u_location_variable": { "global_val": "OM_missionspot" }, "target_params": { "om_terrain": "lab_stairs", "om_terrain_match_type": "CONTAINS", - "search_range": 1200, - "min_distance": 200, + "search_range": 200, + "min_distance": 0, "reveal_radius": { "global_val": "scoutingdistancelanding", "default": 0 }, "z": -2, "random": true @@ -195,5 +200,57 @@ { "math": [ "goingtolabs = 1" ] }, { "run_eocs": [ "EOC_initiate_randomport" ] } ] + }, + { + "type": "effect_on_condition", + "id": "EOC_SKY_ISLAND_MISSION_DIMENSION_SHIFT", + "effect": [ + { "u_location_variable": { "global_val": "OM_HQ_origin" } }, + { + "u_location_variable": { "global_val": "OM_HQ_origin_npc" }, + "passable_only": true, + "min_radius": 2, + "max_radius": 10 + }, + { + "u_location_variable": { "global_val": "sky_dimension_teleport_departure" }, + "z_adjust": -3, + "z_override": true + }, + { + "u_location_variable": { "global_val": "sky_dimension_teleport_departure_npc" }, + "z_adjust": -3, + "z_override": true + }, + { + "location_variable_adjust": { "global_val": "sky_dimension_teleport_departure_npc" }, + "x_adjust": [ -2, 2 ], + "y_adjust": [ -2, 2 ] + }, + { + "u_run_npc_eocs": [ + { + "id": "EOC_SKY_ISLAND_MISSION_DIMENSION_SHIFT_ADD_NPC_EFFECT", + "condition": "u_following", + "effect": [ + { "u_add_effect": "blind", "duration": 0 }, + { "u_add_effect": "effect_sky_island_momentary_flight", "duration": 2 }, + { "u_teleport": { "global_val": "sky_dimension_teleport_departure_npc" }, "force": true }, + { + "location_variable_adjust": { "global_val": "sky_dimension_teleport_departure_npc" }, + "x_adjust": [ -2, 2 ], + "y_adjust": [ -2, 2 ] + } + ] + } + ], + "npc_range": 10, + "local": true + }, + { "u_add_effect": "blind", "duration": 0 }, + { "u_add_effect": "effect_sky_island_momentary_flight", "duration": 2 }, + { "u_teleport": { "global_val": "sky_dimension_teleport_departure" }, "force": true }, + { "u_travel_to_dimension": "dimension_sky_island_mission", "npc_travel_radius": 10, "region_type": "default" } + ] } ]