Hello robloxains! Im making a script that does a function only If you the player either touches It or clicks on It the problem? It appears to not work as attended Im new to scripting and I don't really know anything about scripting.
The script:
local Players = game:GetService("Players") script.Parent.Touched:Connect(function(hit) if Player.Name == hit.Parent.Name then print:("Test") end end)
Btw If you don't userstand me I want to make a script that will not effect anyone exepct for you If you click or touch the part