Texture masking

Hello everyone,

I would like to ask for help regarding the matter of masking textures with below a example.
On the left is the way it currently is functioning(no masking), on the right is the desired behavior.

Thank you for any assistance someone might offer,

Willem

It looks like an alpha issue. I am not that good with 2D or 2.5D in this case.