string getName(HelperPlant plant) { if (!plantManager) { plantManager = PlantsManager.Instance; } return(JsonManager.Instance.getPlant(plant.type).name + "\n"); }
// Start is called before the first frame update void Start() { plantManager = PlantsManager.Instance; //init stats hudByProperty = new Dictionary <PlantProperty, OneStatHud>(); foreach (var pair in plantManager.currentResource) { GameObject oneStatInstance = Instantiate(oneStatPrefab, statsContent.transform); OneStatHud oneStatHud = oneStatInstance.GetComponent <OneStatHud>(); hudByProperty[pair.Key] = oneStatHud; } //init plant buttons UpdatePlantButtons(); }
// Start is called before the first frame update void Start() { plantManager = PlantsManager.Instance; }
// Start is called before the first frame update void Start() { plantManager = PlantsManager.Instance; gameObject.SetActive(false); }
void Awake() { PlantsManagerInstance = this; }