How would i go about getting the color from the ColorMixer

I need to add alot of color mixers to my derma menu (Making a settings menu where you can change the colors of my hud)

[LUA]
function CreateMixer( Parent, x, y, width, height, defaultColor )
local mixer = vgui.Create( “DColorMixer”)
mixer:SetParent( Parent )
mixer:SetPos(x,y)
mixer:SetSize( width, height )
mixer:SetColor( defaultColor )
end
[/LUA]

How would i go about getting the color selected by the user, then passing it into a value. Keep in mind i need alot of these so they need seperate 'id’s I’m really lost on this, could really use some help. (I could just make them individually but it’s gonna use up a ton of lines)

How would i give each mixer an ID? There is no way of me using GetColor() on this, because i have nothing to target it with…

return the mixer from CreateMixer and save it in some variable once you called the function.

What if i create more than 1 with the CreateMixer() function? Wouldn’t i have to make new variables each time? Could you maybe give an example?

You could have an array of mixers, just create them in a for loop or whatever.

NVM, i got two things mixed up in my head. Fixed it.