Making simple click detector part color script

I’m trying to make a script work so that when you click a part it turns green for only 1 person. It’s not changing green for 1 person though and there is no hints in the output.

local script in StarterPlayerScripts:

game.Workspace.Part1.ClickDetector.MouseClick:Connect(function(plr)
	game.Workspace.Part1.Color = Color3.new(0.271214, 1, 0.270527)
end)

Localscripts will fire ClickDetector if it descends from player or character
try moving your localscript do starterplayerscripts…

i just checked here… it is working fine…

local clickDetector = game.Workspace.Part.ClickDetector
local part = game.Workspace.Part

local function onClick(plr)
	part.Color = Color3.new(0.271214, 1, 0.270527)
end

clickDetector.MouseClick:Connect(onClick)

It doesn’t work for me, but it works for you?

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.