  We discuss the generalization of a classical problem involving an $N$-step
ideal polymer adsorption at a sticky boundary (potential well of depth $U$). It
is known that as $N$ approaches infinity, the path undergoes a 2nd-order
localization transition at a certain value of $U_{\text{tr}}$. By considering
the random walk on a half-line with a sticky boundary (Model I), we demonstrate
that the order of the phase transition can be altered by adjusting the scaling
of the first return probability to the boundary. Additionally, we present a
model of a random path on a discrete 1D lattice with non-uniform local hopping
amplitudes and a potential well at the boundary (Model II). We illustrate that
one can tailor such amplitudes so that the polymer undergoes a 3rd-order phase
transition.
