Hardened Steel Glasses

Good evening,

I would like to know more about the use of Hardened Steel Glasses,

I’m trying to follow my friends in “Siege of StoneHold”

However, i’m not sure that I understand how it works, from “friends” to friend

My code is here, almost working

 # You'll need great equipment and strategy to win.
 self.moveXY(45, 31)

 loop:
     enemies = self.findEnemies()
     friends = self.findFriends()
     flag = self.findFlag()
     # If there is an enemy, attack it!
     if flag:
         flagpos = flag.pos
         fx = flagpos.x
         fy = flagpos.y
         self.moveXY(fx, fy)
         self.pickUpFlag(flag)
                
     if enemies:
         for enemy in enemies:
             if enemy > 1:
                     distance = self.distanceTo(enemy,self.pos)
                 if distance < 4:
                     if self.isReady("cleave"):
                         self.cleave(enemy)
                     elif enemy and distance < 3:
                         self.bash(enemy)
                 else:
                     self.attack(enemy)
             elif enemy < 1:
                 self.moveXY(79, 69)

Thank you for your kind collaboration

You can do nearestFriend = self.findNearest(self.findFriends()) to get the nearest friend. Anything else and you’ll have to loop over the friends array to find the one(s) you want.

Thank you ver much for your kind collaboration