[Bf-python] Error when running nodes.new() in currrent SVN

INTERLICHTSPIELHAUS interlichtspielhaus at gmail.com
Sat Apr 27 06:51:46 CEST 2013


this should set you on you way

http://wiki.blender.org/index.php/User:Phonybone/Python_Nodes/API_changes

regards
inS
 On Apr 27, 2013 2:46 AM, "Peter D. Cassetta" <peter at fingertipsoft.com>
wrote:

> Hi all,
>
> I am encountering an error when adding new nodes to a material's node
> tree (via Python).
>
> I know there have been some API changes recently; I just rebuilt Blender
> from SVN yesterday.
> Here is the code I am running and the error I am getting.
>
> >>> C.object.active_material.node_tree.nodes.new('MIX_SHADER')
> Traceback (most recent call last):
>    File "/opt/blender-svn/2.66/python/lib/python3.3/code.py", line 90, in
> runcode
>      exec(code, self.locals)
>    File "<blender_console>", line 1, in <module>
> RuntimeError: Error: Node type MIX_SHADER undefined
>
>
> Is nodes.new() deprecated, or just broken at the moment?
> I am getting this error for any node type, by the way.
>
> Also, do I need to change my code to fix this, or just wait a bit?
> Thanks for any assistance!
>
> -Peter Cassetta
> _______________________________________________
> Bf-python mailing list
> Bf-python at blender.org
> http://lists.blender.org/mailman/listinfo/bf-python
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.blender.org/pipermail/bf-python/attachments/20130427/e2ae9180/attachment.html>


More information about the Bf-python mailing list