Added third parameter to CollisionDetection()

Added a third parameter to CollisionDetection() that allows the designer
to specify whether or not we need to check the z axis for intersection.
That way we can support 3D AABB while allowing the designer to skip the
third axis check if they only want to deal with 2 dimensions for their
game.