2
0
Эх сурвалжийг харах

DistributedNodepathEntities were being destroyed twice

Darren Ranalli 22 жил өмнө
parent
commit
ab9d795781

+ 2 - 6
direct/src/level/BasicEntities.py

@@ -101,7 +101,7 @@ class NodePathEntity(Entity.Entity, NodePath.NodePath, NodePathAttribs):
         node = hidden.attachNewNode('NodePathEntity')
         node = hidden.attachNewNode('NodePathEntity')
         NodePath.NodePath.__init__(self, node)
         NodePath.NodePath.__init__(self, node)
         Entity.Entity.__init__(self, level, entId)
         Entity.Entity.__init__(self, level, entId)
-        NodePathAttribs.initNodePathAttribs(self)
+        self.initNodePathAttribs(self)
 
 
     def destroy(self):
     def destroy(self):
         NodePathAttribs.destroy(self)
         NodePathAttribs.destroy(self)
@@ -120,12 +120,8 @@ class DistributedNodePathEntity(DistributedEntity.DistributedEntity,
 
 
     def announceGenerate(self):
     def announceGenerate(self):
         DistributedEntity.DistributedEntity.announceGenerate(self)
         DistributedEntity.DistributedEntity.announceGenerate(self)
-        NodePathAttribs.initNodePathAttribs(self)
+        self.initNodePathAttribs(self)
         
         
-    def disable(self):
-        NodePathAttribs.destroy(self)
-        DistributedEntity.DistributedEntity.disable(self)
-
     def delete(self):
     def delete(self):
         self.removeNode()
         self.removeNode()
         DistributedEntity.DistributedEntity.delete(self)
         DistributedEntity.DistributedEntity.delete(self)