void Update() { if (Input.GetMouseButtonUp(0)) { if (hover) { if (ButtonModel != null) { ButtonModel.localScale = Vector3.one * 1.25f; } } else { if (ButtonModel != null) { ButtonModel.localScale = Vector3.one * 1f; } } if (press) { arduino.LEDBuiltIn.SetActive(false); arduino.ArduinoReset(); } press = false; } transform.parent.position = parentTransform.position; transform.parent.rotation = parentTransform.rotation; }