No one, and I mean no one, enters my house without advance notice. Not only do none of my relatives or associates have a legitimate means of entry (ie me giving them a key), but anyone who would enter without advance notice would be identified long before making it to my bedroom door. If they know me at all, they would have no doubt what action to expect on my part if such an event as you described were to develop. Finding themselves inside my house at night, the best thing they could do for themselves is lay on the ground with their hands out flat in front of them in plain sight, and hope that I am awake enough not to pull the trigger.

As for house lighting, if the power goes off, I have LED lights that would kick on, with enough ambient lighting to ensure I could identify my target.

The "a" scenario would never be a consideration. Anyone coming into my house unannounced would be an invader. If they are standing at my bedroom door, the next thing they will hear/see is the click of the sear releasing and a bright flash.
_________________________
The ultimate result of shielding men from the effects of folly is to fill the world with fools.
-- Herbert Spencer, English Philosopher (1820-1903)