def findEnemyHero():
for enemy in hero.findEnemies():
if enemy.id == "Hero Placeholder 1":
return enemy
def onSpawn():
while True:
eh = findEnemyHero()
if eh:
pet.moveXY(eh.pos.x, eh.pos.y)
pet.shapeShift()
pet.on("spawn", onSpawn)
goal = hero.pos
while True:
enemy = hero.findNearestEnemy()
if hero.isReady("backstab"):
if hero.isReady("hide"):
hero.hide()
continue
elif hero.isReady("invisibility") and not hero.hasEffect("hide"):
hero.cast("invisibility", hero)
continue
if enemy:
eh = findEnemyHero()
if eh:
hero.backstab(eh)
if enemy:
hero.scattershot(enemy)
goal = Vector.subtract(goalPoint, hero.pos)
goal = Vector.normalize(goal)
goal = Vector.multiply(goal, 10)
yak = hero.findNearestEnemy()
if yak:
distance = hero.distanceTo(yak)
if distance < 10:
yak_vector = Vector.subtract(hero.pos, yak.pos)
yak_vector = Vector.normalize(yak_vector)
yak_vector = Vector.multiply(yak_vector, 10)
goal = Vector.add(yak_vector, goal)
moveToPos = Vector.add(hero.pos, goal)
hero.move(moveToPos)
Then why riticmaster said âuse a list of pointsâ
Thatâs the problem in arena.
1 Like
Because he uses ritic and the list of points is useful and easy for the blink() ability.
1 Like
OK, then what is this
A function for people who donât ask too many questions
Like me? lol
(i asked too many questions lol)
This topic was automatically closed 12 hours after the last reply. New replies are no longer allowed.