Hi!
Is it possible to change label text for some specific parameters when selecting different menu items?
For example I have an Ordered Menu parameter which contains 2 items in it: ‘squares’ and ‘voronoi’.
I've placed 2 floats below this menu and I want their labels to be changed depending on selected menu parameter item.
When ‘squares’ are selected, the labels should contain ‘size X’ and ‘size Y’ text;
And when ‘voronoi’ are selected, the labels should contain ‘density’ and ‘height’ text.
I've attached some images as example. So is it possible to make some sort of script to change those labels on the fly, especially when using in UE4 or Unity as a Digital Asset.
Thanks!
P.S. sorry, my bad. Posted in the wrong section, Should've posted in “Houdini Indie and Apprentice ”
Changing label names when ordered menu item selection changes
3969 3 2- Ivan_Titov
- Member
- 7 posts
- Joined: March 2017
- Offline
- dedeks2999
- Member
- 85 posts
- Joined: May 2011
- Offline
- Ivan_Titov
- Member
- 7 posts
- Joined: March 2017
- Offline
Thanks for the advice.
I've learned some python scripting and made a simple script in DA scripts section that runs when menu item selection changes:
It works fine in houdini, but it doesn't works in Unreal Engine.
It could be a dumb question, but does python scripts works in digital assets outside Houdini, when using in Unreal Engine or Unity?
Thanks!
Upd. uh, just forgot to press “recook asset”. It's good now
I've learned some python scripting and made a simple script in DA scripts section that runs when menu item selection changes:
def onListSelectEx(me, parm): if parm.eval() == "squares": me.parm("sizeX").hide(True) me.parm("sizeY").hide(True) me.parm("density").hide(False) me.parm("height").hide(False) else: me.parm("sizeX").hide(False) me.parm("sizeY").hide(False) me.parm("density").hide(True) me.parm("height").hide(True)
It could be a dumb question, but does python scripts works in digital assets outside Houdini, when using in Unreal Engine or Unity?
Thanks!
Upd. uh, just forgot to press “recook asset”. It's good now
Edited by Ivan_Titov - March 17, 2017 08:46:07
- Ivan_Titov
- Member
- 7 posts
- Joined: March 2017
- Offline
-
- Quick Links