As a heuristic, I would state that if the BG is going full blast out the door - wave bye - bye. If his or her movements toward the door indicate that you are still engaged, that's different
Shooting him does not guarantee an instant stop (except on the Internet). Having been shot and not disabled the BG, rather than fleeing may stay in the fight and kill you or a bystander.
You determine his actions by using your brain and eyes together. I think I can see if someone is running away from me. I grant you that it is a hard skill to pick up just shooting at paper targets.
If one cannot determine if someone has his back to you and running out the door - well, not much can be done about that.