Results 1 to 2 of 2

Thread: Rotate() around a pivot?

  1. #1

    Post Rotate() around a pivot?

    Currently, as far as I'm aware, there is no way to rotate via scripting around a pivot. Under the Gizmo tool, you can set the position of the Gizmo to either use the Center or the set Pivot point for rotation, but in scripting, we seem to be currently limited to only rotating around the Center of an object.

    If rotating around a pivot via scripting is an already implemented feature, an explanation on how to use it would be much appreciated.
    Last edited by Hiram Abiff; 09-25-2018 at 05:49 PM.

  2. #2
    I must mention..

    Since I had posted this thread before doing a good amount of testing; it appears that the specific rotation I was looking for does work by simply adjusting the X axis to rotate around the custom pivot. If you want to rotate around the center instead, I believe you'd also have to move the object and reposition it using setPosition.

    Using the Gizmo Tool with "Center" enabled on an object with a custom pivot, the position of the object is also changed to achieve the rotation; this is because the actual center of the object considered by TTS, Rotate or setRotation, is the objects custom pivot point.

    I highly believe rotating around the center of an object which has a custom pivot could be simplified by including a true or false with Rotate, this would allow using the center of the object in the very same way it is used with the gizmo; which is automatically updating its position to keep a rotation around the center without using setPosition to update it. e.g.

    obj.rotate({30, 90, 270}, center=true)

    This option could also be added to setPositionSmooth which would enable an alternate way to easily align certain objects based on their pivots or centers without using twice as many functions.

    If I'm misunderstanding something, please feel free to let me know.

Similar Threads

  1. Replies: 2
    Last Post: 05-01-2018, 05:38 PM
  2. smothmove and rotate questions...
    By Tragic in forum Scripting
    Replies: 1
    Last Post: 08-02-2017, 06:10 PM
  3. Suggestion: Enhanced rotate button.
    By grant10k in forum VR Support
    Replies: 0
    Last Post: 03-04-2017, 07:22 PM
  4. Unable to rotate round objects
    By Didero in forum Bug Reports
    Replies: 1
    Last Post: 09-11-2016, 04:36 PM
  5. [ADDED] [v4.2] Rotate card while inspecting it with Alt
    By Rade in forum Suggestions
    Replies: 1
    Last Post: 04-04-2015, 12:52 PM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •