void FixedUpdate() { if (!FlangeNutStateController.toTheMaximumPos()) { transform.Rotate(rotationAxis, rotationSpeed, Space.Self); } }
// Update is called once per frame void Update() { if (!FlangeNutStateController.toTheMaximumPos()) { if (reference) { transform.Rotate(rotation * Time.deltaTime, Space.Self); transform.Translate(movement * Time.deltaTime, Space.Self); } else { transform.Rotate(rotation * Time.deltaTime, Space.World); transform.Translate(movement * Time.deltaTime, Space.World); } } }