FPS Multiplayer Weapon Switching

Hi,
I’m trying to figure out how to switch weapons in a multiplayer FPS I’m developing. I’ve used a skeletal mesh array to change the gun mesh whenever Q (switch) is pressed, however could easily set it the index to number pressed. However I’m having a little trouble working out how to implement switching code for weapons.
I’m using 4 variables for each gun: FireRate, RecoilRate, Damage and IsAutomatic.

I Can’t however work out how to run this code every time the weapon is swapped, and set it to the values of the new gun. I’ve attempted casting to the current index array (using another index for actor references) however can’t get it to work.

All comments helpful
Thanks

I think this is what you are trying to do. Let me know if it works for you.