I think I’ve got the right code, but the ogres just seem to be too much. Is there anything I could do that might help? Here is code:
def command():
friends = hero.findFriends()
for friend in friends:
if friend.type == 'soldier':
enemy = friend.findNearestEnemy()
if enemy:
hero.command(friend, "attack", enemy)
def summon():
item = hero.findNearestItem()
if hero.gold > 20:
hero.summon("soldier")
elif item:
hero.move(item.pos)
def attack():
enemy = hero.findNearestEnemy()
if enemy and hero.distanceTo(enemy) < 10:
hero.attack(enemy)
if enemy and hero.canCast("chain-lightning", enemy):
hero.cast("chain-lightning", enemy)
while True:
attack()
command()
summon()
I’ve also got the strongest armour, sword, glasses, and my hero is Tharin. Thanks