LK_ShyPoints - Set points to shy and toggle show/hide shy points

Moho allows users to write new tools and plugins. Discuss scripting ideas and problems here.

Moderators: Víctor Paredes, Belgarath, slowtiger

Post Reply
User avatar
Lukas
Posts: 1296
Joined: Fri Apr 09, 2010 9:00 am
Location: Netherlands
Contact:

LK_ShyPoints - Set points to shy and toggle show/hide shy points

Post by Lukas »

Like shy bones, this let's you do the same with points.

Here's the download link:
Use my included custom Select Points tool to set bones to shy. Use the show/hide bones tool to toggle their visibility. I've got the keyboard shortcut set to <shift> + <B> to toggle shy points and <cmd/ctrl> + <B> to toggle shy bones (the latter might be default).

My select points tool has some really useful other features too.

edit: newer version are here:
Last edited by Lukas on Fri Jun 03, 2022 10:29 pm, edited 2 times in total.
User avatar
davoodice2
Posts: 381
Joined: Tue Jun 15, 2021 1:14 pm

Re: LK_ShyPoints - Set points to shy and toggle show/hide shy points

Post by davoodice2 »

Lukas wrote: Mon Oct 04, 2021 9:25 am Like shy bones, this let's you do the same with points.

Here's the download link:
Use my included custom Select Points tool to set bones to shy. Use the show/hide bones tool to toggle their visibility. I've got the keyboard shortcut set to <shift> + <B> to toggle shy points and <cmd/ctrl> + <B> to toggle shy bones (the latter might be default).

My select points tool has some really useful other features too.
fantastic!
thanks for sharing.
خیام اگر ز باده مستی خوش باش
با ماهرخی اگر نشستی خوش باش
چون عاقبت کار جهان نیستی است
انگار که نیستی چو هستی خوش باش
teotoon
Posts: 135
Joined: Wed Aug 04, 2004 7:19 am
Location: Turkey

Re: LK_ShyPoints - Set points to shy and toggle show/hide shy points

Post by teotoon »

Hello Lukas,

Thank you for posting these amazing scripts. I really love them. I installed your latest script but I constantly get this message:

[url]https://www.mediafire.com/file/d9awtjk6 ... 2.png/file[/url]

Any help?
User avatar
Lukas
Posts: 1296
Joined: Fri Apr 09, 2010 9:00 am
Location: Netherlands
Contact:

Re: LK_ShyPoints - Set points to shy and toggle show/hide shy points

Post by Lukas »

teotoon wrote: Tue Oct 05, 2021 12:39 pmThank you for posting these amazing scripts. I really love them. I installed your latest script but I constantly get this message
I've updated the .zip. The error should be gone now.

Edit: Just a second, the upload failed
Edit: Should be online now
AlexH
Posts: 5
Joined: Thu May 19, 2022 7:36 pm

Re: LK_ShyPoints - Set points to shy and toggle show/hide shy points

Post by AlexH »

Hello Lukas,

thank you very much for this Select-Points tweak. :D I'm currently assembling my first tool-set and your scripts are amazingly handy to use.

I'm using Moho 13.5.5 (x64), the zip-file from your post (SelectPoints Version 6.1) and have three things to point out (pun not intended):
1. the button for shy points currently displays "Shy bone" (really sorry for being so picky :oops: )
2. the button "Slink points horizontally" does the same as the "Slink points both horizontally and vertically" button
3. currently the option to toggle lasso mode through Ctrl seems brocken or maybe not completely implemented yet? When I hold the button and click i get a nil value exception for index field lassoList at 381 and don't know how to fix it. (again sorry, just started the ride into the wild world of Lua ;) )

Greetings Alex
User avatar
Lukas
Posts: 1296
Joined: Fri Apr 09, 2010 9:00 am
Location: Netherlands
Contact:

Re: LK_ShyPoints - Set points to shy and toggle show/hide shy points

Post by Lukas »

AlexH wrote: Fri Jun 03, 2022 3:40 pm Hello Lukas,

thank you very much for this Select-Points tweak. :D I'm currently assembling my first tool-set and your scripts are amazingly handy to use.

I'm using Moho 13.5.5 (x64), the zip-file from your post (SelectPoints Version 6.1) and have three things to point out (pun not intended):
1. the button for shy points currently displays "Shy bone" (really sorry for being so picky :oops: )
2. the button "Slink points horizontally" does the same as the "Slink points both horizontally and vertically" button
3. currently the option to toggle lasso mode through Ctrl seems brocken or maybe not completely implemented yet? When I hold the button and click i get a nil value exception for index field lassoList at 381 and don't know how to fix it. (again sorry, just started the ride into the wild world of Lua ;) )

Greetings Alex
I updated the first post with new url's for updated versions of the scripts. I think these issues are already solved in those versions. Let me know if there's still any issues with them.
AlexH
Posts: 5
Joined: Thu May 19, 2022 7:36 pm

Re: LK_ShyPoints - Set points to shy and toggle show/hide shy points

Post by AlexH »

Thank you Lukas and what a coincidence! I'm really sorry. I missed that you just updated your tools at mohoscripts.com one day ago (I will check out the other ones for sure! :D ).

The only remaining issue for the Select-Points-Tool I recognized at the moment is the nil value exception for index field lassoList (now at line 422) while holding Ctrl.

And maybe my screen resolution is too low, because the menu buttons couldn't be displayed completely and overlap the "Library" button, but I intend to fix that by shortening some button names.
AlexH
Posts: 5
Joined: Thu May 19, 2022 7:36 pm

Re: LK_ShyPoints - Set points to shy and toggle show/hide shy points

Post by AlexH »

I tried the Curvature- and Transform-Points-Tools too. The Lock Curvature feature is really neat! I can imagine some situations where this could be really a blessing in the skys. :D
Unfortunately now I have the issue that, if I create a point group (e.g. through setting their color with Select-Color) and enable "Show Bezier Handles" in the Curvature-tool, the beziere handles and points are displaced with a strange offset.
Same goes for the Transform-Points-Tool, but for every point, not just the ones within point groups, but this could be also a nice feature in case, someone would like to seperate the handles to get just the artwork. :wink:

Image
Image
Image
User avatar
Lukas
Posts: 1296
Joined: Fri Apr 09, 2010 9:00 am
Location: Netherlands
Contact:

Re: LK_ShyPoints - Set points to shy and toggle show/hide shy points

Post by Lukas »

AlexH wrote: Sun Jun 05, 2022 6:32 am I tried the Curvature- and Transform-Points-Tools too. The Lock Curvature feature is really neat! I can imagine some situations where this could be really a blessing in the skys. :D
Unfortunately now I have the issue that, if I create a point group (e.g. through setting their color with Select-Color) and enable "Show Bezier Handles" in the Curvature-tool, the beziere handles and points are displaced with a strange offset.
Same goes for the Transform-Points-Tool, but for every point, not just the ones within point groups, but this could be also a nice feature in case, someone would like to seperate the handles to get just the artwork. :wink:

Image
Image
Image
Thanks, I fixed it for LK_Curvature, the new version is uploaded here https://mohoscripts.com/script/LK_Curvature

Will update and fix LK_TransformPoints soon too.

(edit: Fixed and updated LK_TransformPoints too)
(edit2: Scrap that, don't use LK_TransformPoints at all, delete it and update LK_Curvature, the latest version works with the original transform points tool because it overrules the viewport code of LM_TransformPoints)
User avatar
Lukas
Posts: 1296
Joined: Fri Apr 09, 2010 9:00 am
Location: Netherlands
Contact:

Re: LK_ShyPoints - Set points to shy and toggle show/hide shy points

Post by Lukas »

I added an option to hold <shift> to constrain handle direction. Get v2.4 here: https://mohoscripts.com/script/LK_Curvature
AlexH
Posts: 5
Joined: Thu May 19, 2022 7:36 pm

Re: LK_ShyPoints - Set points to shy and toggle show/hide shy points

Post by AlexH »

Thank you again for keeping up. ;) I'm sorry to tell you that by holding Shift while dragging a handle I get the nil-value-exception "attempt to call method 'NearestPointOnLine' " (line 281).
But neverless the overruled Transform-Points-Tool works just fine and is a great idea in my opinion.

Also I would like to recommend you to currently remove your Transform-Points-Tool from the Select-Points ZIP and Optional-Section on MohoScripts, to prevent other users from using it in the current state.
https://mohoscripts.com/script/LK_SelectPoints

I'm looking forward to the Curvature-Tool with constrained Handles and Select-Points-Tool with Lasso-Toggle-Shortcut, but take your time. :D
User avatar
Lukas
Posts: 1296
Joined: Fri Apr 09, 2010 9:00 am
Location: Netherlands
Contact:

Re: LK_ShyPoints - Set points to shy and toggle show/hide shy points

Post by Lukas »

AlexH wrote: Wed Jun 08, 2022 8:40 amThank you again for keeping up. ;)
No problem, it's very useful for our production too, so I appreciate the bug tracking.
AlexH wrote: Wed Jun 08, 2022 8:40 amI'm sorry to tell you that by holding Shift while dragging a handle I get the nil-value-exception "attempt to call method 'NearestPointOnLine' " (line 281).
Sounds like you have an old version of FO_Utilities.lua installed. Try updating and see if that fixes it.
AlexH wrote: Wed Jun 08, 2022 8:40 amAlso I would like to recommend you to currently remove your Transform-Points-Tool from the Select-Points ZIP and Optional-Section on MohoScripts, to prevent other users from using it in the current state.
Nice catch, I thought I removed it everywhere. Should be gone now.
AlexH
Posts: 5
Joined: Thu May 19, 2022 7:36 pm

Re: LK_ShyPoints - Set points to shy and toggle show/hide shy points

Post by AlexH »

Sounds like you have an old version of FO_Utilities.lua installed. Try updating and see if that fixes it.
You were right. Everything is safe and sound now. :D
Post Reply