Movement limited to viewport

I’m trying to setup a Pong in 3d.
How can I limit my paddle Caracter/Pawn movement (with mouse) to viewport.
I don’t want the paddle to get out of the screen and want to limit its movement within the viewport/
I can’t figure out how to make this.

Thanks for your help


Maybe, you need to placed four blocking volumes, near screen edge, like “invisible wall”?