create new bones with 0 strength option
Moderators: Víctor Paredes, Belgarath, slowtiger
create new bones with 0 strength option
Since I find point binding more predictable and reliable, I haven't used bone strength in years, and I guess many Moho users are in the same boat. So having to turn it off for each single bone I have created has been suboptimal to say the least, and very prone to error. This option could be on the main settings, on the bone layer settings or on the create bone tool, as "strength for new bones: n", or "default strength: n". Something like that.
If there is currently a way to achieve this I'm all ears.
If there is currently a way to achieve this I'm all ears.
Re: create new bones with 0 strength option
In your Moho install there's a file called 'lm_add_bone.lua' open it with a texteditor and find the OnMouseDown function, somewhere in that function a lot of properties of the bone are set. If 'fStrength' is already in there, change the value to 0. If 'fStrength' is not mentioned in the lua file add:
save your edited version of the tool in your custom content folder in the tool folder.
Code: Select all
bone.fStrength = 0
- MrMiracle77
- Posts: 189
- Joined: Mon Jun 24, 2019 2:30 am
Re: create new bones with 0 strength option
I'm in a similar situation. But I often just select multiple bones at the same time and 0 them out simultaneously.
- Dave
(As Your GM)
(As Your GM)
Re: create new bones with 0 strength option
Thank you, I will. I should try to start diving into scripting and this seems like an easy task.Lukas wrote: ↑Fri Jul 01, 2022 1:51 pm In your Moho install there's a file called 'lm_add_bone.lua' open it with a texteditor and find the OnMouseDown function, somewhere in that function a lot of properties of the bone are set. If 'fStrength' is already in there, change the value to 0. If 'fStrength' is not mentioned in the lua file add:save your edited version of the tool in your custom content folder in the tool folder.Code: Select all
bone.fStrength = 0
Yeah I think that's very usual. But many times the problem is that I forgot to zero the strength of some smartbone that I created later, for example. Even when that is not the actual problem I am having, it's like the first thing I have to check every time something goes wrong, so I end using the bones strength tool frecuently. With this optional setting, I could even use the nice shortcut I have set for that tool for other thing, like vitruvian bones. Ahh the small things in life haha.MrMiracle77 wrote: ↑Fri Jul 01, 2022 2:59 pm I'm in a similar situation. But I often just select multiple bones at the same time and 0 them out simultaneously.
Re: create new bones with 0 strength option
A weight option with a default to the add bone tool would be nice.
Re: create new bones with 0 strength option
Oh, yeah! That makes a lot of sense: Add Bone could get numerical box where you can dial in your preferred bone strength, and a Zero check-box to override the numerical box setting.
Maybe something like this mockup...

It's consistent with other tools with optional modes and settings.
Maybe something like this mockup...

It's consistent with other tools with optional modes and settings.
Last edited by Greenlaw on Mon Aug 01, 2022 7:40 pm, edited 1 time in total.
NEW! Visit our Little Green Dog Channel on YouTube!
D.R. Greenlaw
Artist/Partner - Little Green Dog
Little Green Dog Channel | Greenlaw's Demo Reel Channel
D.R. Greenlaw
Artist/Partner - Little Green Dog
Little Green Dog Channel | Greenlaw's Demo Reel Channel
Re: create new bones with 0 strength option
yeah that would be perfect.
Re: create new bones with 0 strength option
Another yes for zero override.
Also, an option to make it default behavior in preferences, so it's always checked if that's what you want.
Also, an option to make it default behavior in preferences, so it's always checked if that's what you want.
- hayasidist
- Posts: 3830
- Joined: Wed Feb 16, 2011 8:12 pm
- Location: Kent, England
Re: create new bones with 0 strength option
I didn't get the suggested mod to work at first -- my screw up ... It works fine when you put the right code in the right place .. my bad!
---
I also agree that it's a good suggestion to have a user-option for bone strength, and I've logged a request for bone strength to be a UI option in the Add Bone tool.
[EDIT: corrected my blunder]

---
I also agree that it's a good suggestion to have a user-option for bone strength, and I've logged a request for bone strength to be a UI option in the Add Bone tool.
[EDIT: corrected my blunder]
Last edited by hayasidist on Fri Aug 05, 2022 1:47 pm, edited 1 time in total.
- synthsin75
- Posts: 10253
- Joined: Mon Jan 14, 2008 11:20 pm
- Location: Oklahoma
- Contact:
Re: create new bones with 0 strength option
Adding this at line 234 works for me:
bone.fStrength = 0
All new bones now have zero strength.
bone.fStrength = 0
All new bones now have zero strength.
- Wes
Donations: https://www.paypal.com/paypalme/synthsin75 (Thx, everyone.)
https://www.youtube.com/user/synthsin75
Scripting reference: https://mohoscripting.com/
Donations: https://www.paypal.com/paypalme/synthsin75 (Thx, everyone.)
https://www.youtube.com/user/synthsin75
Scripting reference: https://mohoscripting.com/
Re: create new bones with 0 strength option
Please find below a quick-edit version of the tool (lm_add_bone+) with suggested 2 additions. The script (when installed in custom tool folder) will replace the built-in tool.
Default strength value will be saved between sessions.
https://drive.google.com/file/d/1m_TbVZ ... sp=sharing
Default strength value will be saved between sessions.
https://drive.google.com/file/d/1m_TbVZ ... sp=sharing
Moho 14.3 » Win 11 Pro 64GB » NVIDIA GTX 1080ti 11GB
Moho 14.3 » Mac mini 2012 8GB » macOS 10.15 Catalina
Tube: SimplSam
Sam
Moho 14.3 » Mac mini 2012 8GB » macOS 10.15 Catalina
Tube: SimplSam
Sam
- synthsin75
- Posts: 10253
- Joined: Mon Jan 14, 2008 11:20 pm
- Location: Oklahoma
- Contact:
Re: create new bones with 0 strength option
Nice. And I never knew Moho would replace a default tool with a "+" added.
- Wes
Donations: https://www.paypal.com/paypalme/synthsin75 (Thx, everyone.)
https://www.youtube.com/user/synthsin75
Scripting reference: https://mohoscripting.com/
Donations: https://www.paypal.com/paypalme/synthsin75 (Thx, everyone.)
https://www.youtube.com/user/synthsin75
Scripting reference: https://mohoscripting.com/
Re: create new bones with 0 strength option
Thank you Sam!
Re: create new bones with 0 strength option
Wow Sam... Nice!
- synthsin75
- Posts: 10253
- Joined: Mon Jan 14, 2008 11:20 pm
- Location: Oklahoma
- Contact:
Re: create new bones with 0 strength option
Wow, I just tested it, and you can add anything after the LM stock script name and it still replaces the stock tool.
This will help a lot with identifying replacement tools by name.
Thanks, Sam.
This will help a lot with identifying replacement tools by name.
Thanks, Sam.
- Wes
Donations: https://www.paypal.com/paypalme/synthsin75 (Thx, everyone.)
https://www.youtube.com/user/synthsin75
Scripting reference: https://mohoscripting.com/
Donations: https://www.paypal.com/paypalme/synthsin75 (Thx, everyone.)
https://www.youtube.com/user/synthsin75
Scripting reference: https://mohoscripting.com/