Search Unity

Rotating objects on other rotating objects

Discussion in 'Getting Started' started by McFly85, Sep 18, 2019.

  1. McFly85

    McFly85

    Joined:
    Sep 17, 2018
    Posts:
    7
    Is it possible to have a rotating object that is connected to another object that is rotating on a different axis? Like an amusment park ride for example.

    My current experiments have failed by breaking apart parented objects at the rotating joints and left sections rotating in mid air, whereas seperately all sections work on their own.

    I assume I'm in for a headache of trying to understand Quaternions in depth but any links would be greatly appreciated because I'm not exactly sure where to start. Or if you could just put me out of my misery and tell me it can't be done, at least it will save me wasting a lot of time.
     
  2. McFly85

    McFly85

    Joined:
    Sep 17, 2018
    Posts:
    7
    Sorry, nevermind, I've spent too much time testing this in the runtime build mode I'm creating and not enough time testing the concept from edit mode. Apparently there's no issue creating what I mentioned, there's obviously a flaw in my building system.
     
    Joe-Censored and JoeStrout like this.
  3. Joe-Censored

    Joe-Censored

    Joined:
    Mar 26, 2013
    Posts:
    11,847
    Just make sure on the child object you're doing local rotation rather than worldspace rotation and you should be fine.
     
    McFly85 likes this.
  4. McFly85

    McFly85

    Joined:
    Sep 17, 2018
    Posts:
    7
    Thanks for the tip. Turned out to be a parenting conflict in my building system causing children to be abducted, but I didn't even think of local/worldspace rotation so I'll keep it in mind.
    Cheers.
     
    Joe-Censored likes this.