I ended up not casting and just used arrays to get this done. It’s not the most optimized way but it works for me.
I saved the material slot names and material assignments from the Geometry Cache asset in two separate arrays. Then the selected materials name would query through all the elements of the array to find and replace with the new materials.
I kept the material slot names because if I wanted to reset the material assignments, it wouldn’t be a pain.
Hope this helps!