Hey. I am having a struggle on a level called “Sarven Sentry.” The goal is to fence out the yaks, but to kill the ogres. Here is my code.
loop: flagGreen = self.findflag("green") flagBlack = self.findflag("black") if flag: if flagGreen: self.pickUpFlag() self.buildXY("fence", flagGreen.pos.x, flagGreen.pos.y) if flagBlack: self.pickUpFlag() self.buildXY("fence", flagBlack.pos.x, flagBlack.pos.y) else: self.moveXY(43, 31)
The things I noticed is that my hero is not moving anywhere. I also did not see any error when I typed this code. Can you help me on this?