How to Create PUBG style Sniper Zoom Function

I’m trying to create a sniper scope with zoom function just like PUBG but i’m having trouble when i try to zoom-in as it also zooms on the scope mesh itself which is not correct.
here is a video of how pubg scope works:

as you can see in the video when the camera zooms out, the location of the scope on screen stays the same size. at first one might think there are 2 cameras but it’s not and thats because the outside part of the scope is also affected by camera FOV.
so any ideas how this can be done?
Thanks !

I’d imagine one camera renders the environment and one camera renders the weapons. Weapons are then overlayed onto the screen, and you can freely change the environment and weapon camera FOV.

How can TWO cameras be overlaid in UE4 though?
UE4 doesn’t offer a whole lot of options to do this…

Option1: RenderTexture (Can be expensive, but there’s lots of flexible control).
Option2: Split-Screen (Zero control… Not much flexibility in Blueprints anyway).
Option3. Marketplace Plugins (Can any of these products help? - Free / Paid).

What is your setup right now? Using render texture is the same as the classic security camera trick, so search on YT for tutorials using those keywords if you need to. But basically you attach a Scene-Capture-2D cam to the weapon, and then assign a 2D texture and create a material from all of that. Its less involved than it sounds and pretty easy. You then alter the FOV on the Scene-Capture-2D cam to mimic the zoom.

If using FOV doesn’t match expectations, you can also just move the 2D camera closer to the action or away from it. Either way, both options can be driven from a Timeline etc. The sniper display itself is a plane / mesh with the material from the 2D Texture. BTW: In some weapon setups / scenarios, you may even be able to use a RenderTexture as the blurred background (projected onto a mesh with a round porous hole), and then just apply FOV changes to a normal camera (as the render texture plane / mesh will occlude the background). Placing an only-owner-see mesh or widget over the camera view could then complete the effect.

EDIT: This might of interest also…

To be honest I just assumed it was done this way in unreal as well, since in Unity this is a fairly basic thing to do.

Thank you for your sharing video on how to use and shoot sniper in PUBG.