THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 07/03/2011 at 19:21, xxxxxxxx wrote:
Hi all
I come from China, and I can not find a man who study python for Cinema 4D around me.
so,I guess there is the only place which I can be helped.
I hope you can understand what I said:)
And there is my plugin:
###############################################################
import c4d
from c4d import gui
def main() :
doc.StartUndo()
objList = doc.GetActiveObjects(childs=True)
for obj in objList:
doc.AddUndo(c4d.UNDOTYPE_CHANGE,obj)
obj.SetRelPos(c4d.Vector(0,0,0))
obj.SetRelRot(c4d.Vector(0,0,0))
c4d.EventAdd()
doc.EndUndo()
if __name__=='__main__':
main()
#######################################################################
the plugin let the object back to (0,0,0) #position and rotation
but, I just want add a message window when none object have be selected, and the sys will show the window with some words(just like :"please select a object frist!") to users.
But, I don`t know how to add it !!!:cry:
So, I hope you can help me.