Change card after taking action.
[naja.git] / naja / gameboard.py
index 980a046c4c4f68e690219a2a216f818df018ce9e..8d4106cc931011dea15725842abf188a0b51f999 100644 (file)
@@ -90,6 +90,10 @@ class GameBoard(object):
         self.health -= 1
         # TODO: Check win/lose
 
+    def replace_card(self, position):
+        location = LocationCard.new_location(choice(self.locations).copy())
+        self.board_locations[position] = location
+
     def change_mode(self):
         """Advance to the next mode"""
         if self.player_mode == MOVE: