¡Robbers in my house!

I go to explore the roads and when i come back to my shelter (a gun store) i find that a few NPC has been taking my things. I put my heavy power suit and killed them whit my crossbow. But for that i have a moral debuff.

How i can make my home safer? Can i put something like a key or something like that?

No keys or locks available in game yet. You could build a palisade gate in front of the door, NPC’s can’t operate them. Alternatively, you could boobytrap the entrance. I’m partial to landmines myself.

You can use Zone Management by hitting capital Y key and try putting down a No NPC Pickup zone in your base.
This works for allied NPCs but I don’t know if it also prevents random dudes from robbing you, worth a shot though.

Zone control works for allied NPC’s only.

If I was going to stay around Board up all the doors/windows/block with bookcases except 1 door.
Outside that door/window leave 1 good solid block of ground.

After that dig 2 deep hole on all sides. Add spikes (optional). This way you can fight on it.

How do you get across. 2x4’s. With them on the tile (the open one) or inventory you can drop them to walk across. Just remember to pick them up and put them someplace else.

NPC’s aren’t smart enough to do that.