Fix joint limit constraint bugs
- local indexing bugs