Cut circle mask/shape by another mask/shape

Hi i saw something in one old game and i wonder how they did this and is something like this possible with phaser.
When you select player you can see area where you can click to move. If something is blocking path you cant go there. This is something like dynamic lights but in this case its not. In game files there are a lot of alpha mask for maps.

Is it possible to cut circle like this or draw shape by obstacles using phaser?
This are the images about what im talking.