mirror of
https://github.com/Outer-Wilds-New-Horizons/new-horizons.git
synced 2025-12-11 20:15:44 +01:00
fix softlock on vision torch
This commit is contained in:
parent
8b05d650d2
commit
dd4b9ea54a
@ -110,6 +110,15 @@ namespace NewHorizons.Builder.Props
|
||||
|
||||
StreamingHandler.SetUpStreaming(prop, sector);
|
||||
|
||||
var torchItem = prop.GetComponent<VisionTorchItem>();
|
||||
// Fix vision torch
|
||||
if (torchItem)
|
||||
{
|
||||
torchItem.enabled = true;
|
||||
torchItem.mindProjectorTrigger.enabled = true;
|
||||
torchItem.mindSlideProjector._mindProjectorImageEffect = SearchUtilities.Find("Player_Body/PlayerCamera").GetComponent<MindProjectorImageEffect>();
|
||||
}
|
||||
|
||||
foreach (var component in prop.GetComponentsInChildren<Component>(true))
|
||||
{
|
||||
/*
|
||||
@ -176,7 +185,8 @@ namespace NewHorizons.Builder.Props
|
||||
}
|
||||
|
||||
// Fix slide reel
|
||||
if (component is SlideCollectionContainer container)
|
||||
// softlocks if this object is a vision torch
|
||||
if (!torchItem && component is SlideCollectionContainer container)
|
||||
{
|
||||
sector.OnOccupantEnterSector.AddListener(_ => container.LoadStreamingTextures());
|
||||
}
|
||||
@ -186,14 +196,6 @@ namespace NewHorizons.Builder.Props
|
||||
socket._sector = sector;
|
||||
}
|
||||
|
||||
// Fix vision torch
|
||||
if (component is VisionTorchItem torchItem)
|
||||
{
|
||||
torchItem.enabled = true;
|
||||
torchItem.mindProjectorTrigger.enabled = true;
|
||||
torchItem.mindSlideProjector._mindProjectorImageEffect = SearchUtilities.Find("Player_Body/PlayerCamera").GetComponent<MindProjectorImageEffect>();
|
||||
}
|
||||
|
||||
// fix campfires
|
||||
if (component is InteractVolume interactVolume)
|
||||
{
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user