aboutsummaryrefslogtreecommitdiff
path: root/frontend/util.h
diff options
context:
space:
mode:
authorLoek Le Blansch <loek@pipeframe.xyz>2024-11-02 13:18:50 +0100
committerLoek Le Blansch <loek@pipeframe.xyz>2024-11-02 13:18:50 +0100
commit5a675c5e6833e98b92b55396594bc0d607b98903 (patch)
treeb252fafe921e7734a13d796b950e5ab817a22a1f /frontend/util.h
parent671a25463419691bc6c8d11bd57d932bdea9632b (diff)
clean up code + implement teleport consumable
Diffstat (limited to 'frontend/util.h')
-rw-r--r--frontend/util.h11
1 files changed, 9 insertions, 2 deletions
diff --git a/frontend/util.h b/frontend/util.h
index 946539f..a32e4c9 100644
--- a/frontend/util.h
+++ b/frontend/util.h
@@ -2,11 +2,18 @@
#include <string>
-#include "backend/Object.h"
+#include "backend/ListIterator.h"
struct by_name_case_insensitive {
by_name_case_insensitive(const std::string & target_name) : target_name(target_name) {}
std::string target_name;
- bool operator () (Object * object);
+
+ template <typename T>
+ bool operator () (T * object);
};
+template <typename T, class Predicate>
+ListIterator<T> find_if_range(ListRange<T>, Predicate);
+
+#include "util.hpp"
+