X-Git-Url: https://git.localhorst.tv/?a=blobdiff_plain;f=src%2Fworld%2FWorld.cpp;h=4ab116c24f79f7f2f9581bdb67553204fd3dcc0f;hb=419e33e565bffbaf0416ed4a5f80e9c81f62a479;hp=82701ce8686f48f20b3f24039a1239547375671f;hpb=c04ea5a6f67d446ea29aa2e88dc4c666956d7732;p=blank.git diff --git a/src/world/World.cpp b/src/world/World.cpp index 82701ce..4ab116c 100644 --- a/src/world/World.cpp +++ b/src/world/World.cpp @@ -178,6 +178,8 @@ bool World::Intersection( bool World::Intersection(const Entity &e) { AABB box = e.Bounds(); glm::mat4 M = e.Transform(player->ChunkCoords()); + // TODO: this only needs to check the chunks surrounding the entity's chunk position + // need find out if that is quicker than the rough chunk bounds test for (Chunk &cur_chunk : chunks.Loaded()) { if (cur_chunk.Intersection(box, M, cur_chunk.Transform(player->ChunkCoords()))) { return true;