Hi!
I'm making a simple asset and the only thing I need to expose is a group so the user can do a primitive selection. At the moment, when I click on the exposed group “pick” button, I get an error message:
'NoneType' object has no attribute ‘eval’
Asset creation: expose group?
895 1 1- olivierth
- Member
- 1004 posts
- Joined: April 2017
- Offline
- krueger
- Member
- 191 posts
- Joined: Oct. 2018
- Offline
If you look at the group parameter on your asset in the Action Button tab, it probably has something like this in there:
If it does, then the soputils selectGroupParm function is expecting the 2 parms ‘grouptype’ and ‘ordered’, but you don't have them on your asset. You could either modify that python code to point to the group node inside your asset, or simply expose those parms on your asset too but make them invisible if you don't want people messing with them.
import soputils kwargs['geometrytype'] = kwargs['node'].parmTuple('grouptype') kwargs['inputindex'] = 0 kwargs['ordered'] = kwargs['node'].parm('ordered').eval() soputils.selectGroupParm(kwargs)
If it does, then the soputils selectGroupParm function is expecting the 2 parms ‘grouptype’ and ‘ordered’, but you don't have them on your asset. You could either modify that python code to point to the group node inside your asset, or simply expose those parms on your asset too but make them invisible if you don't want people messing with them.
Edited by krueger - Nov. 19, 2020 21:18:05
-
- Quick Links