Can anyone help explain why my character just moves to the red x and then never attacks the enemy or grabs any coins. I have also made up some more complex code using the distanceTO function and using logic of distanceToItem vs distanceToEnemy but that didn’t work either.
Be the first to 100 gold!
If you are defeated, you will respawn at 67% gold.
enemy = hero.findNearestEnemy()
item = hero.findNearestItem()
flag = hero.findFlag()
# Find coins and/or attack the enemy.
# Use flags and your special moves to win!