It looks like you're new here. If you want to get involved, click one of these buttons!
theNumber="11" --Binary 11 = 3 print(tonumber(theNumber,2)) --Octal 011 = 9 print(tonumber(theNumber,8)) --Decimal 11 = 11 --Hex 0x11 = 17 print(tonumber(theNumber,16)) |
Dislikes: keszegh
Comments
Website: http://www.castlegateinteractive.com
https://play.google.com/store/apps/developer?id=Castlegate+Interactive
)
Likes: WauloK
#MakeABetterGame! "Never give up, Never NEVER give up!" - Winston Churchill
to Call it: DecToBase(number,base) so if you want a Binary output, place 2 in the base, hex, place 15 etc. I needed 4, as I am doing a Algorythm to validate 4 slots of 4 possibilities, and need to count on each column. Would be nice if this could be added to Compiled function list....
---------------------------------------