Browse Source

Fix obscure error caused by bug in _getDtoolSuperBase

rdb 10 years ago
parent
commit
500da29013
1 changed files with 4 additions and 3 deletions
  1. 4 3
      direct/src/showbase/PythonUtil.py

+ 4 - 3
direct/src/showbase/PythonUtil.py

@@ -1429,11 +1429,12 @@ dtoolSuperBase = None
 
 def _getDtoolSuperBase():
     global dtoolSuperBase
-    from panda3d.core import PandaNode
-    dtoolSuperBase = PandaNode('').__class__.__bases__[0].__bases__[0].__bases__[0]
+    from panda3d.core import TypedObject
+    dtoolSuperBase = TypedObject.__bases__[0]
     assert repr(dtoolSuperBase) == "<type 'libdtoolconfig.DTOOL_SUPER_BASE111'>" \
         or repr(dtoolSuperBase) == "<type 'libdtoolconfig.DTOOL_SUPPER_BASE111'>" \
-        or repr(dtoolSuperBase) == "<type 'dtoolconfig.DTOOL_SUPER_BASE111'>"
+        or repr(dtoolSuperBase) == "<type 'dtoolconfig.DTOOL_SUPER_BASE111'>" \
+        or repr(dtoolSuperBase) == "<type 'dtoolconfig.DTOOL_SUPER_BASE'>"
 
 safeReprNotify = None