One of the objects you're trying to pass has no type defined?
Nope, that would give an 'Object does not exist' error.
You obviously must be supplying an invalid entity handle to 'CollisionEntity(car(ac),1))'. Either the handle was never set or the entity has been deleted and the handle is no longer valid.
Try checking the contents of the 'car(ac)' array (assuming it's an array) for a zero value which would indicate that the handle was never set. Otherwise, try setting the entity handle stored in 'car(ac)' to zero when you delete that entity and then test for a non-zero value before executing any operations involving the stored handle.