Need help with coding: RPG weapons damage

This game does not have to be multiplayer, but it would be nice if the codes were compatible for that.
My the first problem I am facing is how to create a script where all the weapons have set stats such as damage. Then how would I create a script where when an mob collides with that weapon it takes damage according to the weapon’s stats? any ideas?