2D Platformer - Check fall collision

Hi!
First thread now, and I sure hope it is worth it :smile:

I’m making a 2.5D platformer, but I’m having trouble deciding how to detect collisions when falling eg. after a jump.

Basically, what I want is: If theres floor anywhere between the current Y-Position and the next Y-Position snap to the floors Y-Position.

I can’t solve this by putting a script at all the floor instances, so it has to be done in the player script.

So… Is there a way/What is the best way to detect if theres a certain object at a specific position?

Solved it using raycast.

Thanks anyways!