TheAMM

0x40 Hues Colours

Jun 16th, 2014
247
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. const colorNames : Array = [ "black", "brick", "crimson", "red", "turtle", "sludge", "brown", "orange", "green", "grass", "maize",
  2.                  "citrus", "lime", "leaf", "chartreuse", "yellow", "midnight", "plum", "pomegranate", "rose", "swamp", "dust",
  3.                  "dirt", "blossom", "sea", "ill", "haze", "peach", "spring", "mantis", "brilliant", "canary", "navy",
  4.                  "grape", "mauve", "purple", "cornflower", "deep", "lilac", "lavender", "aqua", "steel", "grey", "pink",
  5.                  "bay", "marina", "tornado", "saltine", "blue", "twilight", "orchid", "magenta", "azure", "liberty", "royalty",
  6.                  "thistle", "ocean", "sky", "periwinkle", "carnation", "cyan", "turquoise", "powder", "white"
  7.                ];
  8.        
  9. function setColor(colIndex : Number) {
  10.     var cx =     colIndex % 4;
  11.     var cy = int(colIndex / 4) % 4;
  12.     var cz = int(colIndex / 16);
  13.     // The color as an interger
  14.     var hc = (0x000000 + 0x550000 * cx + 0x005500 * cy + 0x000055 * cz);
  15.     // Snipped: the actual color usage
  16. }
  17. const oldColors : Array = [ {n:"black", c:0x0},
  18.             {n:"brick", c:0x550000},
  19.             {n:"crimson", c:0xaa0000},
  20.             {n:"red", c:0xff0000},
  21.             {n:"turtle", c:0x5500},
  22.             {n:"sludge", c:0x555500},
  23.             {n:"brown", c:0xaa5500},
  24.             {n:"orange", c:0xff5500},
  25.             {n:"green", c:0xaa00},
  26.             {n:"grass", c:0x55aa00},
  27.             {n:"maize", c:0xaaaa00},
  28.             {n:"citrus", c:0xffaa00},
  29.             {n:"lime", c:0xff00},
  30.             {n:"leaf", c:0x55ff00},
  31.             {n:"chartreuse", c:0xaaff00},
  32.             {n:"yellow", c:0xffff00},
  33.             {n:"midnight", c:0x55},
  34.             {n:"plum", c:0x550055},
  35.             {n:"pomegranate", c:0xaa0055},
  36.             {n:"rose", c:0xff0055},
  37.             {n:"swamp", c:0x5555},
  38.             {n:"dust", c:0x555555},
  39.             {n:"dirt", c:0xaa5555},
  40.             {n:"blossom", c:0xff5555},
  41.             {n:"sea", c:0xaa55},
  42.             {n:"ill", c:0x55aa55},
  43.             {n:"haze", c:0xaaaa55},
  44.             {n:"peach", c:0xffaa55},
  45.             {n:"spring", c:0xff55},
  46.             {n:"mantis", c:0x55ff55},
  47.             {n:"brilliant", c:0xaaff55},
  48.             {n:"canary", c:0xffff55},
  49.             {n:"navy", c:0xaa},
  50.             {n:"grape", c:0x5500aa},
  51.             {n:"mauve", c:0xaa00aa},
  52.             {n:"purple", c:0xff00aa},
  53.             {n:"cornflower", c:0x55aa},
  54.             {n:"deep", c:0x5555aa},
  55.             {n:"lilac", c:0xaa55aa},
  56.             {n:"lavender", c:0xff55aa},
  57.             {n:"aqua", c:0xaaaa},
  58.             {n:"steel", c:0x55aaaa},
  59.             {n:"grey", c:0xaaaaaa},
  60.             {n:"pink", c:0xffaaaa},
  61.             {n:"bay", c:0xffaa},
  62.             {n:"marina", c:0x55ffaa},
  63.             {n:"tornado", c:0xaaffaa},
  64.             {n:"saltine", c:0xffffaa},
  65.             {n:"blue", c:0xff},
  66.             {n:"twilight", c:0x5500ff},
  67.             {n:"orchid", c:0xaa00ff},
  68.             {n:"magenta", c:0xff00ff},
  69.             {n:"azure", c:0x55ff},
  70.             {n:"liberty", c:0x5555ff},
  71.             {n:"royalty", c:0xaa55ff},
  72.             {n:"thistle", c:0xff55ff},
  73.             {n:"ocean", c:0xaaff},
  74.             {n:"sky", c:0x55aaff},
  75.             {n:"periwinkle", c:0xaaaaff},
  76.             {n:"carnation", c:0xffaaff},
  77.             {n:"cyan", c:0xffff},
  78.             {n:"turquoise", c:0x55ffff},
  79.             {n:"powder", c:0xaaffff},
  80.             {n:"white", c:0xffffff}
  81.           ]
Advertisement
Add Comment
Please, Sign In to add comment