From 4624cd0107714d676b2ea6682f4e42a05f705a4c Mon Sep 17 00:00:00 2001 From: Josh Wilson Date: Wed, 19 Sep 2007 00:46:31 +0000 Subject: [PATCH] added 'xform' parameter to report --- direct/src/showbase/PythonUtil.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/direct/src/showbase/PythonUtil.py b/direct/src/showbase/PythonUtil.py index 5495f99fc2..a8f6dc68b2 100644 --- a/direct/src/showbase/PythonUtil.py +++ b/direct/src/showbase/PythonUtil.py @@ -2589,7 +2589,7 @@ class ClassTree: return self._getStr() -def report(types = [], prefix = '', notifyFunc = None, dConfigParam = []): +def report(types = [], prefix = '', xform = None, notifyFunc = None, dConfigParam = []): """ This is a decorator generating function. Use is similar to a @decorator, except you must be sure to call it as a function. @@ -2704,6 +2704,9 @@ def report(types = [], prefix = '', notifyFunc = None, dConfigParam = []): if 'avLocation' in types: outStr = '%s : %s' % (outStr, str(localAvatar.getLocation())) + if xform: + outStr = '%s : %s' % (outStr, xform(args[0])) + if notifyFunc: notifyFunc(outStr) else: