mirror of
https://github.com/All-Of-Us-Mods/MiraAPI.git
synced 2026-10-19 15:51:48 +00:00
more null checks, yay!
This commit is contained in:
1 parent
4e37f8b3d4
commit
4d187f3f79
1 file changed
+10
-6
@@ -132,20 +132,24 @@ internal static class GameOptionsMenuPatch
|
||||
|
||||
if (!group.GroupVisible.Invoke())
|
||||
{
|
||||
if (group.Header.gameObject != null)
|
||||
if (group.Header != null && group.Header.gameObject != null)
|
||||
group.Header.gameObject.SetActive(false);
|
||||
foreach (var option in group.Options)
|
||||
{
|
||||
option.OptionBehaviour?.gameObject.SetActive(false);
|
||||
if (option.OptionBehaviour != null && option.OptionBehaviour.gameObject != null)
|
||||
option.OptionBehaviour?.gameObject.SetActive(false);
|
||||
}
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
if (group.Header.gameObject != null)
|
||||
group.Header.gameObject.SetActive(true);
|
||||
group.Header.transform.localScale = Vector3.one * 0.63f;
|
||||
group.Header.transform.localPosition = new Vector3(-0.903f, num, -2f);
|
||||
if (group.Header != null)
|
||||
{
|
||||
if (group.Header.gameObject != null)
|
||||
group.Header.gameObject.SetActive(true);
|
||||
group.Header.transform.localScale = Vector3.one * 0.63f;
|
||||
group.Header.transform.localPosition = new Vector3(-0.903f, num, -2f);
|
||||
}
|
||||
|
||||
num -= 0.58f;
|
||||
|
||||
|
||||
Reference in new issue
Block a user