Page 1 of 1
Move cursor along fixture edge
Posted: Tue Mar 05, 2013 12:37 pm
by iforce2d
Here is a script that moves the cursor along the perimeter of a fixture (polygon, line or loop) by a specified distance. See the comments in the source code for a few places where you can make adjustments:
Re: Move cursor along fixture edge
Posted: Tue Mar 05, 2013 1:29 pm
by dAlex65
Cool. Just two comments to script code:
1 In layout.json have "desc": "move along edeg" instead edge. Just typo

2 In four places have local coord (.pos) in code, but script only work correctly for me when I changed this to the world pos (.wpos).
Re: Move cursor along fixture edge
Posted: Tue Mar 05, 2013 2:37 pm
by iforce2d
Thanks Alex, nice catch! I spent quite a while making this but completely forgot to check it with a body that was not at 0,0 with angle 0 as well

The file has been fixed.