Guest User

sarch

a guest
Oct 28th, 2023
118
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 3.56 KB | None | 0 0
  1. {
  2.   [ "testwp.lua" ] = "os.loadAPI('tos/tos')\
  3. print(tos.getPersistentVariable('wpc'))",
  4.   upline = "os.loadAPI('/uap')\
  5. os.loadAPI('lg/lg')\
  6. lg.setup('term')\
  7. lg.fillScreen(colors.white)\
  8. lg.fill(1,26,2,2,colors.lightGray)\
  9. lg.drawText(2,4,colors.white,colors.gray,' Enter upline color:    ')\
  10. lg.drawInput(' ',2,25,6,6,20)\
  11. \
  12. lg.drawBT('heart',2,2,12,12,colors.black,colors.white,'\\3')\
  13. lg.drawBT('note',4,4,12,12,colors.black,colors.white,'\\15')\
  14. lg.drawBT('dot',6,6,12,12,colors.black,colors.white,'\\7')\
  15. lg.drawBT('smileface',8,8,12,12,colors.black,colors.white,'\\2')\
  16. lg.drawBT('save',2,6,17,17,colors.white,colors.green,' save ')\
  17. local upl_col = \"gray\"\
  18. local upl_sym = \"\\15\"\
  19. if not lg.isColor(upl_col) then\
  20.  upl_col = \"gray\"\
  21. end\
  22. os.sleep(0.5)\
  23. while true do\
  24.  local event, button, x, y = os.pullEvent( \"mouse_click\" )\
  25.    if (lg.isInput(x,y) == \" \") then\
  26.    upl_col = lg.getInput(x,y)\
  27.    if not lg.isColor(upl_col) then upl_col = \"gray\" end\
  28.    tos.writePersistentVariable(\"upl_col\",upl_col)\
  29.    elseif (lg.isButton(x,y) == 'heart') then\
  30.    upl_sym = '\\3'\
  31.    elseif (lg.isButton(x,y) == 'note') then\
  32.    upl_sym = '\\15'\
  33.    elseif (lg.isButton(x,y) == 'dot') then\
  34.    upl_sym = '\\7'\
  35.    elseif (lg.isButton(x,y) == 'smileface') then\
  36.    upl_sym = '\\2'\
  37.    elseif (lg.isButton(x,y) == 'save') then\
  38.    tos.writePersistentVariable('upl_sym', upl_sym)\
  39.    os.sleep(0.5)\
  40.    os.reboot()\
  41.    end\
  42.    if lg.isButton(x,y) or lg.isInput(x,y) then\
  43.      lg.drawText(2,14,colors.white,lg.getColor(upl_col)\
  44.      ,upl_sym)\
  45.    end    \
  46.  end\
  47.  \
  48. lg.exit()",
  49.   settings = "os.loadAPI('lg/lg')\
  50. os.loadAPI('tos/tos')\
  51. os.loadAPI(\"uap\")\
  52. lg.setup('term')\
  53. lg.fillScreen(colors.white)\
  54. lg.fill(1,26,2,2,colors.lightGray)\
  55. \
  56. lg.drawBT('wp',2,25,4,4,colors.black,colors.lightGray,' Wallpaper color')\
  57. lg.drawBT('upl',2,25,6,6,colors.black,colors.lightGray,' Upper line settings')\
  58. lg.drawBT('dwnl',2,25,8,8,colors.black,colors.lightGray,' Down line color')\
  59. uap.upd()\
  60. while true do\
  61.  local event, button, x, y = os.pullEvent( \"mouse_click\" )\
  62.  if (lg.isButton(x,y) == \"wp\") then\
  63.    tos.openFile('/settings/wallpaper')\
  64.    sleep(0.1)\
  65.  elseif (lg.isButton(x,y) == 'upl') then\
  66.    tos.openFile('/settings/upline')\
  67.  elseif (lg.isButton(x,y) == 'dwnl') then\
  68.    tos.openFile('/settings/dwnline')\
  69.  end\
  70. end\
  71. \
  72. lg.exit()",
  73.   wallpaper = "os.loadAPI('/uap')\
  74. os.loadAPI('lg/lg')\
  75. lg.setup('term')\
  76. local wpcolor = \"gray\"\
  77. if not lg.isColor(wpcolor) then\
  78.  wpcolor = \"gray\"\
  79. end\
  80. lg.fillScreen(colors.white)\
  81. lg.fill(1,26,2,2,colors.lightGray)\
  82. lg.drawText(2,4,colors.white,colors.gray,' Enter wallpaper color: ')\
  83. lg.drawInput(' ',2,25,6,6,20)\
  84. os.sleep(0.5)\
  85. while true do\
  86.  local event, button, x, y = os.pullEvent( \"mouse_click\" )\
  87.  if (lg.isInput(x,y) == \" \") then\
  88.    local wpcolor = lg.getInput(x,y)\
  89.    tos.writePersistentVariable('color',wpcolor)\
  90.  end\
  91.  end\
  92. \
  93. lg.exit()",
  94.   dwnline = "os.loadAPI('/uap')\
  95. os.loadAPI('lg/lg')\
  96. lg.setup('term')\
  97. lg.fillScreen(colors.white)\
  98. lg.fill(1,26,2,2,colors.lightGray)\
  99. lg.drawText(2,4,colors.white,colors.gray,' Enter downline color:  ')\
  100. lg.drawInput(' ',2,25,6,6,20)\
  101. local dwl_col = \"gray\"\
  102. if not lg.isColor(dwl_col) then\
  103. dwl_col = \"gray\"\
  104. end\
  105. os.sleep(0.5)\
  106. while true do\
  107.  local event, button, x, y = os.pullEvent( \"mouse_click\" )\
  108.  if (lg.isInput(x,y) == \" \") then\
  109.    local dwl_col = lg.getInput(x,y)\
  110.    tos.writePersistentVariable('dwl_col',dwl_col)\
  111.  end\
  112.  end\
  113. \
  114. lg.exit()",
  115. }
Advertisement
Add Comment
Please, Sign In to add comment