I need help in this level whenever i put this code only my hero would movie not my pet wolf
while True:
item = hero.findNearestItem()
if item:
# If item.type IS NOT EQUAL TO "gem"
# Then follow your pet wolf.
hero.moveXY(pet.pos.x, pet.pos.y)
# Else:
else:
if item == “gem”:
# Move to the gem’s position.
hero.moveXY(item.pos.x, item.pos.y)