Advertisement
Guest User

Untitled

a guest
May 25th, 2016
53
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.21 KB | None | 0 0
  1. local info = [[
  2. Name: Auto Area Attack
  3. Description: Executes area spells on certain conditions
  4. Author: Cavitt Glover (Syntax)
  5. Version: 2.1.00 (updated 04.25.2012)]]
  6.  
  7. local config = {
  8. attacks = {
  9. --[[
  10. spells should be prioritized from top to bott om, eg: exori gran will be attempted before exori or exori mas.
  11.  
  12. players:
  13. true = the area will include players in the threshold
  14. false = the area will only count the monsters in the area
  15.  
  16. aggressive:
  17. 0 = attack triggers when no players are in the area.
  18. 1 = attack triggers when only war enemies and skulled players, noone else.
  19. 2 = attack triggers when innocents are in the area but not when friendlies are.
  20. 3 = attack triggers when friendlies are in the area but not when innocents are.
  21. 4 = attack triggers without any regards to players in the area.
  22. ]]
  23. {words="exori", threshold=2, mana=400, radius=1, aggressive=0, players=false}
  24. }
  25. }
  26.  
  27. local function think()
  28. for _, info in ipairs(config.attacks)do
  29. local amount = getTargetsInArea(Self.Position(), info.radius, info.aggressive, info.players)
  30. if(amount)then
  31. if(amount >= info.threshold)then
  32. Self.Cast(info.words, info.mana)
  33. end
  34. end
  35. end
  36. end
  37.  
  38. print(info)
  39. wait(300)
  40. while (true) do
  41. think()
  42. wait(200)
  43. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement