Skip to content

Commit

Permalink
Disable low poly Samus if reloading from checkpoint during boss fight (
Browse files Browse the repository at this point in the history
…#406)

* Disable low poly Samus if reloading from checkpoint after starting boss

* Disable low poly when exiting the boss scenarios

For reloading save or warp to start in another scenario

* Fix names
  • Loading branch information
dyceron authored Jul 10, 2024
1 parent b0d826f commit b095f6d
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/open_samus_returns_rando/files/levels/s070_area7.lua
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@ s070_area7.tDNAScanLandmarks = {
function s070_area7.InitFromBlackboard()
Game.SetSubAreaCurrentSetup("collision_camera_037", "Omega_Enabled", true)
Scenario.WriteToBlackboard("OmegaDiscovered", "b", true)
s070_area7.SetLowModelsVisibility(false)
if Blackboard.GetProp("s070_area7", "entity_LE_HazarousPool_001_enabled") == nil then
Game.GetEntity("LE_HazarousPool_001").HAZAROUSPOOL:Activate(true)
Game.GetEntity("LE_HazarousPool_002").HAZAROUSPOOL:Activate(false)
Expand All @@ -107,6 +108,7 @@ end
function s070_area7.OnReloaded()
end
function s070_area7.OnExit()
s070_area7.SetLowModelsVisibility(false)
end
function s070_area7.OnEnter_ActivationDNA_001()
-- Game.OnDNAMechApproached("LE_ChozoUnlockAreaDNA_001", 1)
Expand Down
2 changes: 2 additions & 0 deletions src/open_samus_returns_rando/files/levels/s100_area10.lua
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@ function s100_area10.InitFromBlackboard()
Game.DisableEntity("LE_Baby_Hatchling")
Game.DisableTrigger("TG_MetroidRadar")
Game.GetEntity("LE_RandoDNA").USABLE:Activate(false)
s100_area10.SetLowModelsVisibility(false)
if Game.GetEntity("LE_ValveQueen") ~= nil then
if Blackboard.GetProp("DEFEATED_ENEMIES", "Metroid") ~= nil and s100_area10.iNumMetroids == Blackboard.GetProp("DEFEATED_ENEMIES", "Metroid") then
Game.GetEntity("LE_ValveQueen").MODELUPDATER:SetMeshVisible("Valve", false)
Expand All @@ -100,6 +101,7 @@ end
function s100_area10.OnReloaded()
end
function s100_area10.OnExit()
s100_area10.SetLowModelsVisibility(false)
end
function s100_area10.OnEnter_ActivationTeleport_10_01()
Game.OnTeleportApproached("LE_Teleporter_10_01")
Expand Down
2 changes: 2 additions & 0 deletions src/open_samus_returns_rando/files/levels/s110_surfaceb.lua
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ function s110_surfaceb.ElevatorSetTarget(_ARG_0_)
GUI.ElevatorSetTarget("s000_surface_elevator", false)
end
function s110_surfaceb.InitFromBlackboard()
s110_surfaceb.SetLowModelsVisibility(false)
end
function s110_surfaceb.OnReloaded()
end
Expand All @@ -85,6 +86,7 @@ function s110_surfaceb.InitializeRidleyStorms()
end
end
function s110_surfaceb.OnExit()
s110_surfaceb.SetLowModelsVisibility(false)
end
function s110_surfaceb.RecoverEnergy()
if Game.GetPlayer() ~= nil then
Expand Down

0 comments on commit b095f6d

Please sign in to comment.