Browse Source

cleaned up nodepath

Joe Shochet 21 years ago
parent
commit
68f5888be4
1 changed files with 2 additions and 0 deletions
  1. 2 0
      direct/src/distributed/DistributedNodeAI.py

+ 2 - 0
direct/src/distributed/DistributedNodeAI.py

@@ -10,6 +10,8 @@ class DistributedNodeAI(DistributedObjectAI.DistributedObjectAI, NodePath):
         NodePath.__init__(self, hidden.attachNewNode(name))
 
     def delete(self):
+        if not self.isEmpty():
+            self.removeNode()
         DistributedObjectAI.DistributedObjectAI.delete(self)
 
     ### setParent ###