Improve collision detection by using a range