Permalink
Browse files

display which item is equiped

  • Loading branch information...
1 parent 6911d41 commit 55c58dff3320708c9587c6c56ee046782a03ef0c @jbohman jbohman committed Jan 12, 2012
Showing with 5 additions and 1 deletion.
  1. +5 −1 controller.cpp
View
@@ -139,7 +139,11 @@ void Controller::run_output() const
if (container != 0 && !container->is_empty()) {
std::cout << "Inventory: ";
for (auto object : container->get_objects()) {
- std::cout << object->name() << " ";
+ if (object == player->get_weapon()) {
+ std::cout << object->name() << "[Equiped] ";
+ } else {
+ std::cout << object->name() << " ";
+ }
}
std::cout << std::endl;
}

0 comments on commit 55c58df

Please sign in to comment.