I guess a way to do this is to add them as legit components to the component hierarchy.
So in my parent class, Generic Tank, I have everything defined and my components contain virtual functions. So in a derived class, say Medium Tank, I want to call the Fire function from whatever type of Gun Mod my Gun Mod variable in referencing. In this case, I have Cannon that is of type Gun Mod that overrides Gun Mod’s Fire function. So if the Medium Tank want to equip a Cannon as its Gun Mod, it sets the Gun Mod to a new type of Cannon with the overridden Fire function that does a different thing form the other Gun Mods that use Fire.
I suppose I could just type cast, but I’m looking for a less hard-coded solution. When players go to customize their loadout, the Gun Mod variable needs to be able to change to whatever other type of Gun Mod the player chooses.