Block:collidesWith

This function allows you to read what side of a block is touched by a given player in SMBX.