Make animation to play back in correct order and include undone events