Called right after a state has been completed, but before new state has been selected. StateCompleted is called in reverse order to allow to propagate state to other Tasks that are executed earlier in the tree. Note that StateCompleted is not called if conditional transition changes the state.