From 880e44991ef95065e74163d22281429a134b1ba9 Mon Sep 17 00:00:00 2001 From: Henrique Gemignani Passos Lima Date: Sat, 7 May 2022 17:22:00 +0300 Subject: [PATCH 1/5] Artaria: Activate EMMI by default --- .../files/levels/s010_cave.lc.lua | 21 ++++++++++--------- open_dread_rando/static_fixes.py | 14 +++++++++++++ 2 files changed, 25 insertions(+), 10 deletions(-) diff --git a/open_dread_rando/files/levels/s010_cave.lc.lua b/open_dread_rando/files/levels/s010_cave.lc.lua index 3dcf957f8..c9f302d72 100644 --- a/open_dread_rando/files/levels/s010_cave.lc.lua +++ b/open_dread_rando/files/levels/s010_cave.lc.lua @@ -108,6 +108,7 @@ function s010_cave.InitFromBlackboard() CAVES_TUTO_MAP_ROOM_DONE = Scenario.ReadFromBlackboard(Scenario.LUAPropIDs.CAVES_TUTO_MAP_ROOM_DONE, false) QUARENTINE_OPENED = Blackboard.GetProp("GAME_PROGRESS", "QUARENTINE_OPENED") s010_cave.CheckScorpiusDead() + s010_cave.EmmyCaveSpawnSequence() if Game.GetFromGameBlackboardSection("PlayedCutscenes", "CutScenePlayed[cutscenes/0049centralunitdetectsamus01/0049centralunitdetectsamus01.bmscu]") == 0 then local L0_2 = Game.GetActor( "DoorEmmy11") @@ -298,11 +299,11 @@ end function s010_cave.EmmyCaveSpawnSequence() - local oActor1 = Game.GetActor("Door062 (PW-PW, Special)") - if oActor1 ~= nil then - oActor1.LIFE:CloseDoor(true, true, true) - oActor1.LIFE:LockDoor() - end + --local oActor1 = Game.GetActor("Door062 (PW-PW, Special)") + --if oActor1 ~= nil then + -- oActor1.LIFE:CloseDoor(true, true, true) + -- oActor1.LIFE:LockDoor() + --end local oActor2 = Game.GetActor("PRP_CV_CentralUnitCaves") if oActor2 ~= nil then @@ -316,7 +317,7 @@ function s010_cave.EmmyCaveSpawnSequence() oActor3.bEnabled = false end - GUI.AddEmmyMissionLogEntry("#MLOG_ENCOUNTER_EMMY_CAVE") + --GUI.AddEmmyMissionLogEntry("#MLOG_ENCOUNTER_EMMY_CAVE") if Scenario.CheckEmmyAlive(CurrentScenario.oEmmyEntity) then CurrentScenario.oEmmyEntity.bEnabled = true end @@ -1140,10 +1141,10 @@ function s010_cave.OnSubAreaChange(old_subarea, old_actorgroup, new_subarea, new end end - local oActor = Game.GetActor("cutsceneplayer_37") - if oActor ~= nil then - oActor.CUTSCENE:TryLaunchCutscene() - end + --local oActor = Game.GetActor("cutsceneplayer_37") + --if oActor ~= nil then + -- oActor.CUTSCENE:TryLaunchCutscene() + --end elseif old_subarea == "collision_camera_064" and new_subarea == "collision_camera_074" then if disable_fade then local oActor = Game.GetActor("TG_EnableSubareaChangeFade_001") diff --git a/open_dread_rando/static_fixes.py b/open_dread_rando/static_fixes.py index a94cccd82..34d33d0be 100644 --- a/open_dread_rando/static_fixes.py +++ b/open_dread_rando/static_fixes.py @@ -120,7 +120,21 @@ def add_callback_to_kraid(editor: PatcherEditor): }) +def activate_emmi_zones(editor: PatcherEditor): + # Remove the cutscene that plays when you enter the emmi zone for the first time + # This causes the border of the zone to not be revealed, but it should be possible to do that in another way + editor.remove_entity( + { + "scenario": "s010_cave", + "layer": "Cutscenes", + "actor": "cutscenetrigger_36" + }, + None, + ) + + def apply_static_fixes(editor: PatcherEditor): remove_problematic_x_layers(editor) + activate_emmi_zones(editor) apply_one_sided_door_fixes(editor) add_callback_to_kraid(editor) From 001537b7220ad84c1986ac837b950583ed7f58c1 Mon Sep 17 00:00:00 2001 From: Henrique Gemignani Passos Lima Date: Sat, 7 May 2022 22:44:20 +0300 Subject: [PATCH 2/5] Cataris: remove emmi intro cutscene --- open_dread_rando/files/levels/s020_magma.lc.lua | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/open_dread_rando/files/levels/s020_magma.lc.lua b/open_dread_rando/files/levels/s020_magma.lc.lua index 19e302137..62b6480a6 100644 --- a/open_dread_rando/files/levels/s020_magma.lc.lua +++ b/open_dread_rando/files/levels/s020_magma.lc.lua @@ -781,11 +781,11 @@ function s020_magma.OnSubAreaChange(old_subarea, old_actorgroup, new_subarea, ne if oActor ~= nil then oActor.CUTSCENE:TryLaunchCutscene() end - elseif old_subarea == "collision_camera_052" and new_subarea == "collision_camera_020" then - local oActor = Game.GetActor("cutsceneplayer_38") - if oActor ~= nil then - oActor.CUTSCENE:TryLaunchCutscene() - end + --elseif old_subarea == "collision_camera_052" and new_subarea == "collision_camera_020" then + -- local oActor = Game.GetActor("cutsceneplayer_38") + -- if oActor ~= nil then + -- oActor.CUTSCENE:TryLaunchCutscene() + -- end elseif old_subarea == "collision_camera_063" and new_subarea == "collision_camera_044" then Game.PlayCurrentEnvironmentMusic() elseif old_subarea == "collision_camera_022" and new_subarea == "collision_camera_030" then From 607e105778218893bac214bd65ce2d08c90e9c4a Mon Sep 17 00:00:00 2001 From: Henrique Gemignani Passos Lima Date: Sun, 8 May 2022 23:29:09 +0300 Subject: [PATCH 3/5] Dairon: Activate emmi by default --- .../files/levels/s030_baselab.lc.lua | 28 ++++++++++--------- open_dread_rando/static_fixes.py | 11 ++++++++ 2 files changed, 26 insertions(+), 13 deletions(-) diff --git a/open_dread_rando/files/levels/s030_baselab.lc.lua b/open_dread_rando/files/levels/s030_baselab.lc.lua index e18d05164..add2c1b15 100644 --- a/open_dread_rando/files/levels/s030_baselab.lc.lua +++ b/open_dread_rando/files/levels/s030_baselab.lc.lua @@ -73,6 +73,8 @@ function s030_baselab.InitFromBlackboard() LAB_EMMY_SPAWNED = Scenario.ReadFromBlackboard(Scenario.LUAPropIDs.LAB_EMMY_SPAWNED, false) LAB_POSTXRELEASE_APPLIED = Scenario.ReadFromBlackboard(Scenario.LUAPropIDs.LAB_POSTXRELEASE_APPLIED, false) QUARENTINE_OPENED = Blackboard.GetProp("GAME_PROGRESS", "QUARENTINE_OPENED") + s030_baselab.OnEnter_EmmyLAB_Presentation() + if QUARENTINE_OPENED == true then s030_baselab.Activate_Setup_PostXRelease() end @@ -134,25 +136,25 @@ function s030_baselab.OnEnter_EmmyLAB_Presentation() print("ACTIVANDO EMMY") - GUI.AddEmmyMissionLogEntry("#MLOG_ENCOUNTER_EMMY_LAB") + --GUI.AddEmmyMissionLogEntry("#MLOG_ENCOUNTER_EMMY_LAB") local oActor = Game.GetActor("TG_EmmyLAB_Deactivation") if oActor ~= nil then oActor.bEnabled = false end Scenario.WriteToBlackboard(Scenario.LUAPropIDs.LAB_EMMY_SPAWNED, "b", true) LAB_EMMY_SPAWNED = true - if Scenario.CheckEmmyAlive(CurrentScenario.oEmmyEntity) and CurrentScenario.oEmmyEntity ~= nil then - local oActor = Game.GetActor("LM_EmmyPresentation") - CurrentScenario.oEmmyEntity.bEnabled = false - CurrentScenario.oEmmyEntity.vPos = oActor.vPos - CurrentScenario.oEmmyEntity.vAng = oActor.vAng - CurrentScenario.oEmmyEntity.bEnabled = true - print("EMMY REACTIVADO") - end - local oShutter = Game.GetActor("doorshutter_001") - if oShutter ~= nil then - oShutter.ANIMATION:SetAction("opened", true) - end + --if Scenario.CheckEmmyAlive(CurrentScenario.oEmmyEntity) and CurrentScenario.oEmmyEntity ~= nil then + -- local oActor = Game.GetActor("LM_EmmyPresentation") + -- CurrentScenario.oEmmyEntity.bEnabled = false + -- CurrentScenario.oEmmyEntity.vPos = oActor.vPos + -- CurrentScenario.oEmmyEntity.vAng = oActor.vAng + -- CurrentScenario.oEmmyEntity.bEnabled = true + -- print("EMMY REACTIVADO") + --end + --local oShutter = Game.GetActor("doorshutter_001") + --if oShutter ~= nil then + -- oShutter.ANIMATION:SetAction("opened", true) + --end end function s030_baselab.EmmyLabSpawnSequenceEnd() diff --git a/open_dread_rando/static_fixes.py b/open_dread_rando/static_fixes.py index 34d33d0be..c3de10a85 100644 --- a/open_dread_rando/static_fixes.py +++ b/open_dread_rando/static_fixes.py @@ -132,6 +132,17 @@ def activate_emmi_zones(editor: PatcherEditor): None, ) + # Remove the cutscene that introduces the speed emmi + # This causes the border of the zone to not be revealed, but it should be possible to do that in another way + editor.remove_entity( + { + "scenario": "s030_baselab", + "layer": "cutscenes", + "actor": "cutscenetrigger_39" + }, + None, + ) + def apply_static_fixes(editor: PatcherEditor): remove_problematic_x_layers(editor) From 83b0808595c7bd0f51556605bf3bf4cd792a9ed7 Mon Sep 17 00:00:00 2001 From: Henrique Gemignani Passos Lima Date: Mon, 9 May 2022 02:11:34 +0300 Subject: [PATCH 4/5] Ferenia: Activate EMMI by default --- open_dread_rando/files/levels/s070_basesanc.lc.lua | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/open_dread_rando/files/levels/s070_basesanc.lc.lua b/open_dread_rando/files/levels/s070_basesanc.lc.lua index d736a8a63..c935fe325 100644 --- a/open_dread_rando/files/levels/s070_basesanc.lc.lua +++ b/open_dread_rando/files/levels/s070_basesanc.lc.lua @@ -54,9 +54,9 @@ function s070_basesanc.SetupDebugGameBlackboard() Blackboard.SetProp("PLAYER_INVENTORY", "ITEM_METROIDNIZATION", "f", 0) end - - - +function s070_basesanc.IsEmmiActive() + return true +end local QUARENTINE_OPENED = Blackboard.GetProp("GAME_PROGRESS", "QUARENTINE_OPENED") @@ -367,7 +367,7 @@ function s070_basesanc.OnCentralUnitEmmyReady(_ARG_0_, _ARG_1_) s070_basesanc.ChangePatrolEmmy("PATROLROUTE_01") print("EMMY: Generation OK. Starting patrol: " .. _ARG_1_.AI.sCurrentPatrol) - local L2_2 = Blackboard.GetProp("GAME_PROGRESS", "QUARENTINE_OPENED") + local L2_2 = s070_basesanc.IsEmmiActive() if L2_2 == true and CurrentScenario.oEmmyEntity.AI.bTargetInsideEmmyZone then print("QUARANTINE IS OPENED") else @@ -533,7 +533,7 @@ s070_basesanc.tEmmyDoor = nil function s070_basesanc.OnWalkThroughEmmyDoor(_ARG_0_, _ARG_1_, _ARG_2_) - local L3_2 = Blackboard.GetProp("GAME_PROGRESS", "QUARENTINE_OPENED") + local L3_2 = s070_basesanc.IsEmmiActive() if L3_2 == true and Scenario.CheckEmmyAlive(CurrentScenario.oEmmyEntity) then local L4_2 = Game.GetActor("emmy_sanc_deactivated") From aca441cffadce66ac5c1b9fe9f5dbc338e2b8cec Mon Sep 17 00:00:00 2001 From: Henrique Gemignani Passos Lima Date: Mon, 9 May 2022 02:21:32 +0300 Subject: [PATCH 5/5] Ghavoran: Activate EMMI by default --- open_dread_rando/files/levels/s050_forest.lc.lua | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/open_dread_rando/files/levels/s050_forest.lc.lua b/open_dread_rando/files/levels/s050_forest.lc.lua index 2f0c53460..00bf3157b 100644 --- a/open_dread_rando/files/levels/s050_forest.lc.lua +++ b/open_dread_rando/files/levels/s050_forest.lc.lua @@ -52,9 +52,9 @@ function s050_forest.SetupDebugGameBlackboard() Blackboard.SetProp("PLAYER_INVENTORY", "ITEM_METROIDNIZATION", "f", 0) end - - - +function s050_forest.IsEmmiActive() + return true +end @@ -341,7 +341,7 @@ function s050_forest.OnEmmyForestGenerated(_ARG_0_, _ARG_1_) AI.SetWorldGraphToEmmy("LE_WorldGraph", _ARG_1_.sName) s050_forest.ChangePatrolEmmy("PATROLROUTE_03") print("EMMY: Generation OK. Starting patrol: " .. _ARG_1_.AI.sCurrentPatrol) - if QUARENTINE_OPENED == true then + if s050_forest.IsEmmiActive() then print("QUARANTINE IS OPENED") else CurrentScenario.oEmmyEntity.bEnabled = false @@ -516,7 +516,7 @@ function s050_forest.OnWalkThroughEmmyDoor(_ARG_0_, _ARG_1_, _ARG_2_) - if QUARENTINE_OPENED == true and Scenario.CheckEmmyAlive(CurrentScenario.oEmmyEntity) then + if s050_forest.IsEmmiActive() and Scenario.CheckEmmyAlive(CurrentScenario.oEmmyEntity) then if _ARG_1_ then if CurrentScenario.oEmmyEntity ~= nil then if _ARG_2_ then