Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --[[
- Gangplank Q Autohitter + Enemy Harass
- Version 1.1 by Wursti
- History:
- 1.0 - First Version
- 1.01 - Fixed Small Bug Q Damage
- 1.1 - Integration of Circle Range Q and Sheen, Trinity and Lich Bane Support
- ]]--
- --[[Hotkeys]]--
- local HK = 84
- local CHK = 32
- local circ = true
- --[[ Code ]]--
- local myObjectsTable = {}
- local player = GetMyHero()
- local scriptActive = false
- local CscriptActive = false
- local ResetscriptActive = false
- local Sheen = false
- local Lich = false
- local Trini = false
- local mydmg,Qdmg,Sdmg,Ldmg,Tdmg,Bdmg = 0,0,0,0,0,0
- function OnLoad()
- ts = TargetSelector(TARGET_LOW_HP, 625, DAMAGE_PHYSICAL)
- for i = 0, objManager.maxObjects, 1 do
- local object = objManager:GetObject(i)
- if minionValid(object) then table.insert(myObjectsTable, object) end
- end
- end
- if player.charName == "Gangplank" then
- PrintChat(" Gang Makin Money Script + Harass!")
- function OnWndMsg(msg,key)
- if key == HK then
- if msg == KEY_DOWN then
- if scriptActive then
- scriptActive = false
- PrintChat("Auto Q Enemies Disabled")
- else
- scriptActive = true
- PrintChat("Auto Q Enemies Enabled")
- end
- end
- elseif key == CHK then
- if msg == KEY_DOWN and CscriptActive == false then
- ResetscriptActive = scriptActive
- CscriptActive = true
- elseif msg == KEY_DOWN then
- CscriptActive = true
- scriptActive = false
- else
- CscriptActive = false
- scriptActive = ResetscriptActive
- end
- end
- end
- function minionValid(object)
- return object ~= nil and object.valid and string.find(object.name,"Minion_") == 1 and object.team ~= player.team and object.dead == false
- end
- function OnCreateObj(object)
- if minionValid(object) then table.insert(myObjectsTable, object) end
- end
- function OnTick()
- ts:update()
- Sheen, Trini, Lich = GetInventorySlotItem(3057), GetInventorySlotItem(3078), GetInventorySlotItem(3100)
- if scriptActive == true then
- if myHero:GetSpellData(_Q).level > 0 and myHero:CanUseSpell(_Q) == READY then
- for i,minion in ipairs(myObjectsTable) do
- if minionValid(minion) then
- local Qdmg = getDmg("Q",minion,myHero)
- PrintChat(Qdmg)
- local Bdmg = getDmg("AD",minion,myHero)
- local Sdmg = (Sheen and Bdmg or 0)
- local Tdmg = (Trini and 1.5 * Bdmg or 0)
- local Ldmg = (Lich and getDmg("LICHBANE",minion,myHero) or 0)
- mydmg = Qdmg + Sdmg + Tdmg + Ldmg
- if minion.health <= mydmg and GetDistance(minion,myHero) < 625 then
- PrintChat("dmg:" ..mydmg )
- PrintChat("dmg:" ..Sdmg )
- CastSpell(_Q,minion)
- end
- else table.remove(myObjectsTable, i) i = i - 1
- end
- end
- end
- elseif CscriptActive == true then
- if myHero:GetSpellData(_Q).level > 0 and myHero:CanUseSpell(_Q) == READY then
- if ts.target ~= nil and myHero:CanUseSpell(_Q) == READY and myHero:GetDistance(ts.target) < 625 then
- CastSpell(_Q, ts.target)
- end
- end
- end
- end
- function OnSendChat(msg)
- TargetSelector__OnSendChat(msg)
- ts:OnSendChat(msg, "pri")
- end
- function OnDraw()
- if circ == true then
- DrawCircle(player.x,player.y,player.z,625,0xFF80FF00)
- end
- if CscriptActive == true then
- DrawText("Champion Hunt", 20, 120, 40, 0xFFfff600)
- end
- if scriptActive == true then
- DrawText("Minion Hunt", 20, 120, 60, 0xFFfff600)
- end
- end
- else
- PrintChat(" No Gang no Money!")
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement