This regular script makes lighting effects when touched by humanoid, but I need the lighting effects to only affect local player. How can I do that?
local part = script.Parent
local function onPartTouched(otherPart)
local partParent = otherPart.Parent
local humanoid = partParent:FindFirstChildWhichIsA("Humanoid")
if humanoid then
game.Lighting.ColorCorrection.TintColor = Color3.new(1, 1, 0)
game.Lighting.Blur.Size = 7
game.Lighting.ColorCorrection.Brightness = 0.1
end
end
part.Touched:Connect(onPartTouched)

1 comment
o wow that works thanks