How to automatically assign OnHover and OnClick events with different parameters?

I have 15 UMG buttons in an array that trigger 15 corresponding animations then go to their respective level. Basically, 15 buttons calling the same function with different paramenters.

I was trying to use a for loop to automate this task, but the parameters will be overwritten during the loop, so all buttons will always call the function with the last parameters passed.

How can I automate this task and get functions that know which button called them?