If your gun is not on you, it is of little purpose unless your home invader team rings the bell, or otherwise alerts you before crashing through the door or window.
I have several friends who hide guns throughout their homes, but they have not been involved in a home invasion. Having been involved in one you should know that you only have time to draw and fire.
Having guns laying around is not a good idea. If you live alone it is ok, but won't really accomplish your desired result. I leave one gun for my wife when I leave, as she won't carry, so it goes in a spot that is just a shelf hidden by another shelf, "slim" so as not visible. Otherwise they all go in the safe except the one I am carrying. Sometimes I wonder if some of our members are single that have these ideas about leaving weapons all over the house. You are bound to have a mishap unless you just never have people over for dinner or guests who stay for a few days . Having 4 young grandkids,"under 9 yrs old" , doesn't allow for leaving loaded guns around. At bedtime your gun should be in a holster on the side of your bed. That's where it's going to do the most good. Unless you can get your gun in a second or less it's too long. Lock the bedroom door if you have little ones. That way you have 2 doors to enter and your alarm and dog should have woken you up by then. Use the "chime" feature on your alarm system, "they all have it in the last 20 years" so if a window opens you can hear it. I would not consider a safe for my go to gun, it is just one more step to overcome, before being able to defend yourself. Your heart and brain will be running so fast that even the simplest task becomes difficult. Last thing you need is a sticky lock.There is also a foil that we have mentioned before for the windows, I know 3m makes one. It makes it very hard to break them with a bat or pipe. It won't happen with one shot, if you are on the ground floor, you may want to look into it. I have a second gun most times on my person, so at night I have 2 guns available within arms length in the dark. Also a strobe flash with 250 lumens, and a jewelry box with assorted mags for every handgun caliber I may have at my disposal. That's what works for me, your milage may vary.