summaryrefslogtreecommitdiff
path: root/cObjectHandler.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'cObjectHandler.cpp')
-rw-r--r--cObjectHandler.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/cObjectHandler.cpp b/cObjectHandler.cpp
index 0b4bb65..3b56e82 100644
--- a/cObjectHandler.cpp
+++ b/cObjectHandler.cpp
@@ -145,7 +145,7 @@ void cObjectHandler::buildHitmap()
{
for(int y = oPos.y; y <= oPos.y + oSize.y; y++)
{
- if(x < size.x && y < size.y) //Objects can be outside the screen.
+ if((x < size.x && y < size.y) && (x >= 0 && y >= 0)) //Objects can be outside the screen.
iHitMap[x][y] = i;
}//for
}//for