title: How to change object's pivot point using C# in Unity?
body: <p>I am trying to change the Pivot Point of an object in Unity 3D using C#.</p>
  
  <p>I am aware of editing the object in a design software beforehand to desired point but, in my specific situation,  the Pivot Point needs to be changed while game in running. </p>
  
  <p>Here is the code I am using to rotate the object from its left side:</p>
  
  <pre><code>    verticalInputLeft = Input.GetAxis("VerticalLeft");       
  
      rotationLeftX += verticalInputLeft * verticalSensitivity * Time.deltaTime;
      rotationLeftX = Mathf.Clamp(rotationLeftX, minAngle, maxAngle);
  
      transform.localEulerAngles = new Vector3(rotationLeftX, transform.localEulerAngles.y, transform.localEulerAngles.z);
  </code></pre>
  
  <p>I would like to use same method to apply rotation from right side. For that, I need to change the pivot point of the object while game is running.</p>
  
  <p>Thank you.</p>