mirror of
https://github.com/panda3d/panda3d.git
synced 2025-10-17 12:12:10 -04:00
fixed getObjectsOfClassInZone and getDoIdList
This commit is contained in:
parent
9a9149ed9e
commit
2fc6cc3367
@ -122,9 +122,10 @@ class DoCollectionManager:
|
||||
r = parent.get(zoneId, [])
|
||||
if classType is not None:
|
||||
a = []
|
||||
for obj in r:
|
||||
for doId in r:
|
||||
obj = self.getDo(doId)
|
||||
if isinstance(obj, classType):
|
||||
a.append(obj)
|
||||
a.append(doId)
|
||||
r = a
|
||||
return r
|
||||
|
||||
@ -384,6 +385,5 @@ class DoCollectionManager:
|
||||
assert self.notify.debugStateCall(self)
|
||||
doDict = {}
|
||||
for doId in self.getDoIdList(parentId, zoneId, objClass):
|
||||
if isinstance(do, objClass):
|
||||
doDict[doId] = self.doId2do.get(do)
|
||||
doDict[doId] = self.getDo(doId)
|
||||
return doDict
|
||||
|
Loading…
x
Reference in New Issue
Block a user