ame824

Bundlecable

Apr 2nd, 2017
74
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 1.46 KB | None | 0 0
  1. f = 0
  2.  
  3.  
  4. function c(c)
  5.     if c == "blue" then return colors.blue end
  6.     if c == "white" then return colors.white end
  7.     if c == "magenta" then return colors.magenta end
  8.     if c == "lightBlue" then return colors.lightBlue end
  9.     if c == "orange" then return colors.orange end
  10.     if c == "yellow" then return colors.yellow end
  11.     if c == "gray" then return colors.gray end
  12.     if c == "lightGray" then return colors.lightGray end
  13.     if c == "cyan" then return colors.cyan end
  14.     if c == "purple" then return colors.purple end
  15.     if c == "brown" then return colors.brown end
  16.     if c == "green" then return colors.green end
  17.     if c == "red" then return colors.red end
  18.     if c == "black" then return colors.black end
  19. end
  20.  
  21. --f = colors.combine(f, c(#farbe#) ~ hinzufügen
  22. --f = colors.subtract(f, c(#farbe#) ~ entfernen
  23.  
  24.  
  25. --mehr oder weniger unwichtiges
  26. --nur zum überprüfen in den console
  27. function quest()
  28.     write("Welche Farbe? :")
  29.     col = read()
  30.     write("add / remove? :")
  31.     dir = read()
  32.     if dir == "add" then
  33.         f = colors.combine(f, c(col))
  34.     elseif dir == "remove" then
  35.         f = colors.subtract(f, c(col))
  36.     end
  37.     main()
  38. end
  39.  
  40. function main()
  41.     print(f)
  42.     write("Fertig?: ")
  43.     ans = read()
  44.     if ans == "ja" or ans == "JA" or ans == "Ja" or ans == "jA" then
  45.         print("zurück zur frage")
  46.         quest()
  47.     elseif ans == "reboot" then
  48.         os.reboot()
  49.     end
  50.     main()
  51. end
  52.  
  53. quest()
  54.  
  55. --du machst den einfach jedes mal nur rs.setBundledOutput("back", f)
  56. --vorher aber combine bzw. subtract machen!!
Add Comment
Please, Sign In to add comment