This commit makes those item scripts a little more readable and decreases the chance of mistakenly using an incorrect weapon type id. Follow up to c6187fa.