X-Git-Url: http://git.localhorst.tv/?a=blobdiff_plain;ds=sidebyside;f=src%2Fworld%2FWorld.hpp;h=e0209c96aaf273eb4fab523fd4734b2353e5af28;hb=e872614d387c4bfc3afb04bcc7cba3d9b8f3954b;hp=a1385138edd5fa135d84dba21025b2f4253f9e8b;hpb=d2fa8ca97d291508ce3812fb052a8255d3190d00;p=blank.git diff --git a/src/world/World.hpp b/src/world/World.hpp index a138513..e0209c9 100644 --- a/src/world/World.hpp +++ b/src/world/World.hpp @@ -42,15 +42,20 @@ public: /// check if this ray hits a block /// depth in the collision is the distance between the ray's /// origin and the intersection point + /// M is the global transform for given reference chunk bool Intersection( const Ray &, const glm::mat4 &M, + const Chunk::Pos &reference, WorldCollision &); /// check if this ray hits an entity + /// intersections with the reference are not tested + /// M is the global transform for the chunk of given reference entity bool Intersection( const Ray &, const glm::mat4 &M, + const Entity &reference, EntityCollision &); /// check if given entity intersects with the world @@ -64,7 +69,6 @@ public: Entity &AddEntity() { entities.emplace_back(); return entities.back(); } Chunk &PlayerChunk(); - Chunk &Next(const Chunk &to, const glm::ivec3 &dir); void Update(int dt);