Beispiel #1
0
 private void Update()
 {
     if (subscreen == null)
     {
         GameObject gameObject = GameObject.Find("SettingsSubScreen");
         if (gameObject != null)
         {
             subscreen = gameObject.transform;
         }
     }
     else
     {
         int num = subscreen.GetComponentsInChildren <StateMachine>(includeInactive: false).Length;
         if (num > 0)
         {
             BackButton.gameObject.SetActive(value: true);
         }
         else
         {
             BackButton.gameObject.SetActive(value: false);
         }
     }
     if (settingsPrefabCloseButton == null)
     {
         SettingsCloseButton componentInChildren = settingsLoader.GetComponentInChildren <SettingsCloseButton>();
         if (componentInChildren != null)
         {
             settingsPrefabCloseButton = componentInChildren.gameObject;
             settingsPrefabCloseButton.SetActive(value: false);
         }
     }
 }
 /// <summary>
 /// Callback to set the focus to the close button when hitting enter
 /// </summary>
 private void focusCloseButton()
 {
     SettingsCloseButton.Focus();
 }