|
@@ -2,6 +2,7 @@
|
|
|
|
|
|
|
|
from direct.directnotify import DirectNotifyGlobal
|
|
from direct.directnotify import DirectNotifyGlobal
|
|
|
from direct.showbase.PythonUtil import isDefaultValue
|
|
from direct.showbase.PythonUtil import isDefaultValue
|
|
|
|
|
+import types
|
|
|
|
|
|
|
|
class ParentMgr:
|
|
class ParentMgr:
|
|
|
# This is now used on the AI as well.
|
|
# This is now used on the AI as well.
|
|
@@ -89,6 +90,10 @@ class ParentMgr:
|
|
|
if isDefaultValue(token):
|
|
if isDefaultValue(token):
|
|
|
self.notify.error('parent token (for %s) cannot be a default value (%s)' % (repr(parent), token))
|
|
self.notify.error('parent token (for %s) cannot be a default value (%s)' % (repr(parent), token))
|
|
|
|
|
|
|
|
|
|
+ if type(token) is types.IntType:
|
|
|
|
|
+ if token > 0xFFFFFFFF:
|
|
|
|
|
+ self.notify.error('parent token %s (for %s) is out of uint32 range' % (token, repr(parent)))
|
|
|
|
|
+
|
|
|
self.notify.debug("registering %s as '%s'" % (repr(parent), token))
|
|
self.notify.debug("registering %s as '%s'" % (repr(parent), token))
|
|
|
self.token2nodepath[token] = parent
|
|
self.token2nodepath[token] = parent
|
|
|
|
|
|