Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -- pastebin get uR8v94ss color
- os.pullEvent = os.pullEventRaw
- scr_x, scr_y = term.getSize()
- seed = math.random(1, 255)
- local function rollOver(input, max)
- return math.floor(input % max)
- end
- local function getColor(input)
- return 2^rollOver(input, 16)
- end
- term.setBackgroundColor(colors.black)
- term.clear()
- term.setCursorPos(1,1)
- y = 0
- bacColor = 1
- scrollUp = true
- while true do
- if scrollUp then
- term.scroll(1)
- term.setCursorPos(1,scr_y)
- else
- term.scroll(-1)
- term.setCursorPos(1,1)
- end
- for x = 1, scr_x do
- txtColor = getColor(bacColor + seed + y)
- bacColor = getColor((((x + y) - seed) + (y * (seed / 50))) + 100)
- term.setBackgroundColor(bacColor)
- term.setTextColor(txtColor)
- write("#")
- end
- y = y + 1
- if scrollUp then
- term.scroll(1)
- term.setCursorPos(1,scr_y)
- else
- term.scroll(-1)
- term.setCursorPos(1,1)
- end
- for x = 1, scr_x do
- txtColor = getColor(bacColor + seed + y)
- bacColor = getColor((((x - y) + seed) - (y + (seed * 100))) * 100)
- term.setBackgroundColor(bacColor)
- term.setTextColor(txtColor)
- write("#")
- end
- y = y + 1
- if y >= 512 then
- y = 0
- scrollUp = not scrollUp
- seed = math.random(1, 255)
- end
- sleep(0)
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement