From 19befe8e83efc7f5c66aa229780df2a00896553c Mon Sep 17 00:00:00 2001 From: dyceron Date: Sat, 13 Apr 2024 19:37:57 -0400 Subject: [PATCH 1/2] Disable the intro spawn trigger for the alpha if already dead --- src/open_samus_returns_rando/files/levels/s000_surface.lua | 1 + 1 file changed, 1 insertion(+) diff --git a/src/open_samus_returns_rando/files/levels/s000_surface.lua b/src/open_samus_returns_rando/files/levels/s000_surface.lua index f81a0f1b..5bebcd90 100644 --- a/src/open_samus_returns_rando/files/levels/s000_surface.lua +++ b/src/open_samus_returns_rando/files/levels/s000_surface.lua @@ -249,6 +249,7 @@ end function s000_surface.OnEnter_Alpha_001_Dead() if 0 < Scenario.ReadFromBlackboard("entity_SG_Alpha_001_deaths", 0) then Game.SetSubAreaCurrentSetup("collision_camera_010", "PostAlpha_001", true) + Game.DisableEntity("TG_Intro_Alpha") end end function s000_surface.OnGenericCrawler_Generated(_ARG_0_, _ARG_1_) From 6950b75deb2dc609c351aeb1098374e840ce3aeb Mon Sep 17 00:00:00 2001 From: dyceron Date: Sun, 14 Apr 2024 03:09:04 -0400 Subject: [PATCH 2/2] DisableTrigger --- src/open_samus_returns_rando/files/levels/s000_surface.lua | 3 +-- .../files/templates/metroid_template.lua | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/src/open_samus_returns_rando/files/levels/s000_surface.lua b/src/open_samus_returns_rando/files/levels/s000_surface.lua index 5bebcd90..fd33b28b 100644 --- a/src/open_samus_returns_rando/files/levels/s000_surface.lua +++ b/src/open_samus_returns_rando/files/levels/s000_surface.lua @@ -76,7 +76,7 @@ function s000_surface.InitFromBlackboard() Game.SaturateSpawnGroup("SpawnGroup008") end if Scenario.ReadFromBlackboard("AlphaIntroPlayed", false) then - Game.DisableEntity("TG_Intro_Alpha") + Game.DisableTrigger("TG_Intro_Alpha") end -- if not Blackboard.GetProp("DEFEATED_ENEMIES", "Queen") or not (Blackboard.GetProp("DEFEATED_ENEMIES", "Queen") > 0) then Game.DisableEntity("LE_Queen_Door") @@ -524,7 +524,6 @@ function s000_surface.LaunchMeleeTutoCutscene() end function s000_surface.OnDnaAbsorbAnimation() Game.SetInGameMusicState("DEATH") - Game.DisableEntity("TG_Intro_Alpha") Scenario.WriteToBlackboard("alpha_killed", "b", true) end function s000_surface.OnMeleeTutoButtonPressed() diff --git a/src/open_samus_returns_rando/files/templates/metroid_template.lua b/src/open_samus_returns_rando/files/templates/metroid_template.lua index 53707d3f..81712620 100644 --- a/src/open_samus_returns_rando/files/templates/metroid_template.lua +++ b/src/open_samus_returns_rando/files/templates/metroid_template.lua @@ -36,7 +36,7 @@ function Metroid.RemoveMetroid(_ARG_0_) end Game.SetInGameMusicState("RELAX") if scenario == "s000_surface" then - Game.DisableEntity("TG_Intro_Alpha") + Game.DisableTrigger("TG_Intro_Alpha") Scenario.WriteToBlackboard("alpha_killed", "b", true) end Game.SaveGame("checkpoint", "AfterNewAbilityAcquired", "", true)