Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

Distance joint - change distance from script

Discussion in 'Physics' started by Jan-Vrabel, Feb 12, 2016.

  1. Jan-Vrabel

    Jan-Vrabel

    Joined:
    Oct 24, 2015
    Posts:
    5
    Hey guys,

    I am trying to create simple crane, on the end of crane is box connected with distance joint (pic. A). Distance of this joint is managed by script. What is strange, that sometimes box is moved and connected correctly (pic. B), but sometimes happens, that only gizmo (in scene view) of distance is changed and box is still on old position (pic. C)
    Is there something more, what is needed for distance change?
     

    Attached Files:

  2. Jan-Vrabel

    Jan-Vrabel

    Joined:
    Oct 24, 2015
    Posts:
    5
    Looks, it is happening when box is grounded. In case, that box is starting in the air everything works fine