Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 10/20/2018 in Posts

  1. this is the code in the node for everyone interested import c4d def main(): global result # sets a global output variable, cause the xpresso needs it :) result = state # sets the same output to the input state obj = doc.GetFirstObject() # this assigns the first object in the object manager to a variabale named "obj" while obj: # while there is an object returned if obj.GetType() == c4d.Osds: # if the object is a SDS object obj[c4d.ID_BASEOBJECT_GENERATOR_FLAG] = state # toggle it based on the null's object enabled's state obj = walker(obj) # keep checking all the objects in the scene. c4d.EventAdd() def walker(obj): if not obj: return elif obj.GetDown(): return obj.GetDown() while obj.GetUp() and not obj.GetNext(): obj = obj.GetUp() return obj.GetNext()
    1 point
  2. well, if you are Ok with some Python - this a solution. But keep in mind that it will iterate over every object in the scene. It should be quite fast anyway :) sds xpresso python.c4d
    1 point
×
×
  • Create New...