Advertisement
Guest User

Untitled

a guest
Nov 9th, 2019
146
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 10.37 KB | None | 0 0
  1. system.disableChatCommandDisplay("m", true)
  2. system.disableChatCommandDisplay("clear", true)
  3. tfm.exec.disableAutoNewGame(true)
  4. tfm.exec.disableAutoShaman(true)
  5. tfm.exec.newGame("@4459589")
  6. version = "3.0"
  7. tfm.exec.setUIMapName("<VP>Швиндовс 1.0 rus <p")
  8. -- Tables para o EventLoop
  9. n = 0
  10. hora = false
  11. atualizar = false
  12. efeitos = false
  13. tempo = os.date("Hoje é %A, de %B")
  14. messeger = {""}
  15. msn = false
  16.  
  17. --
  18. ui.addTextArea(700, "<B><R><a href='event:on'><font size='9'>O</a></B>", nil, 400, 293, 14, 14, 0, 0, 1.1);
  19. --
  20.  
  21. COLOR = "<VP>"
  22. bordColor = 0x2ECF73
  23.  
  24. function guiColor()
  25. if COLOR == "<VI>" then
  26. bordColor = 0xC53DFF
  27. end
  28. if COLOR == "<VP>" then
  29. bordColor = 0x2ECF73
  30. end
  31. if COLOR == "<N>" then
  32. bordColor = 0xC2C2DA
  33. end
  34. if COLOR == "<CH>" then
  35. bordColor = 0x98E2EB
  36. end
  37. if COLOR == "<ROSE>" then
  38. bordColor = 0xED67EA
  39. end
  40. if COLOR == "<J>" then
  41. bordColor = 0xFFFF00
  42. end
  43. if COLOR == "<R>" then
  44. bordColor = 0xCB546B
  45. end
  46. if COLOR == "<V>" then
  47. bordColor = 0x009D9D
  48. end
  49. end
  50.  
  51.  
  52. function areaTrabalho()
  53. ui.addTextArea(1, "<P align='center'>"..COLOR.."<font size='20'><b>Швиндовс</B></P><font size='13'>Что ты хочеть нажать?</font>", nil, 179, 75, 455, 208, 1, 1, 0.3);
  54. ui.addTextArea(2, "<a href='event:tfm'>ТФМ</a>", nil, 190, 150, 28, 20, 1, bordColor, 1.1);
  55. ui.addTextArea(3, "<a href='event:atualizar'>ОБН</a>", nil, 240, 150, 28, 20, 1, bordColor, 1.1);
  56. ui.addTextArea(4, "<a href='event:hora'>ВРМ</a>", nil, 290, 150, 28, 20, 1, bordColor, 1.1);
  57. ui.addTextArea(5, "<a href='event:cor'>ЦВТ</a>", nil, 340, 150, 30, 20, 1, bordColor, 1.1);
  58. ui.addTextArea(6, "<a href='event:status'>??? (Ошибка)</a>", nil, 390, 150, 30, 20, 1, bordColor, 1.1);
  59. ui.addTextArea(7, "<a href='event:mp3'>MP3</a>", nil, 440, 150, 30, 20, 1, bordColor, 1.1);
  60. ui.addTextArea(8, "<a href='event:efeitodetela'>SCR</a>", nil, 490, 150, 30, 20, 1, bordColor, 1.1);
  61. ui.addTextArea(9, "<a href='event:msn'>ОТД</a>", nil, 540, 150, 30, 20, 1, bordColor, 1.1);
  62. ui.addTextArea(10, "<a href='event:help'>ПОМ</a>", nil, 590, 150, 30, 20, 1, bordColor, 1.1);
  63. end
  64.  
  65. function removeText()
  66. for i = 60, 1, -1 do
  67. ui.removeTextArea(i)
  68. end
  69. end
  70.  
  71. function eventTextAreaCallback(textAreaId, playerName, callback)
  72. if (callback=="on") then
  73. ui.addTextArea(1, "<P align='center'>"..COLOR.."<b><font size='20'>Швиндовс</P></b><BR><font size='14'>O Включение Швиндовс завершенно успешно<BR>Внимение! Данным компьютером могут пользоваться все игроки находящиеся на локации!<BR><BR><a href='event:iniciar'>Старт</a>", nil, 179, 75, 455, 208, 1, 1, 0.3);
  74. end
  75.  
  76. if(callback=="off") then
  77. atualizar = false
  78. ui.addTextArea(102, "<P align='center'>"..COLOR.."<font size='20'><b>Швиндовс</B></P><font size='13'>Вы хотите выйти?</font><BR><BR><BR><BR><font size='17'><a href='event:sim'>Да</a> <a href='event:iniciar'>Нет</a>", nil, 179, 75, 455, 208, 1, 1, 1.1);
  79. ui.addTextArea(700, "<B><R><a href='event:on'><font size='9'>O</a></B>", nil, 400, 293, 14, 14, 0, 0, 1.1);
  80. end
  81. if(callback=="sim") then
  82. ui.addTextArea(700, "<B><VP><a href='event:off'><font size='9'>O</a></B>", nil, 400, 293, 14, 14, 0, 0, 1.1);
  83. for i = 600, 1, -1 do
  84. ui.removeTextArea(i)
  85. end
  86. end
  87.  
  88. if (callback=="help") then
  89. removeText()
  90. ui.addTextArea(102, "<P align='center'>"..COLOR.."<font size='20'><b>Швиндовс</B></P><font size='15'>(Ошибка)</font><BR><BR><font size='10'><B>ТФМ</B> - Transformice<BR><B>ATU</B> - Обнови свою операционную систему <BR><B>ВРЕ</B> - Дата и день<BR><B>ЦВЕ</B> - Выбрать цвет для Швиндовс<BR><B>STS</B> - (Ошибка!)<BR><B>MP3</B> - Поиск звука/видео<BR><B>ОТД</B> - Режим ожидания (Выполнение системных процессов...)<BR><B>СОБ</B> - Отправлять сообщения Используйте !m [text] для отправки сообщения, или используйте прокрутку чтобы увидеть сообщения (старые).<BR><a href='event:iniciar'>Назад</a>", nil, 179, 75, 455, 208, 1, 1, 0.3);
  91. end
  92.  
  93. if (callback=="iniciar") then
  94. areaTrabalho()
  95. ui.removeTextArea(101)
  96. ui.removeTextArea(102)
  97. ui.removeTextArea(103)
  98. efeitos = false
  99. hora = false
  100. msn = false
  101. end
  102.  
  103. if (callback=="tfm") then
  104. ui.addTextArea(101, "<P align='center'><font size='20'><b>Швиндовс - Ошибка</B></P><font size='13'>Ошибка связана с процессом Transformice.exe(C:/Program Files/ Transformice)<BR> Для работы процесса нужно:<BR>1. Освободить 15мб ОЗУ <BR>2. Освободите память для продолжения операции <BR>3. Перезагрузите компьютер <BR>Ошибка 1: Нет памяти.</font>", nil, 179, 75, 455, 208, 130, 130, 1);
  105. removeText()
  106. end
  107.  
  108. if (callback=="msn") then
  109. removeText()
  110. ui.addTextArea(102, "<P align='center'>"..COLOR.."<font size='20'><b>Швиндовс</B></P><font size='13'>Сообщения</font><BR><BR><p aling='left'><font size='10'>"..messeger[1].."<BR><a href='event:iniciar'>Назад</a>", nil, 179, 75, 455, 208, 1, 1, 0.3);
  111.  
  112. msn = true
  113. end
  114.  
  115. if (callback=="atualizar") then
  116. atualizar = true
  117. removeText()
  118. end
  119.  
  120. if(callback=="hora")then
  121. hora = true
  122. removeText()
  123. end
  124.  
  125. if(callback=="cor")then
  126. removeText()
  127. ui.addTextArea(102, "<P align='center'>"..COLOR.."<font size='20'><b>Швиндовс</B></P><font size='13'>Выберите для Швиндовс цвет</font><BR><BR><font size='10'><BR><VP><a href='event:corverde'> ПО УМОЛЧАНИЮ</a><BR><VI><a href='event:corRoxo'>?</a><BR><N><a href='event:corbranca'>?</a><BR><CH><a href='event:corazul'>?</a><BR><ROSE><a href='event:corrosa'>?</a><BR><J><a href='event:coramarelo'>?</a><BR><R><a href='event:corvermelho'>?</a><BR><V><a href='event:corazul2'>?</a>", nil, 179, 75, 455, 208, 1, 1, 0.3);
  128. guiColor()
  129. end
  130. if(callback=="corverde")then
  131. COLOR = "<VP>"
  132. guiColor()
  133. areaTrabalho()
  134. ui.removeTextArea(101)
  135. ui.removeTextArea(102)
  136. end
  137. if(callback=="corRoxo")then
  138. COLOR = "<VI>"
  139. guiColor()
  140. areaTrabalho()
  141. ui.removeTextArea(101)
  142. ui.removeTextArea(102)
  143. end
  144. if(callback=="corbranca")then
  145. COLOR = "<N>"
  146. guiColor()
  147. areaTrabalho()
  148. ui.removeTextArea(101)
  149. ui.removeTextArea(102)
  150. end
  151. if(callback=="corazul")then
  152. COLOR = "<CH>"
  153. guiColor()
  154. areaTrabalho()
  155. ui.removeTextArea(101)
  156. ui.removeTextArea(102)
  157. end
  158. if(callback=="corrosa")then
  159. COLOR = "<ROSE>"
  160. guiColor()
  161. areaTrabalho()
  162. ui.removeTextArea(101)
  163. ui.removeTextArea(102)
  164. end
  165. if(callback=="coramarelo")then
  166. COLOR = "<J>"
  167. guiColor()
  168. areaTrabalho()
  169. ui.removeTextArea(101)
  170. ui.removeTextArea(102)
  171. end
  172. if(callback=="corvermelho")then
  173. COLOR = "<R>"
  174. guiColor()
  175. areaTrabalho()
  176. ui.removeTextArea(101)
  177. ui.removeTextArea(102)
  178. end
  179. if(callback=="corazul2")then
  180. COLOR = "<V>"
  181. guiColor()
  182. areaTrabalho()
  183. ui.removeTextArea(101)
  184. ui.removeTextArea(102)
  185. end
  186.  
  187. if(callback=="status")then
  188. removeText()
  189. ui.addTextArea(102, "<P align='center'>"..COLOR.."<font size='20'><b>Швиндовс</B></P><font size='13'>Player Stats</font><BR><BR><font size='10'><B>Name:</B> "..playerName.."<BR><B>Tribe:</B> "..tfm.get.room.playerList[playerName].tribeName.."<BR><B>Cfm stats</B> : <A href='en.cheese.formice.com/mouse/"..playerName.."'>HERE</a><BR><BR><a href='event:iniciar'>Back</a>", nil, 179, 75, 455, 208, 1, 1, 0.3);
  190. end
  191. if(callback=="mp3")then
  192. removeText()
  193. ui.addPopup(0, 2, "Введи ссылку видео/музыки из видеохостинга YouTube", playerName, 303, 156, 200,20)
  194. ui.addTextArea(102, "<P align='center'>"..COLOR.."<font size='20'><b>Швиндовс</B></P><font size='15'>Найдите звук </font> <BR><BR><BR><BR><BR><BR><a href='event:iniciar'>Назад</a>", nil, 179, 75, 455, 208, 1, 1, 0.3);
  195. end
  196. if(callback=="efeitodetela")then
  197. ui.addTextArea(102, "<P align='center'>"..COLOR.."<font size='20'><b>Швиндовс</B></P><font size='15'>Режим Отдыха (Выполнение системных процессов)</font> <BR><BR><BR><BR><a href='event:iniciar'>Назад</a>", nil, 179, 75, 455, 208, 1, 1, 0.3);
  198. efeitos = true
  199. removeText()
  200. end
  201. end
  202.  
  203. function eventPopupAnswer(popupId, playerName, answer)
  204. if popupId == 0 then
  205. ui.addTextArea(102, "<P align='center'>"..COLOR.."<font size='20'><b>Швиндовс</B></P><font size='15'>Найдите звук</font> <BR><BR><a href='beemp3s.org/index.php?q="..answer.."'>(Начало процесса):/ Поиск</a><BR><BR><a href='event:iniciar'>Назад</a>", nil, 179, 75, 455, 208, 1, 1, 0.3);
  206. end
  207. end
  208.  
  209. function eventLoop()
  210.  
  211. if atualizar == true then
  212. n = n+1
  213. ui.addTextArea(102, "<P align='center'>"..COLOR.."<font size='20'><b>Швиндовс</B></P><font size='13'>Обновление системных процессов</font><BR><BR><font size='17'>"..n.."%", nil, 179, 75, 455, 208, 1, 1, 0.3);
  214. end
  215.  
  216. if n == 100 then
  217. ui.addTextArea(102, "<P align='center'>"..COLOR.."<font size='20'><b>Швиндовс</B></P><font size='13'>Обновление было произведенно успешно</font><BR><BR><font size='15'><a href='event:iniciar'>Назад</a>", nil, 179, 75, 455, 208, 1, 1, 0.3);
  218. atualizar = false
  219. n = 0
  220. end
  221.  
  222. if hora == true then
  223. tempo = os.date("Hoje é %A, de %B")
  224. ui.addTextArea(102, "<P align='center'>"..COLOR.."<font size='20'><b>Швиндовс</B></P><font size='13'>Время</font><BR><BR><font size='17'>"..tempo.."<BR><BR><font size='15'><a href='event:iniciar'>Назад</a>", nil, 179, 75, 455, 208, 1, 1, 0.3);
  225. end
  226.  
  227. if efeitos == true then
  228. for i=20,1,-1 do
  229. tfm.exec.displayParticle(math.random(0, 30), math.random(200,600), math.random(100,290),0,0,0,0,nil)
  230. end
  231. end
  232. end
  233.  
  234.  
  235. function eventChatCommand(playerName, message)
  236. if (message:sub(0,1) == [[m]]) then
  237. table.insert(messeger,1,messeger[1].."<b>["..playerName.."]</b> "..message:sub(3).."<BR>")
  238. end
  239. if msn == true then
  240. ui.addTextArea(102, "<P align='center'>"..COLOR.."<font size='20'><b>Швиндовс</B></P><font size='13'>Discord</font><BR><BR><p aling='left'><font size='10'>"..messeger[1].."<BR><a href='event:iniciar'>Назад</a>", nil, 179, 75, 455, 208, 1, 1, 0.3);
  241. end
  242. if (message=="clear") then
  243. for i = 5000,1,-1 do
  244. table.remove(messeger,1)
  245. table.insert(messeger,1,"")
  246. end
  247. end
  248. end
  249.  
  250. guiColor()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement