Sniper scopes zooming issue

Hello, I was wondering if I could make a scope like this in roblox:

I know there is a zoom feature but I’m not sure how to limit that to a circle in the middle of the screen.

1 Like

ROBLOX does not support dual-rendering. There is no legit way to achieve this other than using hacky methods.

One method would be that you replicate all the workspace parts in a viewport frame. @boatbomber has done this, however, it’s not practical. It would consume a lot of CPU power.

His thread:
[Open Sourced!] "Dual Render" Scope System

1 Like

couldn’t you just destroy the viewportframe when the player isn’t using it and when they swap to the sniper it creates a new one?

I’m not good at this, I am answering based on the thread I read that’s linked above.

I have neither tested boatbomber’s system, nor inspected its source code. Based on my reading of the replies, I think the items rendering in the viewport frame are stopped when the scope is not in use.

However, it is CPU-intensive because the when the scope is in use, the client has to render the same stuff twice - one in the actual camera, and one in the viewport frame.

I also saw the article, I might add it but have an option to switch between a normal scope which blacks out the are around it and that advanced scope.

1 Like

That seems like a good idea. I’d be happy to see an actual game out with the “dual-render” system! Good luck!

Thanks, kinda basing my game off of the game tarkov but changing a lot of things

I found this article while scrolling through some stuff [Release] ViewportFrame limited-rendering if I get that scope and use this, do you think the outcome would be better? Or has he already implemented this feature?

Doesn’t Jailbreak have a sniper? How do they do that?
(I’m not too sure I don’t really play Jailbreak nowadays)

The whole screen zooms in and a GUI covers up the sides to make it not look obvious, it’s like every other sniper

Oh are there any tutorials out there on how to do something like that?

I’m not sure, I did find this though I don’t know if it’s what your after. Making a combat game with ranged weapons? FastCast may be the module for you!

There are a lot of items from the toolbox which use the zoom effect, basically what is happening is when the player right clicks, the camera zooms in a certain amount and a GUI appears.

1 Like