Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

2 mistakes in level description fixed #41

Closed
wants to merge 1 commit into from

2 participants

@senk

Fixed the irritating mistake in README file for beginner/level2. changed 2 times from ".empty?" to ".enemy?"

@gbataille

I would argue that for level 2, this is good enough. If there is something, smash it, otherwise, move along.
It gets more tricky when the captives get introduced later and you have to know what occupies the tile.
Now it's true that enemy? does not get introduced anywhere else, but it seems to be equivalent to !empty? and captive?

Anyway, looks mostly like a matter of taste :)
I'll keep my empty? implementation for now on my side.

@senk

But then we should correct the incoherence with the README.rdoc at "Here is a simple example which will instruct the warrior to attack if he feels an enemy, otherwise he will walk forward."

@gbataille

ok right, works for me :)

@senk senk closed this
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Dec 21, 2011
  1. @senk
This page is out of date. Refresh to see the latest.
Showing with 2 additions and 2 deletions.
  1. +2 −2 towers/beginner/level_002.rb
View
4 towers/beginner/level_002.rb
@@ -3,8 +3,8 @@
# --------
description "It is too dark to see anything, but you smell sludge nearby."
-tip "Use warrior.feel.empty? to see if there's anything in front of you, and warrior.attack! to fight it. Remember, you can only do one action (ending in !) per turn."
-clue "Add an if/else condition using warrior.feel.empty? to decide whether to warrior.attack! or warrior.walk!."
+tip "Use warrior.feel.enemy? to see if there's anything in front of you, and warrior.attack! to fight it. Remember, you can only do one action (ending in !) per turn."
+clue "Add an if/else condition using warrior.feel.enemy? to decide whether to warrior.attack! or warrior.walk!."
time_bonus 20
ace_score 26
Something went wrong with that request. Please try again.