script.Parent.Touched:connect(function(hit)
hit.Parent -- Ect
end
So i want it to find the hit.parent's Player not its character? Help quickly please,Its for a limited time thing
script.Parent.Touched:connect(function(hit)
hit.Parent -- Ect
end
So i want it to find the hit.parent's Player not its character? Help quickly please,Its for a limited time thing
That's where GetPlayerFromCharacter comes in handy, example script:
script.Parent.Touched:connect(function(hit)
local plr=game.Players:GetPlayerFromCharacter(hit.Parent)--It's getting the Player from the Hit.Parent, which is the Character.
print(plr.Name)
end)
This discussion is preserved as it was. New answers, comments, and votes are closed.