I have many methods similar to this:
void GetColorSky(out float r, out float g, out float b)
void GetColorGround(out float r, out float g, out float b)
"Similar" meaning they have the exact same method header excluding the method name. I also have several "colourPicker" controls, that accept R, G, B values.
I am trying to create a method that accepts a method as one of it's parameters, like so:
UpdateColourPicker(ColorPicker cp, CustomMethod cMethod)
and call it as follows:
UpdateColourPicker(cpSky, GetColorSky)
UpdateColourPicker(cpGround, GetColorGround)
What is the correct syntax for out
and Action
together?
I've looked at this question but I still haven't managed.
Thanks!