Hi man ,
i suppose that you want to store 2 guns in the 2 guns slots and 2 melee in the melee slots , and so on.
You can do it all by Array of enum , you create an enumerator full of all weapons you can have.
then you create an array of that enumerator, naming it SlotMelee.
Sure man , Here i made a wall and a weapon generator, the weapon get a random type from enum.
When the Weapon hit the wall : i get his reference and from there i get his type.
wich his type i Switch to different slots array.
sure if you need only 1 weapon you dont need an array.
I just made the weapon add my array if is empty , or overwrite the old weapon.
but here is a good way to switch N weapon.
you can also have multiple kind of weapon pinned to the same slots !
if you have an Mk23, a Revolver and a DesertEagle type… these are all gun
and all their switch go to the Gun Slot.