Notifications
Clear all
[Closed] Short cut ….looping modPanel modifiers ?
Oct 30, 2008 3:11 pm
please, anyone can help me to create my own shortcut using keyboard.shiftPressed ?
my simple idea is :
-
using SHIFT + and SHIFT – to “walk thru” negative/positive numbers in modifiers
guess something like:
modifiers[i+1]
modifiers[i-1] -
more workflow without leaving the “expert mode toggle”
--tests...
---modPanel.setCurrentObject $.modifiers[#TurboSmooth]
-- keyboard.shiftPressed
--fn ThruModPanel =
--(
objs = ($selection)
for seL in objs do
(
(
modP = modPanel.setCurrentObject
ActiveMod = modP seL.modifiers[1] -- here, i want to change numbers with shortCut
)
print (ActiveMod)
)
--)
print (ThruModPanel)
thanks !
2 Replies
Oct 30, 2008 3:11 pm
something like this…? Just hook the appropriate script up to the keyboard shortcuts in the Customize UI menu
macroScript modPanelUp category:"modPanel" buttonText:"modUp" (
fn getModPanelIndex = (
modPanel.getModifierIndex $ (modPanel.getCurrentObject())
)
fn setModPanelIndex i = (
modPanel.setCurrentObject $.modifiers[i]
)
fn modPanelIndexUp = (
if (selection.count == 1) then (
numModifiers = $.modifiers.count
if (numModifiers > 0) then (
newIndex = getModPanelIndex() - 1
if (newIndex < 1) then ( newIndex = numModifiers )
setModPanelIndex newIndex
)
)
)
on execute do ( modPanelIndexUp() )
on isEnabled do ( selection.count == 1 )
)
macroScript modPanelDown category:"modPanel" buttonText:"modDown" (
fn getModPanelIndex = (
modPanel.getModifierIndex $ (modPanel.getCurrentObject())
)
fn setModPanelIndex i = (
modPanel.setCurrentObject $.modifiers[i]
)
fn modPanelIndexDown = (
if (selection.count == 1) then (
numModifiers = $.modifiers.count
if (numModifiers > 0) then (
newIndex = getModPanelIndex() + 1
if (newIndex > numModifiers) then ( newIndex = 1 )
setModPanelIndex newIndex
)
)
)
on execute do ( modPanelIndexDown() )
on isEnabled do ( selection.count == 1 )
)
Edit: Note – this doesn’t much like instanced modifiers within the same modifier stack
Oct 30, 2008 3:11 pm
**EDIT :
thanks a lot ZeBoxx2 !!
that´s exactly what i was looking for !
=)