
Switch Selection concept for v13.5
Moderators: Víctor Paredes, Belgarath, slowtiger
Re: Switch Selection concept for v13.5
Woah, that looks pretty awesome. 

Re: Switch Selection concept for v13.5
Woah, that looks pretty awesome.

synthsin75 wrote: ↑Tue May 18, 2021 1:39 am Thanks to the above help from Alexandra and a break in my other work, I should be able to release this this week. It's very close. I just need to fix some image file management.
![]()
Re: Switch Selection concept for v13.5
Wow, amazing work Wes!
Edit: I've built and have been using a custom tool for switches within a rig too that I never got around to sharing. It has some nice buttons per switch:
If you want to implement any of that I can share the code and/or icons. My main problem ended up being limited toolbar space (especially on smaller screens). But its nice to control stuff from the bone layer without having to set up smartbones for everything (which also loses interpolation options). I've noticed having many layers visible on the timeline slows Moho down a lot, that's why I started experimenting with this, but it's also why I still sometimes wonder if its ever a good idea to rig with switch layers at all because I prefer seeing all of a characters keys on the top layer.
Edit: I've built and have been using a custom tool for switches within a rig too that I never got around to sharing. It has some nice buttons per switch:
- go to switchlayer (and back to bone layer)
- toggle timeline visiblity
- go to prev/next key
- see if there's a key at the current frame and if its step or smooth
- clean switch keys

If you want to implement any of that I can share the code and/or icons. My main problem ended up being limited toolbar space (especially on smaller screens). But its nice to control stuff from the bone layer without having to set up smartbones for everything (which also loses interpolation options). I've noticed having many layers visible on the timeline slows Moho down a lot, that's why I started experimenting with this, but it's also why I still sometimes wonder if its ever a good idea to rig with switch layers at all because I prefer seeing all of a characters keys on the top layer.
- gilcartunista
- Posts: 55
- Joined: Mon Mar 14, 2016 7:13 pm
- Location: https://www.facebook.com/gil.cartunista
- Contact:
Re: Switch Selection concept for v13.5
Fantástico!!!Maravilhoso!!!Wes !!!Estou ansioso para experimentar!!!
- synthsin75
- Posts: 10264
- Joined: Mon Jan 14, 2008 11:20 pm
- Location: Oklahoma
- Contact:
Re: Switch Selection concept for v13.5
- 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/
- gilcartunista
- Posts: 55
- Joined: Mon Mar 14, 2016 7:13 pm
- Location: https://www.facebook.com/gil.cartunista
- Contact:
Re: Switch Selection concept for v13.5
Estou tão contente que esta ferramenta foi lançada! mas no momento não tenho dinheiro para comprar moho13, tem alguma possibilidade de eu usar em minha versão 11, pois esta eu comprei e tenho número serial. Grato
- gilcartunista
- Posts: 55
- Joined: Mon Mar 14, 2016 7:13 pm
- Location: https://www.facebook.com/gil.cartunista
- Contact:
Re: Switch Selection concept for v13.5
I am so glad that this tool has been launched! but at the moment I don't have the money to buy moho13, there is some possibility that I can use it in my version 11, because this one I bought and I have a serial number. Grateful
-
- Posts: 9
- Joined: Fri Sep 13, 2013 10:45 pm
Re: Switch Selection concept for v13.5
Holy Smokes! Thank you Wes! I've been in LA for a few months working nonstop and totally forgot about starting this thread. I can't wait to dive and use this. THANK YOU!
-
- Posts: 224
- Joined: Sat Sep 03, 2011 3:34 am
Re: Switch Selection concept for v13.5
Quite interesting... will give it a try with an existing character.
- synthsin75
- Posts: 10264
- Joined: Mon Jan 14, 2008 11:20 pm
- Location: Oklahoma
- Contact:
Re: Switch Selection concept for v13.5
Apparently AutoHotkey can't output to the same command prompt Lua reads.A.Evseeva wrote: ↑Sat Jan 30, 2021 9:12 amIt can be done with:synthsin75 wrote: ↑Fri Jan 29, 2021 6:49 pm While it's easy enough to pass arguments from Moho Lua to external apps/scripts, it's not as easy to get data back. I think the only way is to write the data to a file, so Lua can read it.This will return text, external command (script) outputs with its "print" callsCode: Select all
function capture(cmd) local f = assert(io.popen(cmd, 'r')) local s = assert(f:read('*a')) f:close() return s end

- 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: Switch Selection concept for v13.5
The other option would be to pass a filename to external app, which it populates, then read/delete the contents of that file after the call.
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: 10264
- Joined: Mon Jan 14, 2008 11:20 pm
- Location: Oklahoma
- Contact:
Re: Switch Selection concept for v13.5
That's my current plan.
- 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/
- hayasidist
- Posts: 3840
- Joined: Wed Feb 16, 2011 8:12 pm
- Location: Kent, England
Re: Switch Selection concept for v13.5
this (windows) example works without the intermediate file
IOW the output of cmd>dir ... is delivered in the fcb:read ... call (and in this instance provides a simple list of all the .pngs in path)
Code: Select all
local sOut = io.popen( "dir /B " .. path .. "*.png", "r" )
local sData = sOut:read "*a"
Last edited by hayasidist on Sat Dec 09, 2023 11:53 am, edited 1 time in total.
- synthsin75
- Posts: 10264
- Joined: Mon Jan 14, 2008 11:20 pm
- Location: Oklahoma
- Contact:
Re: Switch Selection concept for v13.5
The problem is outputting from AutoHotkey, not reading with Lua.hayasidist wrote: ↑Sat Dec 09, 2023 11:48 am this (windows) example works (worked in Lua 5.2 - not tried in 5.4) without the intermediate file
IOW the output of cmd>dir ... is delivered in the fcb:read ... call (and in this instance provides a simple list of all the .pngs in path)Code: Select all
local sOut = io.popen( "dir /B " .. path .. "*.png", "r" ) local sData = sOut:read "*a"
- 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/
- hayasidist
- Posts: 3840
- Joined: Wed Feb 16, 2011 8:12 pm
- Location: Kent, England
Re: Switch Selection concept for v13.5
ah! sorry. my misunderstanding