// Start is called before the first frame update void Start() { eqLabel = GameObject.FindGameObjectWithTag("Name").GetComponent <InputField>(); eqDescription = GameObject.FindGameObjectWithTag("Description").GetComponent <InputField>(); eqDrop = FindObjectOfType <Dropdown>(); FillDrop.Fill(ref eqDrop, CharacterStatic.eqLable); }
void Start() { abilityLabel = GameObject.FindGameObjectWithTag("Name").GetComponent <InputField>(); abilityDescription = GameObject.FindGameObjectWithTag("Description").GetComponent <InputField>(); abilityLevel = GameObject.FindGameObjectWithTag("input").GetComponent <Toggle>(); abilityDrop = FindObjectOfType <Dropdown>(); FillDrop.Fill(ref abilityDrop, CharacterStatic.abilityLable); }
public static void Delete(ref Dropdown drop) { int value = drop.value; File.Delete(ProfileStatic.ProfileFolderPath + "/" + drop.options[value].text + ".dat"); drop.ClearOptions(); FillDrop.Fill(ref drop, ProfileStatic.ProfileFolderPath); }
void Start() { statsFields = GameObject.FindGameObjectsWithTag("input"); label = GameObject.FindGameObjectWithTag("Name").GetComponent <InputField>(); statsDrop = FindObjectOfType <Dropdown>(); FillDrop.Fill(ref statsDrop, CharacterStatic.statsLable); slots = GameObject.FindGameObjectWithTag("Slots").GetComponent <InputField>(); slots.text = 5.ToString(); }
void Start() { if (ProfileStatic.ProfileFolderPath == null) { SceneManager.LoadScene(0); } else { FillDrop.Fill(ref sheetDrop, ProfileStatic.ProfileFolderPath); } ClearStatic.Clear(); }
/// <summary> /// Save values from inputs fields to dropdown component. /// </summary> /// <param name="drop">Dropdown object.</param> /// <param name="labels">List of labels where you wanna delete values.</param> /// <param name="inputs">Array of InputFields to save in dropdown.</param> public static void Delete(ref Dropdown drop, List <string> labels, InputField[] inputs) { drop.ClearOptions(); if (labels.Count > 0) { FillDrop.Fill(ref drop, labels); } else { foreach (var item in inputs) { item.text = null; } } if (drop.options.Count == 0) { foreach (var item in GameObject.FindGameObjectsWithTag("HiddenButton")) { item.GetComponent <Button>().interactable = false; } } }