Advertisement
Guest User

Untitled

a guest
Jul 12th, 2014
202
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. init start
  2. -- local SCRIPT_VERSION = '1.0.0'
  3.  
  4. -- The message to be said. If you write ':attacker:' it will be replaced
  5. -- with the current attacker's name. It is recommended that you have this
  6. -- message assigned to one of your hotkeys, as otherwise it might interfere
  7. -- with the healing and get you killed. This is not doable when using the
  8. -- ':attacker:' placeholder though, unless you're using Wind Addon's fast
  9. -- hotkeys. It's also recommended that you keep this string in all lower
  10. -- case, if you're not having it assigned to a hotkey or not having Wind
  11. -- Addon's enabled.
  12. local message = "pk :attacker: at coryms"
  13.  
  14. -- The name of your guild, so that the bot knows which channel to send the
  15. -- message to. THIS HAS TO BE ALREADY OPENED OR OTHERWISE THE SCRIPT WON'T
  16. -- WORK AT ALL.
  17. local guildChat = "Guild Name"
  18.  
  19. -- The interval between messages, in ms; this is to prevent repeatedly
  20. -- spamming the same message and getting you muted.
  21. local interval = 30000
  22.  
  23. -- DO NOT EDIT BELOW THIS LINE --
  24.  
  25. local lastMessage = 0
  26. init end
  27.  
  28. auto(100)
  29.  
  30. if $pattacker.id ~= 0 and $timems - lastMessage > interval then
  31. local realMessage = message:gsub(":attacker:", $pattacker.name:lower())
  32.  
  33. say(guildChat, realMessage)
  34.  
  35. if waitmessage($name, realMessage, 2000, false, guildChat) then
  36. lastMessage = $timems
  37. end
  38. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement