Parcourir la source

transformations no longer crash when stepping through them

Simon Van Mierlo il y a 9 ans
Parent
commit
e9de86f3d5
1 fichiers modifiés avec 2 ajouts et 0 suppressions
  1. 2 0
      mt/ptcal/ptcal.py

+ 2 - 0
mt/ptcal/ptcal.py

@@ -988,6 +988,8 @@ class PyTCoreAbstractionLayer :
         NOTE: this function assumes that feedback for the last step has already
                 been received '''
     def step(self) :
+        if not hasattr(self, 'start_time'):         
+            self.start_time = clock()
         if self._execmode == 'PLAY' :
             pass
         else :