Color Patterns

How can I create a pattern to cycle through a specific set of colors. I wrote code that manually forces the colors to change, but want to have this pattern added to a loop and the way i have it the time is not working properly

void C9_Colors(){

leds[0] = CRGB::White;
leds[1] = CRGB::Red;
leds[2] = CRGB::Green;
leds[3] = CRGB(255,40,0);
leds[4] = CRGB::Blue;
leds[5] = CRGB(255,150,0);

I want to set all LEDs to cycle these 6 colors but i want every 6th LED a specific color so it keeps this color pattern through 200 LEDs, not all 200 LEDs red, then white, then green as an example. but LED 0 is white, LED 6 is white and so on. then after say 600ms LED 0 becomes Red and LED 6 is also Red and so on through the pattern and then start over in a loop

Similar problem:

//WalkingMarkeeVer2
#include <Adafruit_NeoPixel.h>

#define wait 500         //viewing time

bool allowWalking = true; //true  >>>---> allows the colors to walk
//                          false >>>---> stationary

#define ledCount 200       //total number of LEDs
#define PIN 6             //output pin to the LED strip
#define LEDsPerBoard 6    //number of LEDs on a PCB 

int offset  = 0;          //offset or index into colourArray[]

unsigned long colourArray[] =  //colour code sequence
{
  //example 1:
  //red       green     blue      pink      yellow    white     cyan      orange     black
  //0xFF0000, 0x00FF00, 0x0000FF, 0xFF00FF, 0xFF7F00, 0xFFFFFF, 0x00FFFF, 0xFF3000,  0x000000

  //example 2:
  //red       green     blue      white
  //0xFF0000, 0x00FF00, 0x0000FF, 0xFFFFFF

  //example 3:
  //red     red       green     green     blue      blue      pink      pink      white     white
  //0xFF0000, 0xFF0000, 0x00FF00, 0x00FF00, 0x0000FF, 0x0000FF, 0xFF00FF, 0xFF00FF, 0xFFFFFF, 0xFFFFFF

  //example 4:
  //red       green     blue      pink      yellow    white
  0x3F0000, 0x003F00, 0x00003F, 0x3F003F, 0x3F3F00, 0x3F3F3F    //dimmer

  //example 5:
  //red       green     blue      pink      yellow    white
  //0xFF0000, 0x00FF00, 0x0000FF, 0xFF00FF, 0xFF9F00, 0xFFFFFF  //bright

  //example 6:
  //red       green     blue     
  //0xFF0000, 0x00FF00, 0x0000FF //bright

  //example 7:
  //red       green     blue     
  //0x3F0000, 0x003F00, 0x00003F //dimmer
};

//how many colours do we have
const byte availableColors = sizeof(colourArray) / sizeof(unsigned long);

Adafruit_NeoPixel strip = Adafruit_NeoPixel(ledCount, PIN, NEO_GRB + NEO_KHZ800);

//***********************************************************************************
void setup()
{
  strip.begin();
  strip.show();   // Initialize all pixels to 'off'

}// END of setup()

//***********************************************************************************
void loop()
{
  //cycle through all the colours
  for (byte colourSelect = 0; colourSelect < availableColors; colourSelect++)
  {
    //fill the pixel array memory
    for (byte ledNumber = 0; ledNumber < ledCount; ledNumber++)
    {
      strip.setPixelColor(ledNumber, colourArray[offset]);

      //the next index/offset into colourArray[]
      offset++;
      offset = offset % availableColors;
      
    }// END of for()

    //send the pixel array memory to the LEDs
    strip.show();

    //give some time to view the strip
    delay(wait);

    //*********************
    //move to the next item in colourArray[]
    if (allowWalking == true)
    {
      offset = colourSelect;
    }
    //*********************
    
  }// END of for()
  
}// END of loop()

//***********************************************************************************

You have a similar problem? or yours is working but is a similar example? I don't have NEO pixels to run yours to test

The example given does work, it may give you some ideas to solve your problem.

We need to see 'your code', schematic and a good photo of your wiring.

Always show us your ‘current’ compete sketch.
Use CTRL T to format the sketch.
Please use code tags.
Use the </> icon in the posting menu.

[code] Paste sketch here. [/code]