Found the culprit for bug #45

This commit is contained in:
Kayne Ruse
2015-08-24 03:37:44 +10:00
parent 626435974e
commit 188a6805bf
4 changed files with 10 additions and 1 deletions
@@ -223,6 +223,7 @@ std::list<BoundingBox> World::GenerateCollisionGrid(Entity* ptr, int tileWidth,
//inner loop
wallBounds.y = snapToBase((double)wallBounds.h, ptr->GetOrigin().y);
while(wallBounds.y < (ptr->GetOrigin() + ptr->GetBounds()).y + ptr->GetBounds().h) {
//BUG: #45 this is the culprit; it's pulling regions into existance
//check to see if this tile is solid
if (regionPager.GetSolid(wallBounds.x / wallBounds.w, wallBounds.y / wallBounds.h)) {
//push onto the box set