A function of check all object in the scene with multiple hierarchies.
def GetNextObject(obj):
if obj.GetDown():
obj = obj.GetDown()
return obj
if obj.GetNext():
obj = obj.GetNext()
return obj
while obj.GetUp():
obj = obj.GetUp()
if obj.GetNext():
obj = obj.GetNext()
return obj
return False
Recommended Posts