|
@@ -79,6 +79,13 @@ class Actor(DirectObject, NodePath):
|
|
|
def makeCopy(self):
|
|
def makeCopy(self):
|
|
|
return Actor.SubpartDef(self.truePartName, PartSubset(self.subset))
|
|
return Actor.SubpartDef(self.truePartName, PartSubset(self.subset))
|
|
|
|
|
|
|
|
|
|
+ def __getitem__(self,index):
|
|
|
|
|
+ if(index==0):
|
|
|
|
|
+ return self.truePartName
|
|
|
|
|
+ else:
|
|
|
|
|
+ return None
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
def __repr__(self):
|
|
def __repr__(self):
|
|
|
return 'Actor.SubpartDef(%s, %s)' % (repr(self.truePartName), repr(self.subset))
|
|
return 'Actor.SubpartDef(%s, %s)' % (repr(self.truePartName), repr(self.subset))
|
|
|
|
|
|
|
@@ -938,7 +945,7 @@ class Actor(DirectObject, NodePath):
|
|
|
|
|
|
|
|
truePartName = self.__subpartDict.get(partName, [partName])[0]
|
|
truePartName = self.__subpartDict.get(partName, [partName])[0]
|
|
|
partDef = partBundleDict.get(truePartName)
|
|
partDef = partBundleDict.get(truePartName)
|
|
|
- if part:
|
|
|
|
|
|
|
+ if partDef:
|
|
|
bundle = partDef.partBundle.node().getBundle()
|
|
bundle = partDef.partBundle.node().getBundle()
|
|
|
else:
|
|
else:
|
|
|
Actor.notify.warning("no part named %s!" % (partName))
|
|
Actor.notify.warning("no part named %s!" % (partName))
|