Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Attempted fix for Reverse Area 8 crash #379

Merged
merged 4 commits into from
Jun 17, 2024
Merged
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion src/open_samus_returns_rando/files/levels/s100_area10.lua
Original file line number Diff line number Diff line change
Expand Up @@ -208,6 +208,11 @@ function s100_area10.OnLarva_010_Generated(_ARG_0_, _ARG_1_)
end
end
function s100_area10.OnMetroidDead()
-- Disable the intro and the camera change triggers if a Metroid has been defeated, which means that Reverse Area 8 should be enabled
Game.DisableTrigger("TG_Intro_Larva")
if Game.GetEntity("TG_ChangeCamera_IntroLarva") ~= nil then
Game.GetEntity("TG_ChangeCamera_IntroLarva").TRIGGER:DisableTrigger()
end
if Blackboard.GetProp("DEFEATED_ENEMIES", "Metroid") ~= nil and s100_area10.iNumMetroids == Blackboard.GetProp("DEFEATED_ENEMIES", "Metroid") then
if Game.GetEntity("LE_ValveQueen") ~= nil then
Game.GetEntity("LE_ValveQueen").MODELUPDATER:SetMeshVisible("Valve", false)
Expand All @@ -226,7 +231,9 @@ function s100_area10.OnMetroidDead()
"collision_camera_019"
}) do
print(_FORV_7_)
Game.SetSubAreaCurrentSetup(_FORV_7_, "PostMetroids_001", true)
if Game.GetEntity("LE_ValveQueen") ~= nil then
Game.SetSubAreaCurrentSetup(_FORV_7_, "PostMetroids_001", true)
dyceron marked this conversation as resolved.
Show resolved Hide resolved
end
end
for _FORV_7_, _FORV_8_ in pairs({
"SpawnGroup029",
Expand Down