Make a string | spline component map. But since you’re using an int, it could be easier to put the splines in an array and get one at index.
Is it possible from a function to call these variables dynamically with a String ?
I bet a better question here is why? You may have your reason but there may be a better way of achieving the end goal than associating a component with a string - which is somewhat awkward at best.