There are only three important points to (try) to remember when defending yourself/family from an intruder.
1) are they still in my property- never chase someone down the street then start to "defend yourself" because the threat has left and you followed it and became the attacker.
2) use resonable force- it's something the police and door men have been doing for years. If I find someone going through my kitchen draws and I hit them with a hammer and kill them then am getting done for manslaught. If I hear someone down stairs, call the police and they come up the stairs with a knife and I kill them that is reasonable.
3) never ever hit someone from behind. It will be seen as them running away or u surprised them either way it posed no risk to you.
Note; I don't include defending property. They can have what they like. I am insured and couldn't be doing with the hassle. Also, am sure there are people on here who will know what it's like to live with the feeling of killing someone, justified or not.