Search Unity

Bug Spherical ArticulationBody is completely buggy

Discussion in 'Physics' started by Fressbrett, Nov 20, 2020.

  1. Fressbrett

    Fressbrett

    Joined:
    Apr 11, 2018
    Posts:
    97
    Hello,
    I am currently testing out the ArticulationBody Joints in Unity 2020.2.0b6.
    All ArticulationBody Joint Types work fine, except the spherical one.

    My goal is to create a half-ball socket joint, imagine a sphere cut in half and all rotations around that half sphere are possible. The limits are set accordingly and all gameobjects are on the same layer, which doesn't collide with itself.

    upload_2020-11-20_2-28-15.png

    upload_2020-11-20_2-28-49.png


    Though when starting the game, my "arm" bugs out and moves uncontrollably out of its constraints towards the orange root articulation body, no matter what stiffness/limits/target/force is set.

    When changing Swing Y/Swing Z/Twist from "Limited" to "Free", the joint doesn't immediatly bug out - only when for instance the x drive target is set above 170, which still makes this unusable for my use case.

    upload_2020-11-20_2-35-1.png
     
  2. Sab_Rango

    Sab_Rango

    Joined:
    Aug 30, 2019
    Posts:
    121
    It's by giving proper value to every axis.
    For instance, the transform.rotation.x =0
    now the spherical joint's Y axis must follow these rules:


    spherical joint's Y axis:
    lower limit< transform.rotation.x <upper limit -------------e.g. -10<0<20-- is correct ( 20<0<-20--is wrong)

    Also 10<50<350 is correct ( 10<50<-10 -- is wrong)