easiest way - try tracing from several higher positions, while keeping the same angle. if next trace returns a bigger distance than previous - you found the highest point of the wall. of course this will work only with walls perpendicular to the floor, otherwise you'll have to think of another edge criteria.

so if you trace each 10 quants upwards for example - you can measure the block's height with average accurancy about 5 quants. in your case i'd choose to trace every 5 quants and if 5 traces return the same distance - the wall is 'unclimbable'.

hope that helps.