Explorar el Código

state methods are allowed to be None

Joe Shochet hace 22 años
padre
commit
564bb18332
Se han modificado 1 ficheros con 3 adiciones y 0 borrados
  1. 3 0
      direct/src/fsm/State.py

+ 3 - 0
direct/src/fsm/State.py

@@ -109,6 +109,9 @@ class State(DirectObject):
     def redefineFunc(self, oldMethod, newMethod, map):
         if not FsmRedefine:
             return
+        # Methods are allowed to be None
+        if oldMethod is None:
+            return
         if map.has_key(oldMethod):
             # Get the list of states for the old function
             stateList = map[oldMethod]