In order to make weapons with moving parts, you need to assign the vertexes you want too deform, to the appropriate vertex groups in edit mode. EG, the defualt shotgun has 3:
Weapon_bone which is used for the main body, barrels and grip.
Weapon_bone1 which is used for the pump.
Weapon bone2 which is used for the slug during reloading.
And Weapon_bone3 which I think is used the ejection port on the side.
You should see them on your decompiled model, so check that if you're un sure about what goes where, you can check them from the object data tab
.