Advertisement
Guest User

Untitled

a guest
Dec 7th, 2016
68
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.27 KB | None | 0 0
  1. local targets = {}
  2.  
  3. targets[#targets + 1] = { name = "Nakuu", hp = 80, spell = "exura gran" }
  4.  
  5. targets[#targets + 1] = { name = "Nakux", hp = 80 }
  6.  
  7.  
  8.  
  9. Module("ssSio", function(module)
  10.  
  11. for k,v in ipairs(targets) do
  12.  
  13. local player = Creature(v.name)
  14.  
  15. if player:isOnScreen(false) and (player:HealthPercent() <= v.hp) then
  16.  
  17. if Self.CanCastSpell("exura") and (Self.Mana() > 100) then
  18.  
  19. if (v.spell) and (v.name == Self.Name()) then
  20.  
  21. Self.Cast(v.spell)
  22.  
  23. else
  24.  
  25. Self.Cast("exura sio \"" .. v.name)
  26.  
  27. end
  28.  
  29. end
  30.  
  31. end
  32.  
  33. end
  34.  
  35. end, false)
  36.  
  37.  
  38.  
  39. function onSpeak(chat, msg)
  40.  
  41. chat:SendYellowMessage(Self.Name(), msg)
  42.  
  43. if (msg == "start") then
  44.  
  45. Module("ssSio"):Start()
  46.  
  47. chat:SendOrangeMessage("ssSio", "ssSio has started.")
  48.  
  49. elseif (msg == "stop") then
  50.  
  51. Module("ssSio"):Stop()
  52.  
  53. chat:SendOrangeMessage("ssSio", "ssSio has stopped.")
  54.  
  55. else
  56.  
  57. targets[#targets + 1] = { name = msg, hp = 80 }
  58.  
  59. chat:SendOrangeMessage("ssSio", "Added " .. msg .. " to the healing list.")
  60.  
  61. end
  62.  
  63. end
  64.  
  65.  
  66.  
  67. function onClose() end
  68.  
  69.  
  70.  
  71. local chat = Channel("ssSio", onSpeak, onClose)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement