Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local x,y = term.getSize()
- tChars = { "A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z" }
- tWords = {}
- print("Enter the path to a word list (a file with a word on each line)")
- write("Path: /")
- path = read()
- if fs.exists( path ) then
- file = fs.open( path, "r" )
- if file then
- line = file.readLine()
- while line do
- tWords[#tWords+1] = line
- line = file.readLine()
- end
- file.close()
- else
- error("Y U NO SELECT A REAL FILE?!?!?!?!?")
- end
- else
- error("Y U NO SELECT A FILE?!??!")
- end
- function drawWords()
- for i=1,x do
- for z=1,y do
- term.setCursorPos(i,z)
- write( tChars[ math.random( #tChars ) ] )
- end
- end
- for i=1,#tWords do
- repeat
- randomStart = math.random( x )
- until (tWords[ i ] + randomStart) < x
- term.setCursorPos( randomStart, math.random( y ) )
- end
- end
- drawWords()
- sleep(126000)
Advertisement
Add Comment
Please, Sign In to add comment