check collision before updating