Search Unity

  1. Unity 2019.2 is now released.
    Dismiss Notice

Configurable Joint - adjusting the linearLimit through scripting - strange issue

Discussion in 'Physics' started by D_3d, Nov 5, 2019.

  1. D_3d

    D_3d

    Joined:
    Feb 7, 2013
    Posts:
    2
    I am testing some scripting using the Configurable Joint connection between 2 objects. I am using Unity3d 2017.2.5f1

    I can adjust the linearLimit through scripting (using a keypress routine, in my void Update() ) - I can see the value altering in the Component GUI as expected.

    But, this only seems to have a dynamic effect (physically moves the object according to the linearLimit) if the object with the Configurable Joint is already in motion. If the object is stationary, the altering linearLimit value has no effect.

    If I manually adjust the value at run time directly in the component GUI, it always moves the object as expected.

    Is there something I am missing ? How can I have the altering linearLimit take effect at run time even if the object is not in motion ?

    Any help, pointers gratefully received ...

    D.
     
  2. D_3d

    D_3d

    Joined:
    Feb 7, 2013
    Posts:
    2
    OK, tearing my hair out going over everything I can about this problem.

    Downloaded latest version of Unity3D and the issue is resolved. Looks like it was a bug in 2017.

    Now the code is getting the result I expect.

    D.