Hola estoy teniendo problemas en este nivel, no comprendo correctamente el procedimiento que debo seguir.
Todas las pistas las tengo en ingles y no puedo copiar el texto para poder traducirlas aparte
Dejo lo que he agregado al código y captura de pantalla:
# Munchkins are attacking!
# The swarms will come at regular intervals.
# Whenever you can, cleave to clear the mass of enemies.
while True:
enemy = hero.findNearestEnemy()
# Use an if-statement with isReady to check "cleave":
if hero.isReady("cleave"):
# Cleave!
hero.attack(enemy)
# Else, if cleave is not ready:
else:
hero.moveXY(50, 10)
# Attack the nearest ogre!
gracias @Seojin_Roy_Lee ahora si pude resolverlo use antes cleave pero no vivia el tiempo necesario y probe cambiando la ubicación del movimiento.
Pude solucionarlo con tu ayuda
# Munchkins are attacking!
# The swarms will come at regular intervals.
# Whenever you can, cleave to clear the mass of enemies.
while True:
enemy = hero.findNearestEnemy()
# Use an if-statement with isReady to check "cleave":
if hero.isReady("cleave"):
# Cleave!
hero.cleave(enemy)
hero.moveXY(40, 30)
# Else, if cleave is not ready:
else:
hero.attack(enemy)
# Attack the nearest ogre!
hero.attack(enemy)
por el momento no lo comprendo bien y creo que es lo que me falta para poder solucionar el nivel 10 estoy parado ahi no comprendo correctamente, abrire un nuevo tema para ese nivel (Python) Bosque Aislado 10/120