i have built this lobby background enviroment with this sunray effect, but im running into an issue where the sunrays are very laggy,
With the sunrays:
Without:
i searched on the devforum to no avail! i found this post but it looked bad.
i have built this lobby background enviroment with this sunray effect, but im running into an issue where the sunrays are very laggy,
With the sunrays:
Without:
i searched on the devforum to no avail! i found this post but it looked bad.
What method are you using for the Sunrays? Seeing the original post contains a few suggestions to make this possible
im using the fog part method in the ss
The issue with making volumetric fog/sunrays in roblox is that you’re never really going to get a perfectly optimized solution without some amount of scripting involved, and the ones that don’t have any scripting are often laggier the more are being rendered at the same time or the more light objects are being used in that same space.
the fog part works well visually but is one of the worst in terms of performance
billboard UI’s has been my go to for this since you can semi-optimize it with the amount of billboard UI’s used and setting the max distance to a low value to render fewer at a time, but has its faults still both in performance and visually
the most performant version i could find out there is from “VOLUMIKA AKTIVE”, which is a plugin you can get for free on the roblox marketplace (or find their itch.io page). i recommend trying this
Unfortunately like @Kermitov stated. None of these methods are very optimized so either way, you’ll get a performance loss. Seemly since you chose the Mesh method, it’s very laggy.
I would suggest trying out the Transparent part to still get the sunrays affect but of course more performance friendly. This is one of those graphical features that cannot be made without performance issues.
You’re going to either have to sacrifice performance for visuals, or visuals for performance. i think in your case, the best solution would be to use a grid of beams (im using 9 per window in this example), you can get fairly close to the visuals of the fog part without sacrificing performance. but to get it looking perfect, you’re going to have to put in a lot of time tweaking different properties and attachment positions. (as you can see here around the edges of the windows). unfortunately, beams look quite jarring when intersecting parts, but for your scene, I don’t think it would be very noticeable.