killdeer' 作戦

Show them a weakness and their bloodlust will blind them.
それらに弱さを示しなさい。それらの流血への欲求はそれらを盲目にする。

目標

オーガ達を倒す。

That is a big band of ogres!
Use a function with a boolean return value to check if the hero should retreat.
Fight until shouldRun() returns TRUE, then run!
それは怪物の大きいバンドである!
ヒーローが退却するべきであるかどうかをチェックするために、ブーリアンリターン価値によって機能を用いなさい。
戦い まで shouldRun()リターンTRUE 、そして走りなさい!

ヒント

Lure the ogres into a trap. These ogres are careful.
わなに怪物をおびき出しなさい。これらの怪物は慎重である。
ヒ-ロ-が怪我をしていなければ付いてこない

解答

a
def shouldRun():
  if hero.health < hero.maxHealth / 2:
    return True
  else:
    return False
while True:
  if shouldRun():
    hero.moveXY(75, 37)
  else:
    enemy = hero.findNearestEnemy()
    hero.attack(enemy)
a

  • 最終更新:2017-05-11 00:47:11

このWIKIを編集するにはパスワード入力が必要です

認証パスワード