Advertisement
Guest User

script1

a guest
May 29th, 2015
90
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.69 KB | None | 0 0
  1. raton = {}
  2. chamanes = 0
  3.  
  4. function eventNewPlayer(n)
  5. if not raton[n] then
  6. raton[n] = {
  7. chaman = 0
  8. }
  9. end
  10. end
  11.  
  12. for name in pairs(tfm.get.room.playerList) do
  13. eventNewPlayer(name)
  14. end
  15.  
  16. function isShaman(name)
  17. if tfm.get.room.playerList[name].isShaman==true then
  18. chamanes = chamanes + 1
  19. raton[name].chaman = raton[name].chaman + 1
  20. if chamanes==1 then
  21. print("<CH>El chamán actual ("..name..") ha sido chamán "..raton[name].chaman.." veces.")
  22. end
  23. if chamanes==2 then
  24. print("<rose>El chamán actual ("..name..") ha sido chamán "..raton[name].chaman.." veces.")
  25. end
  26. end
  27. end
  28.  
  29. function eventNewGame()
  30. chamanes = 0
  31. for name in pairs(tfm.get.room.playerList) do
  32. isShaman(name)
  33. end
  34. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement