Got the 20 coins total and it stuck


#1


#2

It might be a bug, but you are also supposed to move to the flag before picking it up with hero.moveXY(x, y) by inputting the flag’s coordinates, but you might have a bad seed.


#3

There’s nothing wrong with the code. It is correct and runs fine. Are you sure that you’re clicking on the Submit button and not Run? In order to use flags you have to use Submit.

Try it again. Maybe you just had a bad seed.


#4

By the way, pickUpFlag moves you to the flag so you can pick it up. You will eventually get remove with advanced flags so you can remove them without moving to them, but that’s different.


#5

But still, he is supposed to have

flag = hero.findNearestFlag("green")

over there, in order for him to use the flags, but he can just use the green flag.


#6

I agree @I_can_rob_you,