Hi @ferdinand , I get it ! Thanks again to your reply!
Best posts made by gheyret
Latest posts made by gheyret
@ferdinand
I mean i Get the Object Data using BaseList2D.GetData()
and SetData
to another object, it's only change the parameter of "Object" Tab in Attributes Manager.
Hera is a exmaple:
from typing import Optional
import c4d
doc: c4d.documents.BaseDocument # The active document
op: Optional[c4d.BaseObject] # The active object, None if unselected
def main() -> None:
new = doc.GetFirstObject()
old = new.GetNext()
old.SetData(new.GetData())
c4d.EventAdd()
if __name__ == '__main__':
main()
Before run the script
After run the script
As you can see, the object name, visibilitys and display color is not changed by SetData
Hi @ferdinand , thanks to your reply.
There is another quession; the basic property (like Name, Viewport visibility, Enabled, e.t.c) of object is not in the data container? I mean the c4d.BaseContainer
returned by c4d.BaseList2D.GetData()
@dunhou
Cool man ! That's what i want !
I actually thought about traverse everything in the scene, but I felt it would be a waste. for example, if there were a lot of objects in the scene, so I think if there was another way to do that. But based on your post, that's the only way to do.
Anyway , thank you and @ferdinand
Cheers~
Hi plugincafe~
I want to get the object newly added in to current scene in my Dialog plugin and update something in my dialog.
For example:
Add something in the scene(like a null object), how do i get this object? and how to get this Message?
I find c4d.EVMSG_CHANGE
in SDK and i can get some document changed message in CoreMessage
. But I don't know what to do next.
@manuel
Cool ! Thank you ~
Hi everyone~
How did i create and get redshift light groups with python ?
Hello everyone~
I have a GeDialog
window now. and i want to close it when my mouse click in anywhare.
I can get the mouse click event in GeDialog.Message()
, but it's just work inside of dialog.
So i think maybe i need to get the global input event . But i can't find any method in SDK.
How do i do that?