Hi man , Lets say that you have a function to make the cube go Green.
If you make inside the blueprint of the cube, something like , event hit - call event -begin green.
Only the one you hit will be green.
For make them all go green. you can use the “get all actor of class” and then "cast to " all the cubes and fire the event go green.
This way if you hit one , all began green.