How can I make it so a player can only see a certain amount and then the rest is darkness? Thanks I would really appreciate it if you could help me
How Do I Make It So A Player Can Only See So Far? (Rest Is Darkness)
Click on Lighting in the Explorer window, then adjust the FogEnd and the FogColor properties.
what should i adjust it to to make it only see up to 30 studs?
I consider the best way to achieve this is by using the “Atmosphere” object:
1 - Insert any skybox you find fitting for your game inside of the “Lighting” service
2 - If the skybox is not already black, change the Lighting.ClockTime to 0
3 - Then, adjust the Atmosphere.Density until it is to your liking
I hope this helped you out.
This means if you leave FogStart at 0 it’ll get darker from 0 to 30 studs. You may want to make FogStart something like 25 so they can still see clearly up to 25 studs then it blends to black from 25 to 30.
This has helped but I think @Scottiflys way may be easier
is there a way that it only shows in game coz its hard to build with this fog on.
You can use a small script like this one, to set the FogStart and FogEnd. Deleting the script afterwards is optional and will cause a tiny bit of lag, but I prefer to delete scripts when they have been run.
local Lighting = game:GetService("Lighting") -- Lighting service Lighting.FogStart = 25 -- Set the FogStart property Lighting.FogEnd = 30 -- Set the FogEnd property script:Destroy() -- Deletes the script so it doesn't interfere with anything later
Yes, you can use @bobbybob2131’s suggestion, or just when you go into Studio set the FogEnd to 1000 but then set the FogEnd to 30 before you test or publish the game .