Continuing refactoring
Fixing distance joint error