How do I detect ledges?
I'm working on a 2D platformer using XNA and Farseer. I would like the player's character to be able to grab and climb up ledges. Detecting a collision between the player and the side of a wall is simple enough with the OnCollision delegate, but I have to admit I'm a bit stumped on how to detect that there's enough clearance for the PC to mount the ledge.
Essentially, I want to ensure there's an appropriately sized rectangle above and to the left or right of the PC (depending on their direction) and I'm not sure how I would check for such a space.
Any suggestions on how to determine there is nothing in the simulated world within some bounding rectangle?