Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- x=4
- br=0.5
- file="bild"
- t=peripheral.wrap("top")
- t.clear()
- color={}
- color[" "]=0x0000FF
- color["0"]=0xF0F0F0
- color["1"]=0xF2B233
- color["2"]=0xE57FD8
- color["3"]=0x99B2F2
- color["4"]=0xDEDE6C
- color["5"]=0x7FCC19
- color["6"]=0xF2B2CC
- color["7"]=0x4C4C4C
- color["8"]=0x999999
- color["9"]=0x4C99B2
- color["a"]=0xB266E5
- color["b"]=0x3366CC
- color["c"]=0x7F664C
- color["d"]=0x57A64E
- color["e"]=0xCC4C4C
- color["f"]=0x191919
- fp=fs.open(file,"r")
- y=1
- line=1
- while line~=nil do
- line=fp.readLine()
- if line~=nil then
- for i=1,#line do
- --t.addText(i*1,y*1,"*",color[string.sub(line,i,i)])
- t.addBox(i*x,y*x,x,x,color[string.sub(line,i,i)],br)
- end
- end
- y=y+1
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement