Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Can someone please convert this button script to filtering enabled?

Asked by 5 years ago

It is just a simple Gui that makes you reset, but I need it to be filtering enabled.

script.Parent.MouseButton1Click:connect(function()
    script.Parent.Parent.Parent.Parent.Character.Humanoid.Health = 0
end)

Can someone please help me?

Thank you.

0
Instead of so many `script.Parents`, I recommend using `LocalPlayer`. http://robloxdev.com/api-reference/property/Players/LocalPlayer TheeDeathCaster 2368 — 5y
0
Thank you, I will try that. User#23357 0 — 5y
0
If you're using this on a Local script, then you don't need to convert it to filtering enabled. It will replicate if it's only affecting the LocalPlayer ininja966 20 — 5y

Answer this question