oops, missed this

This commit is contained in:
Zachary Pavlov 2009-04-17 20:34:41 +00:00
parent 5653b5514b
commit 900c67b409
2 changed files with 9 additions and 7 deletions

View File

@ -3834,7 +3834,7 @@ class Default:
pass
superLogFile = None
def startSuperLog():
def startSuperLog(customFunction = None):
global superLogFile
if(not superLogFile):
@ -3848,8 +3848,11 @@ def startSuperLog():
del vars['__builtins__']
for i in vars:
vars[i] = safeReprTypeOnFail(vars[i])
if(customFunction):
superLogFile.write( "before = %s"%customFunction())
superLogFile.write( "%s(%s):%s:%s\n"%(a.f_code.co_filename.split("\\")[-1],a.f_code.co_firstlineno, a.f_code.co_name, vars))
if(customFunction):
superLogFile.write( "after = %s"%customFunction())
return trace_dispatch
sys.settrace(trace_dispatch)

View File

@ -1540,6 +1540,9 @@ class ShowBase(DirectObject.DirectObject):
self.cTrav.traverse(self.render)
if self.appTrav:
self.appTrav.traverse(self.render)
if self.shadowTrav:
self.shadowTrav.traverse(self.render)
messenger.send("collisionLoopFinished")
return Task.cont
def __audioLoop(self, state):
@ -1603,11 +1606,7 @@ class ShowBase(DirectObject.DirectObject):
# but leave enough room for the app to insert tasks
# between collisionLoop and igLoop
self.taskMgr.add(self.__collisionLoop, 'collisionLoop', priority = 30)
# do the shadowCollisionLoop after the collisionLoop and
# before the igLoop and camera updates (this moves the avatar vertically,
# to his final position for the frame):
self.taskMgr.add(
self.__shadowCollisionLoop, 'shadowCollisionLoop', priority = 44)
# give the igLoop task a reasonably "late" priority,
# so that it will get run after most tasks
self.taskMgr.add(self.__igLoop, 'igLoop', priority = 50)