SHOW:
|
|
- or go back to the newest paste.
1 | link = arg[1] | |
2 | if link == nil then | |
3 | link = "Test.txt" | |
4 | end | |
5 | ||
6 | file = fs.open(link, "r") | |
7 | text = file.readAll() | |
8 | file.close() | |
9 | ||
10 | scrollspeed = arg[2] | |
11 | if scrollspeed == nil then | |
12 | scrollspeed = 0.1 | |
13 | else | |
14 | scrollspeed = tonumber(scrollspeed) | |
15 | end | |
16 | ||
17 | looping = arg[3] | |
18 | if looping == nil then | |
19 | looping = false | |
20 | end | |
21 | repeat | |
22 | for i=1, string.len(text), 1 do | |
23 | write(text:sub(i, i)) | |
24 | sleep(scrollspeed) | |
25 | end | |
26 | until not looping | |
27 | ||
28 | print() |