This post has been marked by the post author as the answer.
yes with some scripts
weapon_restrict.lua should be assigned to always active object (stops player from swapping to slots 3 ~ 9 with number pad / scroll wheel)
weapon.lua should replace your original (modified to only allow swapping if you're carrying 2 weapons already)
p.s. i didn't modify the code for playing with a controller, you can add that yourself if you need it as i'm not actually seeing where the input for that is located in the script
p.p.s don't forget any updates or verification will restore weapon.lua so it might be worth renaming the script but you will need to manually assign the script to each weapon you place, i was being lazy