tags:

views:

43

answers:

2
SDL_Color normColor = {255,255,255};
SDL_Color redColor = {255,0,0};
SDL_Color blackColor = { 0,0,0 };

etc.

What kind of array do I need to do something like:

typeofarray mycolorArray[95] = {normColor, redColor, blackColor..............};
....
mycolorArray[65] = redColor // to change the color
+1  A: 
SDL_Color sdlColors[] = {normColor, redColor, blackColor..............};
Steven
Thank you sir. :)
jack moore
A: 

How about instead of arrays, you use enum instead?

Color enum

or Class based example with enum.

0A0D