Okay, so I've seen this effect used in a lot of games where you can toggle between fog on and fog off but it only effects your player. Or when you wear "night vision goggles" and it only changes your ambient. I would like to know how this works if anyone knows.(Maybe it has something to do with current camera but I can't find anything on the wiki...)
Thanks, ~Sweetpea11fir
I had an epiphany one night about how to cause local lighting and implemented it the next morning.
If you use the Changed
event on the Lighting service, a LocalScript can turn back the change caused by someone else, and so the LocalScript governs what the lighting looks like. (The effect of this is a psychedelic strobe on the Server side -- but none of the clients see this)
That led to the various local-lighting APIs that are floating around; it's pretty easy to implement yourself.
(This method is not a good one, but it means you don't have to do anything to your place to make it work)
Use workspace's FilteringEnabled
. This property, when enabled, makes any change caused by a LocalScript to be ignored by the server -- so just modify the lighting with LocalScripts, and those modifications are local to that one client.
However, this can also mess-up scripts that weren't designed with FilteringEnabled
intended (since the server then ignores everything a LocalScript does). Currently ROBLOX recommends all places use FilteringEnabled
, though, so that should just be some necessary work.
Take this model here: http://www.roblox.com/Localized-Lighting-item?id=103185990 You must be familiar with scripting to use this effectively. Read the comments made in the script to help you.
More detail remember this is a helping centre not a give away a random script centre.