Announcement

Collapse
No announcement yet.

Mel script to check if shape has attributes

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Mel script to check if shape has attributes

    Hello,

    I'm trying to get if a mesh has attributes but this command always return "0" even though the attribute exist :s

    if (`attributeExists "vray_displacement" $objs`)

    Any help would be great. Thank you!

    Jacques.

  • #2
    Hello!
    You have most probably mistaken the attribute name. Before using "attributeExists", you can first try the MEL command "listAttr" to get all attributes for the node or "listAttr -userDefined" to filter only dynamic attributes which Extra V-Ray attributes usually seem to be.
    Iliyana Vladeva
    Software Development Engineer
    V-Ray for Maya

    Comment


    • #3
      Thank you very much for the quick reply Iliyana!

      It now works just fine... I thought "attributeExists" would return any "vray addAttributesFromGroup" name/value.

      Jacques.

      Comment

      Working...
      X