Advertisement
Koelion

Malph

May 12th, 2013
253
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 6.63 KB | None | 0 0
  1. if myHero.charName ~= "Malphite" then return end
  2.  
  3. local kill = {}
  4. local range = 1000
  5. local TIASlot = nil
  6. local TIAREADY = false
  7. local SWSlot = nil
  8. local SWREADY = false
  9. local rDelay = 1000
  10. local rRange = 1000
  11. local ts = TargetSelector(TARGET_LOW_HP,range,false)
  12.  
  13.  
  14. function OnLoad()
  15. acConfig = scriptConfig("UnlimitedMalphite", "Combo")
  16. acConfig:addParam("scriptActive", "Combo", SCRIPT_PARAM_ONKEYDOWN, false, 32)
  17. acConfig:addParam("drawcircles", "Draw Circles", SCRIPT_PARAM_ONOFF, true)
  18. acConfig:addParam("ks","KillSteal", SCRIPT_PARAM_ONOFF,true)
  19. acConfig:addParam("ulti","Ulti in Combo", SCRIPT_PARAM_ONOFF,true)
  20. acConfig:permaShow("scriptActive")
  21. ts.name = "Malphite"
  22. acConfig:addTS(ts)
  23. end
  24.  
  25.  
  26.  
  27. function OnTick()
  28. ts:update()
  29. Damage()
  30. TIASlot = GetInventorySlotItem(3077) or GetInventorySlotItem(3074)
  31. TIAREADY = (TIASlot ~= nil and myHero:CanUseSpell(TIASlot) == READY)
  32. SWSlot = GetInventorySlotItem(3131)
  33. SWREADY = (SWSlot ~= nil and myHero:CanUseSpell(SWSlot) == READY)
  34. for i=1, heroManager.iCount do
  35. local target = heroManager:GetHero(i)
  36. local eDmg = getDmg("E",target,myHero)
  37. if target ~= nil and target.visible == true and player.team ~= target.team and target.dead == false then
  38.  
  39. if player:CanUseSpell(_E) == READY and player:GetDistance(target) < 400 and eDmg > target.health then
  40. CastSpell(_E,target)
  41. end
  42. end
  43. end
  44. if acConfig.scriptActive then
  45. if ts.target~= nil and myHero:GetDistance(ts.target)<400 then
  46. if TIAREADY then
  47. CastSpell(TIASlot)
  48. end
  49. if SWREADY then
  50. CastSpell(SWSlot)
  51. end
  52. end
  53. if myHero:CanUseSpell(_W) then
  54. CastSpell(_W)
  55. end
  56. if myHero:CanUseSpell(_R) and ts.target ~= nil and acConfig.ulti then
  57. if GetDistance(ts.target) <= rRange then
  58. RPOS = GetPredictionPos(ts.target, rDelay)
  59. if RPOS ~= nil and ValidTarget(ts.target, rRange) then
  60. CastSpell(_R,RPOS.x,RPOS.z)
  61. end
  62. end
  63. end
  64.  
  65. if myHero:CanUseSpell(_E) == READY then
  66. if ts.target ~= nil and myHero:GetDistance(ts.target) < 400 then
  67. CastSpell(_E)
  68. end
  69. end
  70. if ts.target ~= nil then
  71. myHero:Attack(ts.target)
  72. end
  73. if ts.target ~= nil and myHero:CanUseSpell(_Q) then
  74. if myHero:GetDistance(ts.target) < 625 then
  75. CastSpell(_Q,ts.target)
  76. end
  77. end
  78. end
  79. if acConfig.ks then
  80. for i=1, heroManager.iCount do
  81. target = heroManager:GetHero(i)
  82. local edmg = getDmg("E",target,myHero)
  83. if target.team ~= myHero.team and target.dead == FALSE and target.visible == TRUE and myHero:GetDistance(target) < 400 and myHero:CanUseSpell(_E) == READY and target.health < edmg then
  84. CastSpell(_E)
  85. end
  86. end
  87. end
  88. end
  89. function Damage()
  90. ts:update()
  91. for i=1, heroManager.iCount do
  92. local enemy = heroManager:GetHero(i)
  93. local qdmg = getDmg("Q",enemy,myHero)
  94. local wdmg = player:CalcDamage(enemy,player.totalDamage *(1 + (20+(player:GetSpellData(_W).level * 5))/100))
  95. local edmg = getDmg("E",enemy,myHero)
  96. local rdmg = getDmg("R",enemy,myHero)
  97.  
  98. local possible = qdmg + wdmg*2 + edmg + rdmg
  99. local thatkill = 0
  100.  
  101. if myHero:CanUseSpell(_Q) == READY then
  102. thatkill = thatkill + qdmg
  103. end
  104. if myHero:CanUseSpell(_W) == READY then
  105. thatkill = thatkill + wdmg*2
  106. end
  107. if myHero:CanUseSpell(_E) == READY then
  108. thatkill = thatkill + edmg
  109. end
  110. if myHero:CanUseSpell(_R) == READY then
  111. thatkill = thatkill + rdmg
  112. end
  113.  
  114.  
  115. if thatkill >= enemy.health then
  116. kill[i] = 2
  117. elseif possible>= enemy.health then
  118. kill[i] = 1
  119. else
  120. kill[i] = 0
  121. end
  122.  
  123. end
  124. end
  125.  
  126.  
  127. function OnDraw()
  128. local coloraqua=ARGB(0xFF,0x00,0xFF,0xFF)
  129. if acConfig.drawcircles then
  130. DrawCircle(myHero.x,myHero.y,myHero.z,range,coloraqua)
  131. DrawCircle(myHero.x,myHero.y,myHero.z,400,0xFFFF0000)
  132. DrawCircle(myHero.x,myHero.y,myHero.z,625,0xFFFF0000)
  133. if acConfig.scriptActive then
  134. DrawText("Script Active",18,100,80,0xFF80FF00)
  135. end
  136. if ts.target ~= nil then
  137. DrawText("Targetting: " .. ts.target.charName, 18, 100, 100, 0xFFFF0000)
  138. DrawCircle(ts.target.x, ts.target.y, ts.target.z, 100, 0xFF80FF00)
  139. end
  140. for i=1, heroManager.iCount do
  141. local enemydraw = heroManager:GetHero(i)
  142. if ValidTarget(enemydraw) then
  143. if kill[i] == 1 then
  144. PrintFloatText(enemydraw,0,"Cooldown")
  145. DrawCircle(enemydraw.x,enemydraw.y,enemydraw.z, 100, 0xFF80FF00)
  146. DrawCircle(enemydraw.x,enemydraw.y,enemydraw.z, 150, 0xFF80FF00)
  147. elseif kill[i] == 2 then
  148. PrintFloatText(enemydraw,0,"MURDER!")
  149. DrawCircle(enemydraw.x,enemydraw.y,enemydraw.z, 100, 0xFF80FF00)
  150. DrawCircle(enemydraw.x,enemydraw.y,enemydraw.z, 150, 0xFF80FF00)
  151. DrawCircle(enemydraw.x,enemydraw.y,enemydraw.z, 200, 0xFF80FF00)
  152. end
  153. end
  154. end
  155.  
  156. end
  157. end
  158.  
  159.  
  160. PrintChat(" >> UnlimitedMalphite Loaded!")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement