SHOW:
|
|
- or go back to the newest paste.
1 | - | --|=====================| |
1 | + | --|===================| |
2 | - | --| Установщик Софта | |
2 | + | --| Обновлялка ofline | |
3 | - | --| Soft Installer | |
3 | + | --| MCSkill.ru TMSB | |
4 | - | --| Developer: Barawik_ | |
4 | + | --| BaraPad | Und.OS | |
5 | - | --| Holograms edition | |
5 | + | --|Developer: Barawik_| |
6 | - | --|=====================| |
6 | + | --|===================| |
7 | ||
8 | local shell = require("shell") | |
9 | - | local event = require("event") |
9 | + | |
10 | - | print("\nУдаление старых файлов.") |
10 | + | local event=require("event") |
11 | - | os.sleep(1) |
11 | + | local component=require("component") |
12 | - | shell.execute("rm holo_print.lua") |
12 | + | local colors = require("colors") |
13 | - | shell.execute("rm test_holo.holo") |
13 | + | local g = component.gpu |
14 | - | print("\nСтарые файлы удалены.") |
14 | + | |
15 | - | os.sleep(1) |
15 | + | if not fs.exists("/lib/Bar.lua") then |
16 | - | print("\nПодготовка к установке новым файлам.") |
16 | + | shell.execute("wget https://raw.githubusercontent.com/Gorodlilov/BarashPad/master/Barlib.lua /lib/Bar.lua") |
17 | - | os.sleep(2) |
17 | + | end |
18 | - | shell.execute("wget https://raw.githubusercontent.com/BarawikS/Holo/master/holograms/holo_print.lua holo_print.lua") |
18 | + | local Bar = require("Bar") |
19 | - | print("\nПрограмма для отображения установлена.") |
19 | + | |
20 | - | os.sleep(2) |
20 | + | --------------------Настройки-------------------- |
21 | - | shell.execute("wget https://raw.githubusercontent.com/BarawikS/Holo/master/holograms/test_holo.holo test_holo.holo") |
21 | + | local WIGHT, HEIGHT = 146, 42 --Разрешение моника 146/112 x 42 |
22 | - | print("\nТестовая голограмма установлена.") |
22 | + | local COLOR1 = 0x30626b --Рамка |
23 | - | -- Перезапуск компа |
23 | + | local COLOR2 = 0x240935 --Цвет кнопок |
24 | - | print("\nЧтобы отключить инсталлер, просто тыкните.") |
24 | + | local COLOR3 = 0x00382b --Таблица |
25 | - | local e = event.pull("touch") |
25 | + | local COLOR_SHELL = 0xa73853 --Цвет шелла |
26 | - | print("\nОтключение") |
26 | + | local mid = (WIGHT-32)/2+32 -- Центральное слово |
27 | - | os.sleep(2) |
27 | + | ------------------------------------------------- |
28 | - | shell.execute("clear") |
28 | + | |
29 | - | os.sleep(1) |
29 | + | WIGHT, HEIGHT = Bar.Resolution(WIGHT, HEIGHT) |
30 | Bar.Ram("Обновляльщик", COLOR1,COLOR2,WIGHT, HEIGHT) | |
31 | ||
32 | Bar.Word(mid - 24,7, "UPDBAR", 0x000000) | |
33 | ||
34 | Bar.Mid(WIGHT,26,"Прочитка старых файлов...") | |
35 | if fs.exists("Barapad.lua") then | |
36 | Bar.Mid(WIGHT,27,"Barapad обнаружен!") | |
37 | else | |
38 | Bar.Mid(WIGHT,27,"Barapad не обнаружен!") | |
39 | end | |
40 | os.sleep(2) | |
41 | if fs.exists("Programms.lua") then | |
42 | Bar.Mid(WIGHT,28,"Список программ обнаружен!") | |
43 | else | |
44 | Bar.Mid(WIGHT,28,"Список программ не обнаружен!") | |
45 | end | |
46 | os.sleep(2) | |
47 | Bar.Mid(WIGHT,30,"Начинаю удалять старые файлы.") | |
48 | os.sleep(1) | |
49 | shell.execute("rm Barapad.lua") | |
50 | shell.execute("rm Programms.lua") | |
51 | shell.execute("rm /lib/Bar.lua") | |
52 | Bar.Mid(WIGHT,31,"Старые файлы все удадалены!") | |
53 | os.sleep(2) | |
54 | Bar.Mid(WIGHT,33,"Начинаю закачку новых файлов.") | |
55 | os.sleep(1) | |
56 | shell.execute("wget https://raw.githubusercontent.com/Gorodlilov/BarashPad/master/Barlib.lua /lib/Bar.lua") | |
57 | shell.execute("wget https://raw.githubusercontent.com/Gorodlilov/BarashPad/master/Barapad.lua Barapad.lua") | |
58 | shell.execute("wget https://raw.githubusercontent.com/Gorodlilov/BarashPad/master/Programms.lua Programms.lua") | |
59 | Bar.Mid(WIGHT,35,"Новые файлы загружены.") | |
60 | Bar.Mid(WIGHT,36,"Перезагружаем компьютер.") | |
61 | os.sleep(2) | |
62 | os.execute("reboot") |