Just in general, I believe stationary lights still update when they aren’t being interacted with, this could be improved somehow
Or, having lights update at different speeds, important player interactions like a flashlight could update faster, or the opposite, a player being far away updates the light less and less and deletes lights for better performance.
Basically and LOD for lighting, this could be edited for player settings aswell, for player tweaked performance.
Wow this:
is a genius idea. Right now I update every light on screen in a 55 stud radius, because I had no better idea. Thank you!
No problem, I suggest the maximum update FPS should be 24 or 30 for better allocation for other processes.
Also, if you haven’t already, lights not seen should be dramatically decreased, but still updating slowly for if you turn too fast it can catch up later.
How does your fog work compared to LightUp’s?
edit: changed dog to fog lmao
Hi @Xsticcy , Im interested in this little Project that you made… Uh may i ask… How did you make this?
Raycasting + beams + optimization! That’s all.
Ohhh, well that makes sense… thanks a lot.
but how many beams do you use for each light? How did you compose them together like blend together like in the video of the OP.
The textures I use and the width of the beams create the effect. It depends how many beam is used for a light.
Ok… how did you scatter the beams? Yk cuz putting them in 1 place doesnt really work…
Makes ton of sense TYSM, what youve done is very helpful.
So what i should do is:
-
Make a number of beams (any number), then make them randomize position (and orientation) within the angle of the light (Had issues getting the angle but ig i can do something about it).
-
Determine the size of each beams (I think it already does this but ima do some tweaking).
-
Then Use raycasts to uh, detect parts and change distance of beams (um im not sure if i should delete then create a beam or just make a new beam and reduce it’s distance or use existing beams and reduce the size which is kinda hard since it needs to know which beam it should change).
I’m i getting anything wrong by any chance?
- You don’t randomize anything, use loops.
- Good.
- Just change the distance of the beam, deleting and creating a new one is much slower.
How can i use for loops to scatter the position of attachments?
Use the angle of the light to create attachments on the X axis and use the angle AGAIN to make another list of attachments to create
Love it! Looks awesome! Great job.
Just lemme give you a hint:
for x = 1, lightAngle, 15 do
for y = 1, lightAngle, 15 do
for z = 1, lightAngle, 15 do
--your code here
end
end
end
oh, well that makes sense… I understand it.