Cobra_Tomtrein-temp-

Untitled

Jul 20th, 2017
74
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.19 KB | None | 0 0
  1. function bit-table(num)
  2. local tab = {}
  3. for i=1,8 do
  4. if (num % 2) == 1 then
  5. tab[i] = 1
  6. num = num - 1
  7. else
  8. tab[i] = 0
  9. end
  10. num = num / 2
  11. end
  12. end
Advertisement
Add Comment
Please, Sign In to add comment