Code / mIRC / Function: $Hex2RGB()

  1. ; $hex2rgb(HEX) - Converts a Hexadecimal color to an RGB color
  2. ; Written by sc0tt, Questions/Comments to sc0tt@unlagged.org
  3. ; Usage $hex2rgb(FFFFFF);
  4.  
  5. alias">alias hex2rgb {
  6.   ; coded from the idea of zack^
  7.   ; example usage: $hex2rgb(FFFFFF)
  8.   if ($1) {
  9.     return $rgb($base($mid($1,1,2),16,10),$base($mid($1,3,2),16,10),$base($mid($1,5,2),16,10))
  10.   }
  11. }

Download as Text : January 6th, 2009