void ChangeTarget(bool turnOn) { if (turnOn) { if (tray.CheckIngredient(pickObject.name.Substring(0, 5))) { tray.target.gameObject.SetActive(true); } } else { if (tray.CheckIngredient(pickObject.name.Substring(0, 5))) { tray.target.gameObject.SetActive(false); } } }