Play Home Contribute GitHub Join Us Discourse Staff Members GitHub Contribution Guides Team

Problem with completing mission "Airdrop"


Hello,I have problem, in mission Airdrop i don’t know how to complete this level.
This is my code:

def onSpawn (event):
while True:
item = hero.findNearestItem()
if item:

while True:
enemy = hero.findNearestEnemy()
if enemy:

How to use pets, I have never done it before.
Can you help?Thank you.


remove the pet.moveXY(). Under Pet.fetch(item) and above while True:, type down pet.on("spawn", onSpawn)


@Seojin_Roy_Lee Don’t just give out the answer. Make sure you add an explanation why so @Vayne1 can also grasp the concept