Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function C()
- term.clear()
- end
- function CP(x,y)
- term.setCursorPos(x,y)
- end
- function BC(bgC)
- term.setBackgroundColor(bgC)
- end
- function TC(ttC)
- term.setTextColor(ttC)
- end
- function Write(text,Wx,Wy,Wbc,Wtc)
- CP(Wx,Wy)
- BC(Wbc)
- TC(Wtc)
- term.write(text)
- end
- function Input(text,rd,Ix,Iy,Ibc,Itc)
- CP(Ix,Iy)
- BC(Ibc)
- TC(Itc)
- term.write(text)
- return read(rd)
- end
- function F(Fy,Fcol)
- Write(" ",1,Fy,Fcol,Fcol)
- end
- function FS(fillCol,effect,eTime)
- y = 1
- if effect then
- for y = 1,19 do
- F(y,fillCol)
- sleep(eTime)
- end
- elseif not effect then
- for y = 1,19 do
- F(y,fillCol)
- end
- end
- end
- function ShellEvent(evt)
- a,b,c,d = os.pullEventRaw()
- if a == evt then
- return b,c,d
- end
- end
- function ShellEventAdv(a,b,c,d,e,f)
- evt,button,x,y = os.pullEventRaw()
- if evt == a then
- if button == b then
- if x >= c then
- if x <= d then
- if y >= e then
- if y <= f then
- return true
- else
- return false
- end
- else
- return false
- end
- else
- return false
- end
- else
- return false
- end
- else
- return false
- end
- else
- return false
- end
- end
- function PastebinGet(PBcode,Fpath)
- http.get(PBcode,Fpath)
- end
- function FsDel(Fpath)
- fs.delete(Fpath)
- end
- function FsMkdir(dir)
- fs.makeDir(dir)
- end
- function FsExists(file)
- return fs.exists(file)
- end
- function OsReboot()
- os.reboot()
- end
- function OsShutdown()
- os.shutdown()
- end
- function Api(api)
- os.loadAPI(api)
- end
- function Image(Image,x,y)
- img = paintutils.loadImage(Image)
- paintutils.drawImage(img,x,y)
- end
- function Button(text,x,midY,bgC,ttC)
- for x1 = x,(x + (string.len(text))) + 1 do
- Write(" ",x1,midY - 1,bgC,ttC)
- end
- Write(" "..text.." ",x,midY,bgC,ttC)
- for x1 = x,(x + (string.len(text))) + 1 do
- Write(" ",x1,midY + 1,bgC,ttC)
- end
- end
- function Users()
- local file = fs.open("/ProgramFiles/Nano/Users/Data/Logon/List")
- data = file.readAll()
- return data
- end
- function UserExsists(usr,data)
- if usr in data then
- return true
- else
- return false
- end
- end
Add Comment
Please, Sign In to add comment