]> git.localhorst.tv Git - blank.git/blobdiff - src/world/Block.hpp
check for entities under crosshair
[blank.git] / src / world / Block.hpp
index 274e3d3c3120369eb8915c752db357c8b8b80b23..5f52d173882903af05a8346561842d0f77006f52 100644 (file)
@@ -131,7 +131,13 @@ private:
 
 };
 
-bool operator ==(const Block &, const Block &);
+inline bool operator ==(const Block &a, const Block &b) {
+       return a.type == b.type && a.orient == b.orient;
+}
+
+inline bool operator !=(const Block &a, const Block &b) {
+       return !(a == b);
+}
 
 std::ostream &operator <<(std::ostream &, const Block &);
 std::ostream &operator <<(std::ostream &, const Block::Face &);