Simlor_GER

SimSoft 3 - Installer

Mar 29th, 2016 (edited)
647
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 6.14 KB | None | 0 0
  1. --ACHTUNG - Dies ist eine geupdatete Version von SimSoft 3 auf SimSoft 3.1!
  2.  
  3. --Alle Rechte an SimSoft 3 sind "SimlorLP" (oder in Minecraft auch nur "Simlor") vorbehalten.
  4.  
  5.  
  6. --Function
  7.  
  8. function Clear()
  9. term.clear()
  10. term.setCursorPos(1,1)
  11. end
  12.  
  13. function CP(x,y)
  14. term.setCursorPos(x,y)
  15. end
  16.  
  17. function TC(farbe)
  18. term.setTextColor(farbe)
  19. end
  20.  
  21. function BC(farbe)
  22. term.setBackgroundColor(farbe)
  23. end
  24.  
  25.  
  26. BC(128)
  27. Clear()
  28.  
  29. CP(1,1)
  30. BC(32768)
  31. print(" ")
  32. print(" ")
  33. print(" ")
  34.  
  35. CP(15,2)
  36. TC(1)
  37. print("SimSoft 3 - Installer")
  38.  
  39. TC(1)
  40. BC(128)
  41. CP(4,5)
  42.  
  43. print("Terms of use")
  44.  
  45. CP(2,8)
  46. TC(256)
  47. print("-All rights are reserved to")
  48. CP(2,9)
  49. print(" SimlorLP (or just Simlor)")
  50. CP(2,11)
  51. print("-Changes in the system may be carried out")
  52. CP(2,12)
  53. print(" only with the permission of SimlorLP.")
  54. CP(4,18)
  55. TC(1)
  56. print("Tip - Use the arrow keys")
  57.  
  58. CP(47,18)
  59. TC(256)
  60. print("1/3")
  61.  
  62. l = 1
  63.  
  64. while true do
  65.  
  66. if l == 1 then
  67.  
  68. CP(4,15)
  69. BC(128)
  70. TC(32768)
  71. print("Yes, continue ")
  72.  
  73. CP(20,15)
  74. BC(128)
  75. TC(32768)
  76. print("[No, cancel] ")
  77.  
  78. elseif l == 2 then
  79.  
  80. CP(4,15)
  81. BC(128)
  82. TC(32768)
  83. print("[Yes, continue]")
  84.  
  85. CP(20,15)
  86. BC(128)
  87. TC(32768)
  88. print("No, cancel ")
  89. end
  90.  
  91. a, b = os.pullEvent()
  92.  
  93. while a~= "key" do a,b = os.pullEvent() end
  94.  
  95. if b == 203 then
  96. l = 2
  97. end
  98.  
  99. if b == 205 then
  100. l = 1
  101. end
  102.  
  103. if b == 28 then
  104.  
  105. if l == 1 then
  106. os.reboot()
  107. break
  108. elseif l == 2 then
  109. break
  110. end
  111. end
  112. end
  113.  
  114.  
  115. --Teil 2
  116.  
  117. BC(128)
  118. Clear()
  119.  
  120. CP(1,1)
  121. BC(32768)
  122. print(" ")
  123. print(" ")
  124. print(" ")
  125.  
  126. CP(15,2)
  127. TC(1)
  128. print("SimSoft 3 - Installer")
  129.  
  130. BC(128)
  131. TC(256)
  132. CP(4,6)
  133. print("New PC-Name -")
  134.  
  135. TC(1)
  136. CP(4,9)
  137. print("New account name -")
  138.  
  139. CP(4,11)
  140. print("New account password -")
  141.  
  142. CP(47,18)
  143. TC(256)
  144. print("2/3")
  145.  
  146. CP(19,6)
  147. TC(32768)
  148. pcname = read()
  149.  
  150. CP(23,9)
  151. TC(32768)
  152. name = read()
  153.  
  154. CP(27,11)
  155. TC(32768)
  156. pass = read()
  157.  
  158. --Teil 3
  159.  
  160. BC(128)
  161. Clear()
  162.  
  163. CP(1,1)
  164. BC(32768)
  165. print(" ")
  166. print(" ")
  167. print(" ")
  168.  
  169. CP(15,2)
  170. TC(1)
  171. print("SimSoft 3 - Installer")
  172.  
  173. BC(128)
  174. CP(20,10)
  175. TC(1)
  176. print("Let's go!")
  177. CP(20,11)
  178. TC(256)
  179. print(" [Enter]")
  180.  
  181. BC(128)
  182. CP(2,17)
  183. TC(256)
  184. print("Cancel")
  185. CP(2,18)
  186. print(" [Q]")
  187.  
  188. CP(47,18)
  189. TC(256)
  190. print("3/3")
  191.  
  192. while true do
  193.  
  194. a, b = os.pullEvent()
  195.  
  196. while a~= "key" do a,b = os.pullEvent() end
  197.  
  198. if b == 16 then
  199. os.reboot()
  200. end
  201.  
  202. if b == 28 then
  203. break
  204. end
  205. end
  206.  
  207. --Teil 4 - Installer
  208.  
  209. BC(128)
  210. TC(32)
  211. Clear()
  212.  
  213. shell.run("cd /")
  214. fs.delete("SimSoft/System")
  215. fs.delete("SimSoft/SappS")
  216. fs.delete("SimSoft/Daten")
  217. fs.delete("startup")
  218. os.setComputerLabel(pcname)
  219. Clear()
  220.  
  221. BC(128)
  222. Clear()
  223.  
  224. CP(1,1)
  225. BC(32768)
  226. print(" ")
  227. print(" ")
  228. print(" ")
  229.  
  230. CP(15,2)
  231. TC(1)
  232. print("SimSoft 3 - Installer")
  233.  
  234. CP(3,8)
  235. BC(256)
  236. print(" ")
  237.  
  238. CP(3,8)
  239. BC(1)
  240. write(" ")
  241.  
  242. local file = fs.open("SimSoft/Daten/Config","w")
  243. file.close()
  244.  
  245. local file = fs.open("SimSoft/Daten/Config","a")
  246. file.writeLine("t")
  247. file.writeLine("t")
  248. file.writeLine("3.1.0")
  249. file.writeLine("en")
  250. file.close()
  251. --
  252.  
  253. local file = fs.open("SimSoft/Daten/User/User1","w")
  254. file.close()
  255. local file = fs.open("SimSoft/Daten/User/User1","a")
  256. file.writeLine(name)
  257. file.writeLine(pass)
  258. file.close()
  259.  
  260.  
  261. local file = fs.open("SimSoft/Daten/User/User2","w")
  262. file.close()
  263. local file = fs.open("SimSoft/Daten/User/User2","a")
  264. file.writeLine("Account 2")
  265. file.writeLine("123")
  266. file.writeLine("false")
  267. file.close()
  268.  
  269.  
  270. local file = fs.open("SimSoft/Daten/User/User3","w")
  271. file.close()
  272. local file = fs.open("SimSoft/Daten/User/User3","a")
  273. file.writeLine("Account 3")
  274. file.writeLine("123")
  275. file.writeLine("false")
  276. file.close()
  277.  
  278. --
  279.  
  280. write(" ")
  281.  
  282. --
  283.  
  284. local file = fs.open("SimSoft/Daten/SappS/1","w")
  285. file.close()
  286.  
  287. local file = fs.open("SimSoft/Daten/SappS/1","a")
  288. file.writeLine("")
  289. file.close()
  290.  
  291. local file = fs.open("SimSoft/Daten/SappS/1","a")
  292. file.writeLine("")
  293. file.close()
  294.  
  295. local file = fs.open("SimSoft/Daten/SappS/1","a")
  296. file.writeLine("")
  297. file.close()
  298.  
  299. local file = fs.open("SimSoft/Daten/SappS/1","a")
  300. file.writeLine("")
  301. file.close()
  302.  
  303. local file = fs.open("SimSoft/Daten/SappS/1","a")
  304. file.writeLine("n")
  305. file.close()
  306.  
  307. local file = fs.open("SimSoft/Daten/SappS/1","a")
  308. file.writeLine("false")
  309. file.close()
  310.  
  311. --
  312.  
  313. write(" ")
  314.  
  315. --
  316.  
  317. u = 1
  318.  
  319. while true do
  320.  
  321. u = (u+1)
  322.  
  323. fs.copy("SimSoft/Daten/SappS/1", "SimSoft/Daten/SappS/"..u)
  324.  
  325. if u == 15 then
  326. break
  327. end
  328. end
  329.  
  330. local file = fs.open("SimSoft/Daten/SappS/A","w")
  331. file.writeLine("0.0")
  332. file.close()
  333.  
  334. function Download(Pfad, CodePB)
  335. local cacheBuster = ("%x"):format(math.random(0, 2 ^ 30))
  336. local datei = http.get("https://pastebin.com/raw/" .. textutils.urlEncode(CodePB) .. "?cb=" .. cacheBuster)
  337. datei = datei.readAll()
  338.  
  339. local file = fs.open(Pfad, "w")
  340. file.write(datei)
  341. file.close()
  342. write(" ")
  343. end
  344.  
  345. Download("SimSoft/System/Desktop", "V32EFt9q")
  346. Download("SimSoft/System/SappS", "xvU8Ep0N")
  347. Download("SimSoft/System/SappSLoeschen", "Mg9Bc3qN")
  348. Download("SimSoft/System/SystemStart", "9TDWzqPK")
  349. Download("SimSoft/Daten/DesktopBG", "5UqmydfY")
  350. Download("startup", "MmCHLubv")
  351. Download("SimSoft/System/SystemUpdate", "46mQ0NML")
  352. Download("SimSoft/System/LiveSystem", "MssfrTSH")
  353. Download("SimSoft/System/AcManager", "cqa2Pxrh")
  354.  
  355. print(" ")
  356.  
  357. sleep(0.8)
  358.  
  359. os.reboot()
  360.  
  361.  
  362.  
  363. --end
Add Comment
Please, Sign In to add comment