Yorbo

KPW OS Beta.0.0.1

Oct 21st, 2021
777
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. ---
  2. --- Created by yannb.
  3. --- DateTime: 22/10/2021 02:36
  4. ---
  5.  
  6. local interface = peripheral.wrap("back")
  7. local canvas = interface.canvas()
  8. local text = canvas.addText({ x = 5, y = 5 }, "KPW OS BOOTING / 0%")
  9. local rect = canvas.addRectangle(0, 0, 100, 100, 0xFF34e8eb)
  10. local progress = 0
  11. local chat = peripheral.wrap("back")
  12. local afk = false
  13. local width, height = canvas.getSize()
  14. local rec_alpha = 100
  15.  
  16. rect.setSize(200, 20)
  17. rect.setAlpha(100)
  18. text.setScale(2)
  19.  
  20.  
  21. while progress < 100 do
  22.     progress = progress + 1
  23.     text.setText("KPW OS BOOTING / " .. progress .. "%")
  24.     sleep(0.03)
  25. end
  26.  
  27. while rec_alpha > 0 do
  28.     rec_alpha = rec_alpha - 2
  29.     rect.setAlpha(rec_alpha)
  30.     text.setAlpha(rec_alpha)
  31.     sleep(0.03)
  32. end
  33.  
  34.  
  35.  
  36.  
  37. while true do
  38.     local _, player, message, uuid = os.pullEvent("chat_message")
  39.  
  40.     if message:find("[Yy][aä]nn") and afk then
  41.         chat.say("Yann ist gerade AFK, hier ist le Bot der antwortet")
  42.         chat.say(player)
  43.     elseif uuid == "cc05c242-fc7b-4813-b568-3f0fe94e9b18" and message:find("afk") then
  44.         afk = true
  45.     end
  46. end
RAW Paste Data