Your browser does not seem to support JavaScript. As a result, your viewing experience will be diminished, and you have been placed in read-only mode.
Please download a browser that supports JavaScript, or enable it if it's disabled (i.e. NoScript).
On 13/11/2014 at 02:21, xxxxxxxx wrote:
Hello _<_t_>_ English »
|
<_<_t_>_ Options : History : Help : Feedback Text-to-speech function is limited to 100 characters
I want to create xpresso structure with connections via python script. Basic ports are created without problems, but the problem occurs when i create port with User Data - node stops working, and title bar painted yellow. If create port manually - all works.
This code create node and port: [
](http://www.html.by/misc.php?do=bbcode#CODE) XP=c4d.BaseTag(c4d.Texpresso) obj.InsertTag(XP) Node_M=XP.GetNodeMaster() Base_Node=Node_M.CreateNode(Node_M.GetRoot(), c4d.ID_OPERATOR_OBJECT, None, 0, 0) Base_Node.AddPort(c4d.GV_PORT_OUTPUT, [c4d.ID_USERDATA,1] ,c4d.GV_PORT_FLAG_IS_VISIBLE,True)[
](http://www.html.by/misc.php?do=bbcode#CODE)
#Sorry for my english.
On 14/11/2014 at 01:28, xxxxxxxx wrote:
Hello,
To create ports for userdata parameters you have to create the DescID of that parameter.
USERDATA_NUMERO = 1 #change this nodeObjOut.AddPort(c4d.GV_PORT_OUTPUT, c4d.DescID(c4d.DescLevel(c4d.ID_USERDATA, c4d.DTYPE_SUBCONTAINER, 0), c4d.DescLevel(USERDATA_NUMERO)), message=True)
This example is taken from this thread describing the solution.
best wishes, Sebastian
On 16/11/2014 at 02:06, xxxxxxxx wrote:
Thank you very much!
On 16/11/2014 at 03:46, xxxxxxxx wrote:
And another question. I created this node manually(pic1)
But i want create this node via Python script, how can i make it? Any ideas?
_<_t_>_ English »
On 17/11/2014 at 01:54, xxxxxxxx wrote:
do you want to edit the reference parameter of the given node? Just use SetParameter() to link a given object. The list of parameters of the object node can be found on the C++ documentation.
baseNode.SetParameter(c4d.GV_OBJECT_OBJECT_ID,linkedObject,c4d.DESCFLAGS_SET_0)
Best wishes, Sebastian
On 24/11/2014 at 06:52, xxxxxxxx wrote:
Thanks, it works. _<_t_>_ English »
<_<_t_>_ Options : History : Help : Feedback Text-to-speech function is limited to 100 characters But it is for R16, what about the older versions?
On 24/11/2014 at 09:24, xxxxxxxx wrote:
in this case just use
baseNode[c4d.GV_OBJECT_OBJECT_ID] = linkedObject