forked from Pickonme/BoL_Scripts
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathEnemyRange.lua
More file actions
24 lines (19 loc) · 737 Bytes
/
Copy pathEnemyRange.lua
File metadata and controls
24 lines (19 loc) · 737 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
--[[ Shows the enemy range; Fix by Trus ]]--
function OnLoad()
Config = scriptConfig("Enemy Range","EnemyRange")
Config:addParam("drawAllys", "Draw Allys", SCRIPT_PARAM_ONOFF, true)
print("Enemy Range loaded")
end
function OnDraw()
for i, unit in pairs(GetEnemyHeroes()) do
if myHero.range + 500 >= GetDistance(unit) and not unit.dead then
DrawCircle(unit.x, unit.y, unit.z, unit.range + GetDistance(unit.minBBox, unit.maxBBox), 0xFFFFFF00)
end
end
if not Config.drawAllys then return end
for i, unit in pairs(GetAllyHeroes()) do
if myHero.range + 500 >= GetDistance(unit) and not unit.dead then
DrawCircle(unit.x, unit.y, unit.z, unit.range + GetDistance(unit.minBBox, unit.maxBBox), 0xFFFFFF00)
end
end
end