![]() |
#1
|
|||
|
|||
Inheritence with node3d
I wanted to create my own object ( a table, a few children nodes connected
to it, and a few children nodes connected to them ), and to extend the functionlaties of my object, whilst keeping all the node3d functions ( such as visible, rotate, etc... ) available. So is it possible to inherit from the node3d class? If so, how do i do it? thanks |
#2
|
|||
|
|||
Sure, the following code show a basic example:
Code:
class MyNode(viz.VizNode): def __init__(self): base = viz.add('model.ive') viz.VizNode.__init__(self,base.id) #Add child self.child = viz.add('ball.wrl',parent=self) mynode = MyNode() mynode.visible(0) |
![]() |
Thread Tools | |
Display Modes | Rate This Thread |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
inheritence question | theuberk | Vizard | 3 | 01-10-2008 07:01 AM |