diff --git a/agents4e.py b/agents4e.py index 75369a69a..dde45e4c3 100644 --- a/agents4e.py +++ b/agents4e.py @@ -875,10 +875,10 @@ def __init__(self, agent_program, width=6, height=6): def init_world(self, program): """Spawn items in the world based on probabilities from the book""" - "WALLS" + # WALLS self.add_walls() - "PITS" + # PITS for x in range(self.x_start, self.x_end): for y in range(self.y_start, self.y_end): if random.random() < self.pit_probability: @@ -888,7 +888,7 @@ def init_world(self, program): self.add_thing(Breeze(), (x + 1, y), True) self.add_thing(Breeze(), (x, y + 1), True) - "WUMPUS" + # WUMPUS w_x, w_y = self.random_location_inbounds(exclude=(1, 1)) self.add_thing(Wumpus(lambda x: ""), (w_x, w_y), True) self.add_thing(Stench(), (w_x - 1, w_y), True) @@ -896,10 +896,10 @@ def init_world(self, program): self.add_thing(Stench(), (w_x, w_y - 1), True) self.add_thing(Stench(), (w_x, w_y + 1), True) - "GOLD" + # GOLD self.add_thing(Gold(), self.random_location_inbounds(exclude=(1, 1)), True) - "AGENT" + # AGENT self.add_thing(Explorer(program), (1, 1), True) def get_world(self, show_walls=True):