grantygames

Untitled

Nov 1st, 2015
156
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.40 KB | None | 0 0
  1. options:
  2. PREFIX: &9[VillagerCMD]
  3.  
  4. command /villager [<text>] [<text>]:
  5. permission: tearpvp.villager
  6. permission message: &cVoce nao tem a permissao &4'tearpvp.villager'&c.
  7. trigger:
  8. if arg 2 is not set:
  9. send "{@PREFIX} &cUso: /villager [nomedovillager] [comando]."
  10. stop
  11. else:
  12. spawn a villager at location of player
  13. apply slowness 100 to spawned villager for 999 days
  14. set name of spawned villager to colored arg 1
  15. set {villager::%name of spawned villager%} to arg 2
  16. set {villagerlocal::%name of spawned villager%} to location of player
  17. send "{@PREFIX} &eVoce criou um aldeao com o comando &6%arg 2%&e."
  18. while {villager::%name of spawned villager%} is set:
  19. teleport spawned villager to {villagerlocal::%name of spawned villager%}
  20. wait 8 seconds
  21.  
  22. command /delvillager:
  23. permission: deltearpvp.villager
  24. permission message: &cVoce nao tem a permissao &4'tearpvp.delvillager'&c.
  25. trigger:
  26. loop all entities in radius 2 around player:
  27. if loop-entity is a villager:
  28. clear loop-entity
  29. clear {villager::%loop-entity%}
  30. clear {villagerlocal::%loop-entity%}
  31. send "{@PREFIX} &eVoce deletou o aldeao &6%loop-entity%&e."
  32.  
  33. on damage:
  34. if {villager::%victim%} is set:
  35. cancel event
  36. teleport victim to {villagerlocal::%victim%}
  37.  
  38. on rightclick on a villager:
  39. make player execute command "%{villager::%name of clicked entity%}%"
  40. cancel event
Advertisement
Add Comment
Please, Sign In to add comment