The consensus seems to be the best option is to "get out of there" basically. The details involve various ways of doing this. OK, then what's Plan B?
Although it's fashionable to disregard the use of handguns on this site, a handgun here may allow for the most doable option for regular people. At a minimum, a handgun broadens the scope of options tremendously.
Without a gun, I would not consider hunkering down and hiding to be a viable option. With a handgun, hunkering down is an attractive option, considering the alternative of having to become an Olympic sprinter suddenly. I don't know about others, but I can't sprint anymore. I can run as hard as I can, but it can't be objectively classified as a "sprint". Further, nowadays, I'm more often injured with a hamstring pull than I am not. I encourage you to be honest with yourself as well.
If I could situate myself such that there's only one direction from which to shoot me, then I'd feel "comfortable" with the option of hunkering down. Someone above mentioned that I may be waiting for hours. OK, so I hunker down and keep my flashlight handy to be able to identify anybody who invades my new home. I can wait it out in order to save my life.
This all assumes I don't have any kids with me. It's also fair to assume the shooter is playing "bully" and will probably become a meek coward if faced with bullets flying in his direction.
Anyway, that's a rough draft for Plan B. I encourage more experienced people to modify it, provide more details or be inspired to present their own Plan B. Heck, this might even be Plan A.
_________________________
If you're reading this, it's too late.