Advertisement
Dudugz-Contistente

Untitled

Nov 12th, 2016
76
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.45 KB | None | 0 0
  1. admin=""
  2. mapas = {6930458}
  3. p = {}
  4.  
  5. tfm.exec.disableAutoNewGame(true)
  6. tfm.exec.disableAutoShaman(true)
  7. tfm.exec.disableAutoTimeLeft(true)
  8. tfm.exec.disableAfkDeath(true)
  9.  
  10. function eventNewPlayer(name)
  11. p[name]={
  12. click = true,
  13. time_click = 0,
  14. }
  15. end
  16.  
  17. for all in pairs(tfm.get.room.playerList) do
  18. eventNewPlayer(all)
  19. end
  20.  
  21. function eventMouse(name,x,y)
  22. if p[name].click then
  23. tfm.exec.explosion (x, y, 20, 100, true)
  24. tfm.exec.displayParticle(12,x,t)
  25. p[name].click = false
  26. p[name].time_click = 20
  27. end
  28. end
  29.  
  30. function eventLoop()
  31. if not p[admin].click then
  32. if p[admin].time_click > 0 then
  33. ui.addTextArea(0,"<b><p align='center'><VP><font size='15'>"..math.floor(p[admin].time_click/2).."</font></p>",nil,5,370,790,25,nil,nil,80,true)
  34. p[admin].time_click = p[admin].time_click-1;
  35. else
  36. p[admin].click = true
  37. ui.removeTextArea(0,nil)
  38. end
  39. end
  40. end
  41.  
  42. function eventPlayerDied(name)
  43. if vivos > 1 then
  44. vivos = vivos-1;
  45. else
  46. for i in pairs(tfm.get.room.playerList) do
  47. if not tfm.get.room.playerList[i].isDead then
  48. tfm.exec.giveCheese(I)
  49. tfm.exec.playerVictory(i)
  50. end
  51. end
  52.  
  53. tfm.exec.newGame(mapas[math.random(#mapas)])
  54. end
  55. end
  56.  
  57. function eventNewGame()
  58. tfm.exec.killPlayer(admin)
  59.  
  60. vivos = 0
  61.  
  62. for i in pairs(tfm.get.room.playerList) do
  63. vivos=vivos+1;
  64. end
  65. end
  66.  
  67. system.bindMouse(admin,true)
  68. tfm.exec.setUIMapName("Power of the sprit")
  69. tfm.exec.newGame(mapas[math.random(#mapas)])
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement