Advertisement
Guest User

Untitled

a guest
Oct 13th, 2017
79
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.09 KB | None | 0 0
  1. quest evento_pvm begin
  2. state start begin
  3. when 20095.chat."Evento PvM" with pc.get_map_index() == 1 or pc.get_map_index() == 21 or pc.get_map_index() == 41 begin
  4. say_title("Nohe o Imortal")
  5. say("")
  6. if game.get_event_flag("evento_blazing2") == 0 and not pc.is_gm() then
  7. say("Os portões para a entrada no Evento")
  8. say("PvM estão fechados no momento!")
  9. else
  10. say("Deseja entrar no Evento PvM?")
  11. local main_set =select ("Sim","Não")
  12. if main_set == 1 then
  13. pc.warp (83200 , 0)
  14. elseif main_set == 2 then
  15. return
  16. end
  17. end
  18. end
  19.  
  20. when 20095.chat."GM: Evento PvM" with pc.is_gm() and pc.get_map_index() == 200 and game.get_event_flag("evento_pvm") == 0 begin
  21. say_title("Nohe o Imortal")
  22. say("")
  23. say("Deseja ativar o Evento PvM?")
  24. local menu = select ("Sim", "Não")
  25. if menu == 1 then
  26. game.set_event_flag("evento_pvm", 1)
  27. game.set_event_flag("desativar_pvp_map", 1)
  28. server_timer( "finalizar_evento_pvm", 15*60, get_server_timer_arg())
  29. server_loop_timer("anuncio_evento_pvm", 305)
  30. notice_all("O Evento PvM Começou!!!")
  31. notice_all("Participe através do Nohe o Imortal.")
  32. kill_all_in_map(200)
  33. regen_in_map(200, "data/eventos/evento_pvm.txt")
  34. elseif menu == 2 then
  35. return
  36. end -- if
  37. end -- when
  38.  
  39. when anuncio_evento_pvm.server_timer begin
  40. notice_all("O Evento PvM está em andamento!")
  41. notice_all("Participe através do Nohe o Imortal.")
  42. end
  43.  
  44. when finalizar_evento_pvm.server_timer begin
  45. clear_server_timer("finalizar_evento_pvm")
  46. clear_server_timer("anuncio_evento_pvm")
  47. game.set_event_flag("evento_pvm", 0)
  48. game.set_event_flag("desativar_pvp_map", 0)
  49. notice_all("O Evento PvM Terminou!")
  50. notice_all("Obrigado pela participação de todos!")
  51. warp_all_to_village(200, 10) -- em 10 segundos manda todos para vila.
  52. end -- when
  53.  
  54. when login with not pc.is_gm() and pc.get_map_index() == 200 begin
  55. if game.get_event_flag("evento_pvm") == 0 then -- DESLIGADO
  56. warp_to_village()
  57. end -- if
  58. end -- when
  59. end -- state
  60. end -- quest
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement