Try making the ladders NPCs, and then having the system detect the NPCs.
ex.
ladder
PHP Code:
function onCreated() {
setshape(1,16*width,16*height);
this.isLadder = true;
}
-----system NPC function for testing ladders
function testLadder() {
temp.tnpcs = findareanpcs(x,y,w,h);
for (i=0; i<temp.tnpcs.size(); i++)
if (temp.tnpcs[i].isladder)
return true;
return false;
}