aboutsummaryrefslogtreecommitdiff
path: root/frontend/cmd/query.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'frontend/cmd/query.cpp')
-rw-r--r--frontend/cmd/query.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/frontend/cmd/query.cpp b/frontend/cmd/query.cpp
index acd6cee..19f2584 100644
--- a/frontend/cmd/query.cpp
+++ b/frontend/cmd/query.cpp
@@ -1,9 +1,9 @@
#include "backend/Location.h"
#include "backend/Object.h"
#include "backend/Enemy.h"
+#include "backend/print.h"
#include "../Player.h"
-#include "../print.h"
using namespace std;
@@ -21,8 +21,7 @@ FollowupAction Player::cmd_query(string &) {
{
lprtf("Zichtbare objecten: ");
size_t objects = 0;
- for (Object * obj : this->location.get_objects()) {
- if (obj->get_hidden() == true) continue;
+ for (Object * obj : this->location.get_visible_objects()) {
if (objects > 0) lprtf(", ");
lprtf("%s", obj->get_displayname().c_str());
objects++;