/ Published in: ActionScript 3

Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
private function uint2hex(dec:uint):String { // http://blog.rcq129.com/coding/as3-uint-to-hex/ var digits:String = "0123456789ABCDEF"; var hex:String = ''; while (dec > 0) { var next:uint = dec & 0xF; dec >>= 4; hex = digits.charAt(next) + hex; } if (hex.length == 0) hex = '0' return hex; }
URL: http://blog.rcq129.com/coding/as3-uint-to-hex/
Comments
