Looked at the add-on, you have TONS of if statements in the damage function, if a lot of people are being damaged at once it can possibly lag the server, unfortunately I do not want to waste a lot of time fixing that but I will look into why
It's not blocking damage because every if statement checks to see if they are 'headshots' - I am not going to spend hours doing repetitive code
OP is also getting console spam because it doesn't check if image slot 1 has an image, it just thinks it always has one.
The code otherwise looks fine to me, just remove your old health system and download the new health system - Could of been the problem for it not blocking damage but I'm not completely sure.
A good practice in the future when you have so many datablocks, putting a variable on your helmet/armor datablocks saying it is either armor or a helmet along with a damage resistance variable. Then in the damage code you just do a few simple checks (also useful if you ever add more helmets and the function won't be slower) and then apply the new damage. This saves A LOT of time in case you messed up on something, especially when every check is using a headshot (?) check.