#I have a part where it changes green when touched, but its material doesn’t stay neon, fix anyone?😄
57 messages · Page 1 of 1 (latest)
no script = no help
** You are now Level 5! **
send ur script
send it like this plz
then go on pc 😭
then unfortunately i cant help you
maybe send a picture
local part = script.Parent
part.Touched:Connect(function()
part.BrickColor = BrickColor.Green()
part.Material = Enum.Material.Neon
end)```
is it a server script
no
local part = script.Parent
part.Touched:Connect(function(hit)
if hit:FindFirstChild("Humanoid") then
part.BrickColor = BrickColor.new("Bright green")
part.Material = Enum.Material.Neon
end
end)```
touched events dont work on local
try that script and remove the findfirstchild part and see if it works
then utilize remote events
and fire the client who hit it
game:GetService("ReplicatedStorage").EventName:FireClient(hit)
``` and then make a local script
```lua
game:GetService("ReplicatedStorage").EventName.OnClientEvent:Connect(function()
--script
end)
dude
local part = script.Parent
part.Touched:Connect(function(hit)
game:GetService("ReplicatedStorage").EventName:FireClient(hit)
end)
this is the touched script
this will fire an event whenever you touch it
now make a local script inside that part
and do this
game:GetService("ReplicatedStorage").EventName.OnClientEvent:Connect(function(hit)
script.Parent.BrickColor = BrickColor.new("Bright green")
script.Parent.Material = Enum.Material.Neon
end)
also
you need to create a remote event
if you haven't already
just make one in replicated storage
and name it
EventName
ye
s
actually no
put the local script
in starter character scripts
and put this inside of it
game:GetService("ReplicatedStorage").EventName.OnClientEvent:Connect(function(hit)
workspace.PARTNAMEHERE.BrickColor = BrickColor.new("Bright green")
workspace.PARTNAMEHERE.Material = Enum.Material.Neon
end)```
this
yes
yes
ignore that
ive already told u that answre
yes
yes
ive already told u this

gl
2 years ago
and yet im still shit 😭
i self taught myself
i dont advise self teaching urself it gets u in bad habits lol
just wtach tutorials
or use like
free model scripts and see how they work