I'm looking for the function to toggle an object's "By Object"/"By Layer" property in Display Properties, specifically to "By Object". I haven't been able to get any of the functions here http://help.autodesk.com/view/3DSMAX/2015/ENU/?guid=__files_GUID_78B79975_7BA5_4A03_8FEF_27E78D14B575_htm to do what I want.
Thanks in advance!
Or you can use next one for selection
mapped fn Display_ByObject_ByLayer nodes state: =
(
if isValidNode nodes do node.displaybylayer = state
)
--now you can test it
if selection.count > 0 do Display_ByObject_ByLayer (selection as array) state:off