Added initial collision detection