How can I hide my sprites behind some backgrounds???

For example think about a man: he's walking... ta, ta, ta... there is a wall... go behind and go on walking... ta ta ta.... when wall finished go foreground ... and so on...


Any ideas??


Thx,

Xmas.