                 nextColor = colorRGB([randflt(), randflt(), randflt()])
             }
             rgbColor = thisColor.fadeTo(nextColor, fade:colorFade/100.0)
+
+        case .LIST:
+            colorIndex = (colorIndex + 1) % colorList.count
+            rgbColor = colorList[colorIndex]  
+            
+        case .DIRECTION:
+            let ci = colorInc/100.0
+            var r = Float(rgbColor.red())
+            var g = Float(rgbColor.green())
+            var b = Float(rgbColor.blue())
+            let side:Side = Side(rawValue:nextDir)!
+            switch side
+            {
+            case .UP: b = clamp(b + ci, low:0.0, high:1.0)
+            case .LEFT:
+                r = clamp(r + ci, low:0.0, high:1.0)
+            case .RIGHT:
+                g = clamp(g + ci, low:0.0, high:1.0)
+            case .DOWN:
+                b = clamp(b - ci, low:0.0, high:1.0)
+            case .BACKL:
+                r = clamp(r - ci, low:0.0, high:1.0)
+            case .BACKR:
+                g = clamp(g - ci, low:0.0, high:1.0)
+            default: break
+            }
+            rgbColor = colorRGB([r,g,b])
         }
     }
         

    
    func chooseNextColor()
    {
        var colorType = ColorFade.RANDOM
        switch colorType
        {
        case .RANDOM:


    var colorFade:Float = 0
    var colorInc:Float  = 0
    var colorIndex:Int = 0
    var colorList:[NSColor] = [
        NSColor(red:0, green:0, blue:0, alpha: 1),
        NSColor(red:1, green:0, blue:0, alpha: 1),
        NSColor(red:0.2, green:0.2, blue:0.2, alpha: 1),
        NSColor(red:1, green:0.5, blue:0, alpha: 1),
        NSColor(red:0.2, green:0.2, blue:0.2, alpha: 1),
    ]
    
    var thisColor  = NSColor(red:0, green:0, blue:0, alpha: 1)
    var nextColor  = NSColor(red:0, green:0, blue:0, alpha: 1)
