Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -- VARIABLES --
- shell.run("name/varnom")
- shell.run("name/paint.name")
- --FUNCTIONS --
- function paintedit()
- term.setBackgroundColor(colours.blue)
- term.setTextColor(colours.white)
- term.setCursorPos(16,7)
- print(" Outil de dessin X")
- term.setBackgroundColor(colours.lightGrey)
- term.setTextColor(colours.black)
- term.setCursorPos(16,8)
- print(" [...] ")
- event, button, xpos, ypos = os.pullEvent("mouse_click")
- if xpos==36 and ypos==7 then
- screen()
- elseif xpos>=24 and xpos<=28 and ypos==8 then
- term.setCursorPos(24,8)
- print(" ")
- term.setCursorPos(20,8)
- ptedit = read()
- shell.run("paint "..ptedit)
- shell.run("base")
- end
- end
- -- ECRAN --
- function screen()
- shell.run("name/paint.name")
- shell.run("name/varnom")
- shell.run("config/bgimg.cfg")
- term.setBackgroundColour(colours.cyan)
- term.clear()
- paintutils.drawImage(paintutils.loadImage(bgimg),1,1)
- term.setCursorPos(1,1)
- term.setBackgroundColour(colours.lightGrey)
- term.clearLine()
- term.setBackgroundColour(colours.blue)
- term.setTextColour(colours.white)
- print(" MENU ")
- -- ICONE FILE BROWSER --
- paintutils.drawImage(paintutils.loadImage("Icons/fs.ico"),3,4)
- term.setBackgroundColour(colours.cyan)
- term.setCursorPos(2,9)
- print(FichiersName)
- term.setTextColour(colours.red)
- term.setCursorPos(8,4)
- term.write("+")
- -- ICONE ESSENTIAL CHAT --
- paintutils.drawImage(paintutils.loadImage("Icons/EC.ico"),3,11)
- term.setCursorPos(1,17)
- term.setTextColour(colours.white)
- term.setBackgroundColour(colours.cyan)
- print(" E-Chat")
- term.setTextColour(colours.red)
- term.setCursorPos(8,11)
- term.write("+")
- -- ICONE CLOUDSTORAGE --
- term.setBackgroundColor(colours.grey)
- term.setCursorPos(14,11)
- print(" ")
- term.setCursorPos(13,12)
- print(" ")
- term.setCursorPos(12,13)
- print(" ")
- term.setCursorPos(13,14)
- print(" ")
- term.setCursorPos(14,15)
- print(" ")
- term.setCursorPos(12,17)
- term.setTextColour(colours.white)
- term.setBackgroundColor(colours.cyan)
- print(" Cloud")
- term.setTextColour(colours.red)
- term.setCursorPos(19,11)
- term.write("+")
- -- ICONE PAINT --
- term.setCursorPos(13,4)
- term.setBackgroundColor(colours.black)
- paintutils.drawImage(paintutils.loadImage("Icons/paint.ico"),13,4)
- term.setTextColor(colours.white)
- term.setCursorPos(13,9)
- term.setBackgroundColor(colours.cyan)
- print(PaintName)
- term.setTextColour(colours.red)
- term.setCursorPos(19,4)
- term.write("+")
- -- CREDITS BARRE --
- term.setCursorPos(1,19)
- term.setBackgroundColour(colours.blue)
- term.clearLine()
- term.setCursorPos(3,19)
- write("[Bugs ?]")
- -- while true do
- event, button, xpos, ypos = os.pullEvent("mouse_click")
- if xpos >=3 and xpos <=7 and ypos >=4 and ypos <=7 then
- shell.run("Browser")
- elseif xpos >=3 and xpos <=7 and ypos >=12 and ypos <=15 then
- shell.run("EssentialChat")
- elseif xpos >=3 and xpos<=10 and ypos ==19 then
- shell.run("bugcheck")
- elseif xpos>=12 and xpos<=21 and ypos>=11 and ypos<=15 then
- shell.run("CloudStorage/cloudpage")
- elseif xpos>=13 and xpos<=18 and ypos>=4 and ypos<=10 then
- paintedit()
- elseif xpos ==8 and ypos ==4 then -- OPTIONS BROWSER
- term.setCursorPos(9,5)
- term.setBackgroundColour(colours.blue)
- term.setTextColour(colours.white)
- print(" OPTIONS ")
- term.setTextColour(colours.red)
- term.setCursorPos(23,5)
- write("X")
- term.setBackgroundColour(colours.white)
- term.setCursorPos(9,6)
- term.setTextColour(colours.blue)
- print(" Renommer ")
- term.setCursorPos(9,7)
- print(" Editer icone ")
- while true do
- event, button, xpos, ypos = os.pullEvent("mouse_click")
- if xpos==23 and ypos==5 then
- screen()
- elseif xpos >=9 and xpos <= 23 and ypos ==6 then
- term.setCursorPos(2,9)
- term.setTextColour(colours.blue)
- -- term.setBackgroundColour(colours.lightGrey)
- write("Nom : ")
- NewName = read()
- varnom = fs.open("name/varnom","w")
- varnom.writeLine("FichiersName = '"..NewName.."'")
- varnom.close()
- shell.run("varnom")
- screen()
- elseif xpos>=9 and xpos<=23 and ypos==7 then
- shell.run("paint Icons/fs.ico")
- shell.run("base")
- end
- end
- elseif xpos ==8 and ypos ==11 then -- OPTIONS ESSENTIAL CHAT
- term.setCursorPos(9,12)
- term.setBackgroundColour(colours.blue)
- term.setTextColour(colours.white)
- print(" OPTIONS ")
- term.setTextColour(colours.red)
- term.setCursorPos(23,12)
- write("X")
- term.setBackgroundColour(colours.white)
- term.setCursorPos(9,13)
- term.setTextColour(colours.blue)
- print(" Renommer ")
- term.setCursorPos(9,14)
- print(" Editer icone ")
- while true do
- event, button, xpos, ypos = os.pullEvent("mouse_click")
- if xpos==23 and ypos==12 then
- shell.run("base")
- elseif xpos >=9 and xpos <= 23 and ypos ==13 then -- A BOSSER --
- term.setCursorPos(2,17)
- term.setTextColour(colours.blue)
- -- term.setBackgroundColour(colours.lightGrey)
- write("Nom : ")
- NewECName = read()
- EName = fs.open("name/EC.name","w")
- EName.writeLine("ECName = '"..NewECName.."'")
- EName.close()
- shell.run("EC.name")
- shell.run("base")
- elseif xpos>=9 and xpos<=23 and ypos==14 then
- shell.run("paint Icons/EC.ico")
- shell.run("base")
- end
- end
- elseif xpos ==19 and ypos ==4 then -- OPTIONS PAINT
- term.setCursorPos(20,5)
- term.setBackgroundColour(colours.blue)
- term.setTextColour(colours.white)
- print(" OPTIONS ")
- term.setTextColour(colours.red)
- term.setCursorPos(34,5)
- write("X")
- term.setBackgroundColour(colours.white)
- term.setCursorPos(20,6)
- term.setTextColour(colours.blue)
- print(" Renommer ")
- term.setCursorPos(20,7)
- print(" Editer icone ")
- while true do
- event, button, xpos, ypos = os.pullEvent("mouse_click")
- if xpos==34 and ypos==5 then
- shell.run("base")
- elseif xpos >=9 and xpos <= 23 and ypos ==6 then
- term.setCursorPos(13,9)
- term.setTextColour(colours.blue)
- -- term.setBackgroundColour(colours.lightGrey)
- write("Nom : ")
- NewPName = read()
- PName = fs.open("name/paint.name","w")
- PName.writeLine("PaintName = '"..PName.."'")
- PName.close()
- shell.run("paint.name")
- shell.run("base")
- elseif xpos>=9 and xpos<=23 and ypos==7 then
- shell.run("paint Icons/paint.ico")
- shell.run("base")
- end
- end
- elseif xpos >= 1 and xpos <=6 and ypos ==1 then
- term.setCursorPos(2,2)
- term.setBackgroundColour(colours.black)
- term.setTextColour(colours.white)
- print(" MENU ")
- term.setCursorPos(2,3)
- term.setBackgroundColour(colours.blue)
- term.setTextColour(colours.white)
- print(" Eteindre ")
- term.setCursorPos(2,4)
- print(" Edition ")
- term.setCursorPos(2,5)
- print(" Fichiers >")
- term.setCursorPos(2,6)
- print(" Reboot ")
- term.setCursorPos(2,7)
- print(" Gestion ")
- event, button, xpos, ypos = os.pullEvent("mouse_click")
- if xpos >=2 and xpos <=11 and ypos ==3 then
- os.shutdown()
- elseif xpos >=2 and xpos <=11 and ypos ==4 then
- shell.run("edit")
- elseif xpos ==12 and ypos ==5 then
- term.setCursorPos(13,5)
- print(" ClickTest ")
- term.setCursorPos(13,6)
- print(" Explorer ")
- event, button, xpos, ypos = os.pullEvent("mouse_click")
- if xpos >=13 and xpos <=23 and ypos ==5 then
- shell.run("clicktest")
- elseif xpos >=13 and xpos <=23 and ypos ==6 then
- shell.run("Browser")
- else
- shell.run("base")
- end
- elseif xpos >=2 and xpos <=11 and ypos ==6 then
- shell.run("rbsystem")
- else
- screen()
- end
- else
- shell.run("base")
- end
- end
- screen()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement