1. #1
    Blastergamer's Avatar Senior Member
    Join Date
    Mar 2014
    Location
    Rocking Trials Country
    Posts
    2,539

    Object rotating with the rider!

    Thanks to RedLynx I know how to stay an object above the rider
    But does anybody know how when the rider flips, the object will rotate with the rider?
    Example: Use a skulls head to position it in the riders head, and you want have the rider still looking like a skeleton when he flips with the bike. (That means the skull should rotate and stay in the rider head).
    Any helps would be appreciated
    Share this post

  2. #2
    dasraizer's Avatar Senior Member
    Join Date
    Apr 2014
    Location
    UK, Isle of Wight
    Posts
    1,195

    Re: Object rotating with the rider!

    simplest method is to physics joint the skull to the head, set the joint to custom, adjust the angular rotation limits so they're all 0 and set no collision and pivots combine, now move the pivot to the head location, easiest to do with a snap plane set on the riders head, now enable physics on the skull and set under advance physics 'no contact response' and set the mass to 0.1 kg.

    if you want to use OPE to the rider, you will suffer 1 frame lag as the Object Position Info (OPI) works on last location, however to do this with OPE use OPI, have 3 set to Positions (X/Y/Z) and 3 to Angle (X/Y/Z) and point these to the riders head, pass this into the skulls OPEs position and rotiaion, the Yaw/Pitch/Bank match X/Y/Z angles, i believe you need to have local unchecked and set rotation checked. under the skulls advance physics, set it to decoration only.

    if the lag is noticeable you need to add 1 frame of the riders heads velocity to the position, the velocities are found in the OPI, you'll need to divide the velocities by 60 (although i found 90ish to be better) and add each to the positions X/Y/Z before using them for the OPE.

    one last thing with OPE, if the skull is not pointing in the same direction as the rider, 1st see if unchecking set rotation cures it, else grab a glue pivot, set it to custom and set its rotation to the world axis(open editor options uncheck all x/y/z snap and make sure no objects are set to a snap plane) ,double click right stick on the pivot and PLACE THE GLUE IN THE WORLD (ie its not selected), now reselect the glue pivot and in its option choose members as the skull, select the glue group in the OPE, test to see if the skull matches the rider, if not select the skull with bumper held (ie picking single objects inside a glue group) , rotate and test until it matches the riders head.

    i think i've covered it, if you want i can break it down further.
    hope this helps some.
    Share this post

  3. #3

    Re: Object rotating with the rider!

    ?
    Just set the joint to 'Point-to-point'. No Collisions don't work with the rider because he can't be set to no collisions.

    Skull
    Physics ON
    |
    Point to point
    Pivot strength 50
    |
    Rider's head
    Share this post

  4. #4
    dasraizer's Avatar Senior Member
    Join Date
    Apr 2014
    Location
    UK, Isle of Wight
    Posts
    1,195

    Re: Object rotating with the rider!

    i suspect that setting the angular limits to 0 would be the same as point-to-point, and as for the pivot strength, i found anything much above 1 makes the back wheel buckle when the bike goes backwards.
    Share this post

  5. #5
    Lukeyy19's Avatar Member
    Join Date
    Mar 2014
    Location
    UK
    Posts
    449

    Re: Object rotating with the rider!

    Yeah I would just use a hard point to point joint, but as dasraiser said, don't increase the joint strength, it isn't going to be put under any strain so a high number will just cause problems in other areas.
    Share this post