Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

Is the lighting tab in Studio replicated to all clients or is it server side?

I have a speed boost for a character in my game, and when he enables it I want there to be a blur. (I only want the sprinting character to see the blur) I want to use lighting and a storage for the blur, but I fear when I enable it, it will be enabled for everyone. How can I avoid this? Do I parent the blur to the actual player?

Thank you for your time. :)

1 answer

Filtering Enabled makes this easy. Turn it on first Then, if you're using a server script, use a RemoteEvent and fire the client. The client will then add the blur which makes it so only that player sees it

Like so (EXAMPLE)

-- Script in ServerScriptService
local RemoteEvent = Instance.new("RemoteEvent",game.ReplicatedStorage)
RemoteEvent.Name = "AddBlur"

game.Players.PlayerAdded:connect(function(player)
	RemoteEvent:FireClient()
end)

-- LocalScript in StarterGui
game.ReplicatedStorage:WaitForChild("AddBlur").OnClientEvent:connect(function()
	local blur = Instance.new("BlurEffect",game.Lighting)
end)

If you're going to use a LocalScript however, you just need the line of code after the OnClientEvent event above in the LocalScript. So that would be: local blur = Instance.new("BlurEffect",game.Lighting)

If you have any questions, drop me a comment

2 comments

0

It still blurs every players screen. I only want it to blur the player who is running screen. Any ideas still???

0

Well, is filtering enabled on?

This discussion is preserved as it was. New answers, comments, and votes are closed.