diff options
author | Loek Le Blansch <loek@pipeframe.xyz> | 2024-10-30 20:31:18 +0100 |
---|---|---|
committer | Loek Le Blansch <loek@pipeframe.xyz> | 2024-10-30 20:31:18 +0100 |
commit | d8daa3e045ca2f41edcbed533bc5a9fef1363a17 (patch) | |
tree | 6a4c0883d05607476b609e68bcac7d854e281aea /frontend/cmd/query.cpp | |
parent | 6e1d62955c7a7f39bc9126d709a42a70e02a1d30 (diff) |
print to backend
Diffstat (limited to 'frontend/cmd/query.cpp')
-rw-r--r-- | frontend/cmd/query.cpp | 5 |
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++; |