WoW:USERAPI RGBPercToHex: Difference between revisions

Undo revision 1913541 by Kasper2 (talk)
(use r*255 or r*255+.5)
(Undo revision 1913541 by Kasper2 (talk))
Line 10: Line 10:
  return string.format("%02x%02x%02x", r*255, g*255, b*255)
  return string.format("%02x%02x%02x", r*255, g*255, b*255)
  end
  end
the data i get from GetTextColor() i need to use r*255'''+.5'''  to get the tru result :)
return string.format("%02x%02x%02x", r*255+.5, g*255+.5, b*255+.5)
Anonymous user