using System; using System.Collections; using System.Collections.Generic; using UnityEngine; public class ChangeInputWay : BaseToggle { private GameObject comburentDropdown; private GameObject comburentInputField; private void Start() { comburentDropdown = transform.parent.Find("Dropdown").gameObject; comburentInputField = transform.parent.Find("InputField").gameObject; } public override void RespondFun(bool value) { if (value) { comburentDropdown.SetActive(false); comburentInputField.SetActive(true); transform.parent.parent.GetComponent().chooseObj.GetComponent().combustibleInputWay = true; } else { comburentDropdown.SetActive(true); comburentInputField.SetActive(false); transform.parent.parent.GetComponent().chooseObj.GetComponent().combustibleInputWay = false; } } }