mirror of
https://github.com/Outer-Wilds-New-Horizons/new-horizons.git
synced 2025-12-11 20:15:44 +01:00
Fix subtitle breaking when theres only one
This commit is contained in:
parent
c615902702
commit
90c3b9b785
@ -72,6 +72,7 @@ namespace NewHorizons.Handlers
|
||||
_subtitleDisplay.transform.localPosition = new Vector3(0, 0, 0);
|
||||
_subtitleDisplay.transform.localScale = new Vector3(0.75f, 0.75f, 0.75f);
|
||||
_graphic = _subtitleDisplay.gameObject.GetAddComponent<Graphic>();
|
||||
_subtitleDisplay.gameObject.GetAddComponent<LayoutElement>().minWidth = SUBTITLE_WIDTH;
|
||||
|
||||
AddSubtitles();
|
||||
}
|
||||
@ -126,6 +127,8 @@ namespace NewHorizons.Handlers
|
||||
if (_subtitleDisplay.sprite == null)
|
||||
{
|
||||
_subtitleDisplay.sprite = possibleSubtitles[0];
|
||||
// Always call this in case we stop changing subtitles after
|
||||
ChangeSubtitle();
|
||||
}
|
||||
|
||||
// don't fade transition subtitles if there's only one subtitle
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user